SHA256
ESP32 wallet RPC, browser wallet provider, and side panel
This commit is contained in:
@@ -75,6 +75,22 @@ export class ShineApiClient {
|
||||
return Array.isArray(response?.payload?.sessions) ? response.payload.sessions : [];
|
||||
}
|
||||
|
||||
async callSignalToSession({ toLogin, targetSessionId, callId, type, data = '' }) {
|
||||
const response = await this.ws.request('CallSignalToSession', {
|
||||
toLogin: String(toLogin || '').trim(),
|
||||
targetSessionId: String(targetSessionId || '').trim(),
|
||||
callId: String(callId || '').trim(),
|
||||
type: Number(type) || 0,
|
||||
data: String(data || ''),
|
||||
});
|
||||
if (response.status !== 200) throw opError('CallSignalToSession', response);
|
||||
return response.payload || {};
|
||||
}
|
||||
|
||||
onEvent(op, handler) {
|
||||
return this.ws.on(op, handler);
|
||||
}
|
||||
|
||||
async resumeSession(sessionRecord) {
|
||||
const login = String(sessionRecord?.login || '').trim();
|
||||
const sessionId = String(sessionRecord?.sessionId || '').trim();
|
||||
|
||||
Reference in New Issue
Block a user