ysyt-agent-sdk 1.0.106 → 1.0.107
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/src/core/api-client.d.ts +2 -1
- package/dist/src/index.d.ts +2 -1
- package/dist/src/types/index.d.ts +23 -0
- package/dist/src/utils/http.d.ts +6 -0
- package/dist/ysyt-agent-sdk.cjs.js +3 -3
- package/dist/ysyt-agent-sdk.esm.js +3 -3
- package/dist/ysyt-agent-sdk.umd.js +3 -3
- package/package.json +1 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { AgentItemType, AgentStateDataType, DeviceType, CallCrmObject, RequestBodyType, StateType } from '@/types';
|
|
1
|
+
import { AgentItemType, AgentStateDataType, DeviceType, CallCrmObject, RequestBodyType, StateType, RecordItemType } from '@/types';
|
|
2
2
|
export declare class ApiClient {
|
|
3
3
|
private roleData;
|
|
4
4
|
/**
|
|
@@ -32,4 +32,5 @@ export declare class ApiClient {
|
|
|
32
32
|
}, {
|
|
33
33
|
is_login: boolean;
|
|
34
34
|
}>): Promise<void>;
|
|
35
|
+
getCallRecord(params: RequestBodyType<any, RecordItemType[]>): Promise<void>;
|
|
35
36
|
}
|
package/dist/src/index.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { AgentDataType, AgentItemType, AgentStateDataType, DeviceType, InitInfoType, RequestBodyType, StateType, Events, CallCrmObject } from './types';
|
|
1
|
+
import { AgentDataType, AgentItemType, AgentStateDataType, DeviceType, InitInfoType, RequestBodyType, StateType, Events, CallCrmObject, RecordItemType } from './types';
|
|
2
2
|
export type * from './types';
|
|
3
3
|
export * from './types/Enum';
|
|
4
4
|
declare class YSYTAgentSdk {
|
|
@@ -64,6 +64,7 @@ declare class YSYTAgentSdk {
|
|
|
64
64
|
}, {
|
|
65
65
|
is_login: boolean;
|
|
66
66
|
}>) => Promise<void>;
|
|
67
|
+
getCallRecord: (params: RequestBodyType<any, RecordItemType[]>) => Promise<void>;
|
|
67
68
|
};
|
|
68
69
|
getAgentData(): AgentDataType;
|
|
69
70
|
getRealTimeCustomerInfo(): Promise<CallCrmObject>;
|
|
@@ -5,6 +5,13 @@ export interface ResponseCodeType<T> {
|
|
|
5
5
|
msg: string;
|
|
6
6
|
data?: T;
|
|
7
7
|
}
|
|
8
|
+
export interface ResponseListType<T> extends Omit<ResponseCodeType<any>, 'data'> {
|
|
9
|
+
num_per_page: number;
|
|
10
|
+
total_rows: number;
|
|
11
|
+
total_pages: number;
|
|
12
|
+
current_page: number;
|
|
13
|
+
data: T[];
|
|
14
|
+
}
|
|
8
15
|
export interface RequestBodyType<B = any, R = any> {
|
|
9
16
|
success?: (params: ResponseCodeType<R>) => void;
|
|
10
17
|
data?: B;
|
|
@@ -158,6 +165,22 @@ export interface AgentDataType {
|
|
|
158
165
|
state_name: string;
|
|
159
166
|
};
|
|
160
167
|
}
|
|
168
|
+
export interface RecordItemType {
|
|
169
|
+
record_id: number;
|
|
170
|
+
app_id: string;
|
|
171
|
+
session_id: string;
|
|
172
|
+
call_type: 0 | 1 | 2 | 3 | 4 | 5 | 6 | 7;
|
|
173
|
+
call_trace: string;
|
|
174
|
+
direction: 0 | 1;
|
|
175
|
+
custom_reason: number;
|
|
176
|
+
customer_num: string;
|
|
177
|
+
customer_name: string;
|
|
178
|
+
province: string;
|
|
179
|
+
city: string;
|
|
180
|
+
card_type: string;
|
|
181
|
+
start_time: string;
|
|
182
|
+
call_state: 0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9;
|
|
183
|
+
}
|
|
161
184
|
type EventObject<T> = {
|
|
162
185
|
event: keyof Events;
|
|
163
186
|
data: T;
|
package/dist/src/utils/http.d.ts
CHANGED
|
@@ -26,3 +26,9 @@ export declare const setOutNumber: (params: {
|
|
|
26
26
|
export declare const queryIsLogin: (params: {
|
|
27
27
|
agent_no: string;
|
|
28
28
|
}) => Promise<any>;
|
|
29
|
+
export declare const queryAllRecordList: (params: {
|
|
30
|
+
end_time: string;
|
|
31
|
+
start_time: string;
|
|
32
|
+
page_no: number;
|
|
33
|
+
page_size: number;
|
|
34
|
+
}) => Promise<any>;
|