Response
Feature Introduction
info
Common parameter description for uni-app and JS SDK Promise function callbacks.
- uni-app
- Browser/Electron/MiniProgram
- React-Native
CatchResponse
Type
type CatchResponse = {
errCode: number;
errMsg: string;
};
Field Description
Field Name | Field Type | Description |
---|---|---|
errCode | number | Error code when the call fails |
errMsg | string | Error description when the call fails |
WsResponse
Type
type WsResponse<T = unknown> = {
errCode: number;
errMsg: string;
data: T;
operationID: string;
};
Field Description
Field Name | Field Type | Description |
---|---|---|
errCode | number | Error code when the call fails |
errMsg | string | Error description when the call fails |
operationID | string | The operationID passed in during the call |
data | T | Return results when the call is successful, as a generic type |
WSEvent
Type
type WSEvent<T = unknown> = {
event: CbEvents;
data: T;
errCode: number;
errMsg: string;
operationID: string;
};
Field Description
Field Name | Field Type | Description |
---|---|---|
event | CbEvents | Event being listened to |
data | T | Callback results, as a generic type |
errCode | number | Error code |
errMsg | string | Error description |
operationID | string | Unique operation id |