@or-sdk/hitl 0.35.2-beta.3694.0 → 0.35.2-beta.3696.0
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/cjs/api/Agents.js.map +1 -1
- package/dist/cjs/types/agents.js.map +1 -1
- package/dist/esm/api/Agents.js.map +1 -1
- package/dist/esm/types/agents.js.map +1 -1
- package/dist/types/api/Agents.d.ts.map +1 -1
- package/dist/types/types/agents.d.ts.map +1 -1
- package/package.json +1 -1
- package/src/api/Agents.ts +245 -28
- package/src/types/agents.ts +6 -27
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Agents.js","sourceRoot":"","sources":["../../../src/api/Agents.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,gDAAwB;AAExB,0CAAmD;AAmBnD,uCAAsC;AAEtC;IAA4B,0BAAQ;IAApC;;
|
|
1
|
+
{"version":3,"file":"Agents.js","sourceRoot":"","sources":["../../../src/api/Agents.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,gDAAwB;AAExB,0CAAmD;AAmBnD,uCAAsC;AAEtC;IAA4B,0BAAQ;IAApC;;IA2eA,CAAC;IAlbqB,gBAAS,GAA7B;4DACE,OAA8B;;YAA9B,wBAAA,EAAA,YAA8B;;gBAExB,KAAK,GAAG,IAAI,CAAC,UAAU,CAAC,OAAO,CAAC,CAAC;gBACjC,MAAM,GAAG,MAAM,CAAC,WAAW,CAC/B,MAAM,CAAC,OAAO,CAAC,OAAO,CAAC,CAAC,MAAM,CAAC,UAAC,EAAK;wBAAJ,GAAG,QAAA;oBAAM,OAAA,CAAC,+BAAmB,CAAC,QAAQ,CAAC,GAAG,CAAC;gBAAlC,CAAkC,C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agents.ts"],"names":[],"mappings":";;;AAAA,2DAKkC;
|
|
1
|
+
{"version":3,"file":"agents.js","sourceRoot":"","sources":["../../../src/types/agents.ts"],"names":[],"mappings":";;;AAAA,2DAKkC;AA0EzB,6FA7EP,6BAAY,OA6EO;AAAE,uGA5ErB,uCAAsB,OA4EqB;AAAE,0FA3E7C,0BAAS,OA2E6C"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Agents.js","sourceRoot":"","sources":["../../../src/api/Agents.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA,OAAO,GAAG,MAAM,OAAO,CAAC;AAExB,OAAO,EAAE,mBAAmB,EAAE,MAAM,cAAc,CAAC;AAmBnD,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AAEtC,MAAM,OAAO,MAAO,SAAQ,QAAQ;
|
|
1
|
+
{"version":3,"file":"Agents.js","sourceRoot":"","sources":["../../../src/api/Agents.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA,OAAO,GAAG,MAAM,OAAO,CAAC;AAExB,OAAO,EAAE,mBAAmB,EAAE,MAAM,cAAc,CAAC;AAmBnD,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AAEtC,MAAM,OAAO,MAAO,SAAQ,QAAQ;IAyD3B,MAAM,CAAO,SAAS;6DAC3B,UAA4B,EAAE;YAE9B,MAAM,KAAK,GAAG,IAAI,CAAC,UAAU,CAAC,OAAO,CAAC,CAAC;YACvC,MAAM,MAAM,GAAG,MAAM,CAAC,WAAW,CAC/B,MAAM,CAAC,OAAO,CAAC,OAAO,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,GAAG,CAAC,EAAE,EAAE,CAAC,CAAC,mBAAmB,CAAC,QAAQ,CAAC,GAAG,CAAC,CAAC,CAC9E,CAAC;YAEF,OAAO,IAAI,CAAC,OAAO,iBACjB,KAAK;gBACL,MAAM,IACH,IAAI,CAAC,eAAe,CAAC,OAAO,CAAC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AI,GAAG,MAAM,CAAC,WAAW,CAC7B,MAAM,CAAC,OAAO,CAAC,OAAO,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,GAAG,CAAC,EAAE,EAAE,CAAC,CAAC,mBAAmB,CAAC,QAAQ,CAAC,GAAG,CAAC,CAAC,CAC9E,CAAC;YAEF,IAAI,MAAM,CAAC;YACX,IAAI,QAAQ,GAAG,CAAC,CAAC;YAEjB,OAAO,MAAM,KAAK,SAAS,IAAI,QAAQ,GAAG,UAAU,EAAE,CAAC;gBACrD,QAAQ,EAAE,CAAC;gBACX,IAAI,CAAC;oBACH,MAAM,GAAG,MAAM,IAAI,CAAC,OAAO,iBACzB,MAAM,EAAE,KAAK,EACb,KAAK;wBACL,IAAI,IACD,IAAI,CAAC,eAAe,CAAC,OAAO,CAAC,EAChC,CAAC;gBAEL,CAAC;gBAAC,OAAO,CAAM,EAAE,CAAC;oBAChB,IAAI,CAAC,CAAC,OAAO,KAAK,qDAAqD;wBAAE,MAAM,CAAC,CAAC;gBACnF,CAAC;YACH,CAAC;YAED,OAAO,MAAM,CAAC;QAChB,CAAC;KAAA;;AAzegB,iBAAU,GAAG,QAAQ,CAAC;AACtB,uBAAgB,GAAG,QAAQ,CAAC;AAC5B,sBAAe,GAAG,UAAU,CAAC;AAC7B,2BAAoB,GAAG,cAAc,CAAC;AACtC,4BAAqB,GAAG,aAAa,CAAC;AACtC,4BAAqB,GAAG,mBAAmB,CAAC;AAC5C,uBAAgB,GAAG,QAAQ,CAAC;AAC5B,wCAAiC,GAAG,cAAc,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"agents.js","sourceRoot":"","sources":["../../../src/types/agents.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,YAAY,EACZ,sBAAsB,EACtB,SAAS,GACV,MAAM,0BAA0B,CAAC;
|
|
1
|
+
{"version":3,"file":"agents.js","sourceRoot":"","sources":["../../../src/types/agents.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,YAAY,EACZ,sBAAsB,EACtB,SAAS,GACV,MAAM,0BAA0B,CAAC;AA0ElC,OAAO,EAAE,YAAY,EAAE,sBAAsB,EAAE,SAAS,EAAE,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Agents.d.ts","sourceRoot":"","sources":["../../../src/api/Agents.ts"],"names":[],"mappings":"AAGA,OAAO,EACL,KAAK,EACL,sBAAsB,EACtB,wBAAwB,EACxB,2BAA2B,EAC3B,kBAAkB,EAClB,qBAAqB,EACrB,gBAAgB,EAChB,iBAAiB,EACjB,mBAAmB,EACnB,oBAAoB,EACpB,kBAAkB,EAClB,mBAAmB,EACnB,4BAA4B,EAC5B,6BAA6B,EAC7B,gCAAgC,EACjC,MAAM,iBAAiB,CAAC;AAEzB,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AAEtC,qBAAa,MAAO,SAAQ,QAAQ;IAClC,SAAS,CAAC,MAAM,CAAC,UAAU,SAAY;IACvC,SAAS,CAAC,MAAM,CAAC,gBAAgB,SAAY;IAC7C,SAAS,CAAC,MAAM,CAAC,eAAe,SAAc;IAC9C,SAAS,CAAC,MAAM,CAAC,oBAAoB,SAAkB;IACvD,SAAS,CAAC,MAAM,CAAC,qBAAqB,SAAiB;IACvD,SAAS,CAAC,MAAM,CAAC,qBAAqB,SAAuB;IAC7D,SAAS,CAAC,MAAM,CAAC,gBAAgB,SAAY;IAC7C,SAAS,CAAC,MAAM,CAAC,iCAAiC,SAAkB;
|
|
1
|
+
{"version":3,"file":"Agents.d.ts","sourceRoot":"","sources":["../../../src/api/Agents.ts"],"names":[],"mappings":"AAGA,OAAO,EACL,KAAK,EACL,sBAAsB,EACtB,wBAAwB,EACxB,2BAA2B,EAC3B,kBAAkB,EAClB,qBAAqB,EACrB,gBAAgB,EAChB,iBAAiB,EACjB,mBAAmB,EACnB,oBAAoB,EACpB,kBAAkB,EAClB,mBAAmB,EACnB,4BAA4B,EAC5B,6BAA6B,EAC7B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Dd,cAAc,CAChC,EAAE,OAAO,EAAE,GAAG,OAAO,EAAE,EAAE,qBAAqB,GAC7C,OAAO,CAAC,IAAI,CAAC;WA4CI,yBAAyB,CAC3C,EAAE,UAAc,EAAE,GAAG,OAAO,EAAE,EAAE,gCAAgC;CA8BnE"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"agents.d.ts","sourceRoot":"","sources":["../../../src/types/agents.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,MAAM,EACN,YAAY,EACZ,sBAAsB,EACtB,SAAS,EACV,MAAM,0BAA0B,CAAC;AAElC,OAAO,EAAE,iBAAiB,EAAE,WAAW,EAAE,MAAM,UAAU,CAAC;AAG1D,MAAM,WAAW,KAAM,SAAQ,IAAI,CAAC,MAAM,CAAC,MAAM,EAAE,SAAS,CAAC;CAAG;
|
|
1
|
+
{"version":3,"file":"agents.d.ts","sourceRoot":"","sources":["../../../src/types/agents.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,MAAM,EACN,YAAY,EACZ,sBAAsB,EACtB,SAAS,EACV,MAAM,0BAA0B,CAAC;AAElC,OAAO,EAAE,iBAAiB,EAAE,WAAW,EAAE,MAAM,UAAU,CAAC;AAG1D,MAAM,WAAW,KAAM,SAAQ,IAAI,CAAC,MAAM,CAAC,MAAM,EAAE,SAAS,CAAC;CAAG;AAChE,MAAM,MAAM,WAAW,GAAG,MAAM,CAAC;AACjC,MAAM,WAAW,0BAA2B,SAAQ,MAAM,CAAC,oBAAoB;CAAG;AAElF,MAAM,WAAW,iBAAiB;IAChC,QAAQ,CAAC,IAAI,EAAE,OAAO,CAAC,KAAK,CAAC,EAAE,CAAC;IAChC,QAAQ,CAAC,IAAI,CAAC,EAAE;QACd,QAAQ,CAAC,EAAE,CAAC,EAAE,MAAM,CAAC;QACrB,QAAQ,CAAC,SAAS,CAAC,EAAE,MAAM,CAAC;KAC7B,CAAC;CACH;AAED,MAAM,WAAW,gBACf,SAAQ,iBAAiB,EACvB,WAAW,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,sBAAsB,EAAE,SAAS,EAAE,CAAC"}
|
package/package.json
CHANGED
package/src/api/Agents.ts
CHANGED
|
@@ -34,21 +34,20 @@ export class Agents extends HITLBase {
|
|
|
34
34
|
/**
|
|
35
35
|
* Gets a list of agents with HITL (Human in the Loop) information
|
|
36
36
|
*
|
|
37
|
-
* @param options - Configuration options for the agent list request
|
|
38
|
-
*
|
|
39
|
-
*
|
|
40
|
-
*
|
|
41
|
-
*
|
|
42
|
-
*
|
|
43
|
-
*
|
|
44
|
-
* @param [options
|
|
37
|
+
* @param {Object} options - Configuration options for the agent list request
|
|
38
|
+
* @param {string[]} [options.agentIds] - List of specific agent identifiers to retrieve
|
|
39
|
+
* @param {string[]} [options.projection] - List of fields to include in the response
|
|
40
|
+
* @param {number} [options.limit] - Maximum number of agents to return
|
|
41
|
+
* @param {number} [options.offset] - Number of agents to skip for pagination
|
|
42
|
+
* @param {string} [options.orderBy] - Field name to order the results by
|
|
43
|
+
* @param {('asc'|'desc')} [options.order] - Order direction
|
|
44
|
+
* @param {number} [options.version] - API version
|
|
45
45
|
*
|
|
46
46
|
* @returns {Promise<GetAgentsResponse>} Promise resolving to:
|
|
47
47
|
* - `data` - Array of partial agent objects {@link Agent}
|
|
48
48
|
* - `last` - Optional pagination information:
|
|
49
49
|
* - `id` - Optional ID of the last agent in the list
|
|
50
50
|
* - `accountId` - Optional account ID of the last agent
|
|
51
|
-
* See {@link GetAgentsResponse} in types/agents.ts for complete type definition
|
|
52
51
|
*
|
|
53
52
|
* @throws HITLAuthenticationError
|
|
54
53
|
* @throws HITLValidationError
|
|
@@ -75,6 +74,8 @@ export class Agents extends HITLBase {
|
|
|
75
74
|
* });
|
|
76
75
|
* ```
|
|
77
76
|
*
|
|
77
|
+
* @remarks
|
|
78
|
+
* Makes a GET request to the `/agents` endpoint
|
|
78
79
|
* @public
|
|
79
80
|
*/
|
|
80
81
|
public static async getAgents(
|
|
@@ -93,8 +94,28 @@ export class Agents extends HITLBase {
|
|
|
93
94
|
}
|
|
94
95
|
|
|
95
96
|
/**
|
|
96
|
-
*
|
|
97
|
-
*
|
|
97
|
+
* Get Agents list with full info (additional data from Users API DB)
|
|
98
|
+
*
|
|
99
|
+
* @param {Object} options - Configuration options for the complete agent list request
|
|
100
|
+
* @param {string} [options.accountId] - Account identifier
|
|
101
|
+
* @param {number} [options.version] - API version
|
|
102
|
+
*
|
|
103
|
+
* @returns {Promise<GetAgentsResponse>} Promise resolving to:
|
|
104
|
+
* - `data` - Array of partial agent objects with complete information
|
|
105
|
+
* - `last` - Optional pagination information
|
|
106
|
+
*
|
|
107
|
+
* @throws HITLAuthenticationError
|
|
108
|
+
* @throws HITLValidationError
|
|
109
|
+
* @throws HITLApiError
|
|
110
|
+
*
|
|
111
|
+
* @example
|
|
112
|
+
* ```typescript
|
|
113
|
+
* const response = await Agents.getCompleteAgents();
|
|
114
|
+
* ```
|
|
115
|
+
*
|
|
116
|
+
* @remarks
|
|
117
|
+
* Makes a GET request to the `/agents/complete` endpoint
|
|
118
|
+
* @public
|
|
98
119
|
*/
|
|
99
120
|
public static async getCompleteAgents(
|
|
100
121
|
options: GetCompleteAgentsOptions = {},
|
|
@@ -111,11 +132,33 @@ export class Agents extends HITLBase {
|
|
|
111
132
|
}
|
|
112
133
|
|
|
113
134
|
/**
|
|
114
|
-
*
|
|
115
|
-
*
|
|
135
|
+
* Get Agent with full info (additional data from Users API DB)
|
|
136
|
+
*
|
|
137
|
+
* @param {Object} options - Configuration options for retrieving a complete agent
|
|
138
|
+
* @param {string} options.agentId - Required identifier of the agent to retrieve
|
|
139
|
+
* @param {string} [options.multiUserId] - Optional multi-user identifier
|
|
140
|
+
* @param {string} [options.accountId] - Optional account identifier
|
|
141
|
+
* @param {number} [options.version] - Optional API version
|
|
142
|
+
*
|
|
143
|
+
* @returns {Promise<Agent>} Promise resolving to a complete agent object
|
|
144
|
+
*
|
|
145
|
+
* @throws HITLAuthenticationError
|
|
146
|
+
* @throws HITLValidationError
|
|
147
|
+
* @throws HITLApiError
|
|
148
|
+
*
|
|
149
|
+
* @example
|
|
150
|
+
* ```typescript
|
|
151
|
+
* const agent = await Agents.getCompleteAgentById({
|
|
152
|
+
* agentId: 'agent123',
|
|
153
|
+
* multiUserId: 'multi456'
|
|
154
|
+
* });
|
|
155
|
+
* ```
|
|
156
|
+
*
|
|
157
|
+
* @remarks
|
|
158
|
+
* Makes a GET request to the `/agents/complete/:agentId` endpoint
|
|
159
|
+
* @public
|
|
116
160
|
*/
|
|
117
161
|
public static async getCompleteAgentById(
|
|
118
|
-
// FIXME: not sure accountId can exist here. Added hack to make it build
|
|
119
162
|
{ accountId, multiUserId, ...options }: GetCompleteAgentByIdOptions & { accountId?: string; },
|
|
120
163
|
): Promise<Agent> {
|
|
121
164
|
const baseUrl = this.getBaseUrl(options);
|
|
@@ -135,8 +178,33 @@ export class Agents extends HITLBase {
|
|
|
135
178
|
}
|
|
136
179
|
|
|
137
180
|
/**
|
|
138
|
-
*
|
|
139
|
-
*
|
|
181
|
+
* Search Agents by Rule Groups, status etc.
|
|
182
|
+
*
|
|
183
|
+
* @param {Object} options - Configuration options for the agent search request
|
|
184
|
+
* @param {string[]} [options.ruleGroups] - List of rule group identifiers to filter by
|
|
185
|
+
* @param {string} [options.status] - Agent status to filter by
|
|
186
|
+
* @param {string[]} [options.projection] - List of fields to include in the response
|
|
187
|
+
* @param {Object} [options.filter] - Additional filter criteria
|
|
188
|
+
* @param {number} [options.version] - API version
|
|
189
|
+
*
|
|
190
|
+
* @returns {Promise<SearchAgentsResponse>} Promise resolving to:
|
|
191
|
+
* - `data` - Array of partial agent objects matching the search criteria
|
|
192
|
+
*
|
|
193
|
+
* @throws HITLAuthenticationError
|
|
194
|
+
* @throws HITLValidationError
|
|
195
|
+
* @throws HITLApiError
|
|
196
|
+
*
|
|
197
|
+
* @example
|
|
198
|
+
* ```typescript
|
|
199
|
+
* const response = await Agents.searchAgents({
|
|
200
|
+
* status: 'BUSY',
|
|
201
|
+
* projection: ['id', 'name', 'statusData']
|
|
202
|
+
* });
|
|
203
|
+
* ```
|
|
204
|
+
*
|
|
205
|
+
* @remarks
|
|
206
|
+
* Makes a POST request to the `/agents/search` endpoint
|
|
207
|
+
* @public
|
|
140
208
|
*/
|
|
141
209
|
public static async searchAgents(
|
|
142
210
|
options: SearchAgentsOptions = {},
|
|
@@ -156,8 +224,36 @@ export class Agents extends HITLBase {
|
|
|
156
224
|
}
|
|
157
225
|
|
|
158
226
|
/**
|
|
159
|
-
*
|
|
160
|
-
*
|
|
227
|
+
* Update Agent
|
|
228
|
+
*
|
|
229
|
+
* @param {Object} options - Configuration options for the agent update
|
|
230
|
+
* @param {string} options.agentId - Required identifier of the agent to update
|
|
231
|
+
* @param {string[]} [options.ruleGroupIds] - Array of rule group identifiers to assign
|
|
232
|
+
* @param {string[]} [options.contactRuleGroupIds] - Array of contact rule group identifiers
|
|
233
|
+
* @param {Object} [options.meta] - Metadata object for the agent
|
|
234
|
+
* @param {number} [options.version] - API version
|
|
235
|
+
*
|
|
236
|
+
* @returns {Promise<UpdateAgentResponse>} Promise resolving to a partial agent object with updated information
|
|
237
|
+
*
|
|
238
|
+
* @throws HITLAuthenticationError
|
|
239
|
+
* @throws HITLValidationError
|
|
240
|
+
* @throws HITLApiError
|
|
241
|
+
*
|
|
242
|
+
* @example
|
|
243
|
+
* ```typescript
|
|
244
|
+
* const updatedAgent = await Agents.updateAgent({
|
|
245
|
+
* agentId: 'agent123',
|
|
246
|
+
* ruleGroupIds: ['group1', 'group2'],
|
|
247
|
+
* meta: {
|
|
248
|
+
* department: 'Support',
|
|
249
|
+
* skills: ['chat', 'voice']
|
|
250
|
+
* }
|
|
251
|
+
* });
|
|
252
|
+
* ```
|
|
253
|
+
*
|
|
254
|
+
* @remarks
|
|
255
|
+
* Makes a PUT request to the `/agents` endpoint with agentId as a query parameter
|
|
256
|
+
* @public
|
|
161
257
|
*/
|
|
162
258
|
public static async updateAgent(
|
|
163
259
|
{ agentId, ...options }: UpdateAgentOptions,
|
|
@@ -177,8 +273,32 @@ export class Agents extends HITLBase {
|
|
|
177
273
|
}
|
|
178
274
|
|
|
179
275
|
/**
|
|
180
|
-
*
|
|
181
|
-
*
|
|
276
|
+
* Update Rule Groups for Agent
|
|
277
|
+
*
|
|
278
|
+
* @param {Object} options - Configuration options for updating agent rule groups
|
|
279
|
+
* @param {string} options.agentId - Required identifier of the agent
|
|
280
|
+
* @param {string[]} [options.addRuleGroupIds] - Array of rule group IDs to add
|
|
281
|
+
* @param {string[]} [options.removeRuleGroupIds] - Array of rule group IDs to remove
|
|
282
|
+
* @param {number} [options.version] - API version
|
|
283
|
+
*
|
|
284
|
+
* @returns {Promise<UpdateAgentRuleGroupsResponse>} Promise resolving to a partial agent object with updated rule groups
|
|
285
|
+
*
|
|
286
|
+
* @throws HITLAuthenticationError
|
|
287
|
+
* @throws HITLValidationError
|
|
288
|
+
* @throws HITLApiError
|
|
289
|
+
*
|
|
290
|
+
* @example
|
|
291
|
+
* ```typescript
|
|
292
|
+
* const updatedAgent = await Agents.updateAgentRuleGroups({
|
|
293
|
+
* agentId: 'agent123',
|
|
294
|
+
* addRuleGroupIds: ['group1', 'group2'],
|
|
295
|
+
* removeRuleGroupIds: ['group3', 'group4']
|
|
296
|
+
* });
|
|
297
|
+
* ```
|
|
298
|
+
*
|
|
299
|
+
* @remarks
|
|
300
|
+
* Makes a PUT request to the `/agents/rule-groups` endpoint with agentId as a query parameter
|
|
301
|
+
* @public
|
|
182
302
|
*/
|
|
183
303
|
public static async updateAgentRuleGroups(
|
|
184
304
|
{ agentId, ...options }: UpdateAgentRuleGroupsOptions,
|
|
@@ -199,8 +319,29 @@ export class Agents extends HITLBase {
|
|
|
199
319
|
}
|
|
200
320
|
|
|
201
321
|
/**
|
|
202
|
-
*
|
|
203
|
-
*
|
|
322
|
+
* Get Agent status
|
|
323
|
+
*
|
|
324
|
+
* @param {Object} options - Configuration options for retrieving agent status
|
|
325
|
+
* @param {string} [options.agentId] - Identifier of the agent to get status for
|
|
326
|
+
* @param {number} [options.version] - API version
|
|
327
|
+
*
|
|
328
|
+
* @returns {Promise<GetAgentStatusResponse>} Promise resolving to agent status object
|
|
329
|
+
*
|
|
330
|
+
* @throws HITLAuthenticationError
|
|
331
|
+
* @throws HITLValidationError
|
|
332
|
+
* @throws HITLApiError
|
|
333
|
+
*
|
|
334
|
+
* @example
|
|
335
|
+
* ```typescript
|
|
336
|
+
* const status = await Agents.getAgentStatus({
|
|
337
|
+
* agentId: 'agent123',
|
|
338
|
+
* version: 2
|
|
339
|
+
* });
|
|
340
|
+
* ```
|
|
341
|
+
*
|
|
342
|
+
* @remarks
|
|
343
|
+
* Makes a GET request to the `/agents/agent-status` endpoint or `/agents/status` endpoint if version is 2
|
|
344
|
+
* @public
|
|
204
345
|
*/
|
|
205
346
|
public static async getAgentStatus(
|
|
206
347
|
options: AgentStatusOptions = {},
|
|
@@ -220,8 +361,28 @@ export class Agents extends HITLBase {
|
|
|
220
361
|
}
|
|
221
362
|
|
|
222
363
|
/**
|
|
223
|
-
*
|
|
224
|
-
*
|
|
364
|
+
* Send an Agent status "ping" message to keep Agent "online"
|
|
365
|
+
*
|
|
366
|
+
* @param {Object} options - Configuration options for the agent status ping
|
|
367
|
+
* @param {string} [options.agentId] - Identifier of the agent to ping
|
|
368
|
+
* @param {number} [options.version] - API version
|
|
369
|
+
*
|
|
370
|
+
* @returns {Promise<GetAgentStatusResponse>} Promise resolving to updated agent status
|
|
371
|
+
*
|
|
372
|
+
* @throws HITLAuthenticationError
|
|
373
|
+
* @throws HITLValidationError
|
|
374
|
+
* @throws HITLApiError
|
|
375
|
+
*
|
|
376
|
+
* @example
|
|
377
|
+
* ```typescript
|
|
378
|
+
* const status = await Agents.pingAgentStatus({
|
|
379
|
+
* agentId: 'agent123'
|
|
380
|
+
* });
|
|
381
|
+
* ```
|
|
382
|
+
*
|
|
383
|
+
* @remarks
|
|
384
|
+
* Makes a PUT request to the `/agents/ping-agent-status` endpoint
|
|
385
|
+
* @public
|
|
225
386
|
*/
|
|
226
387
|
public static async pingAgentStatus(
|
|
227
388
|
options: AgentStatusOptions = {},
|
|
@@ -239,8 +400,40 @@ export class Agents extends HITLBase {
|
|
|
239
400
|
}
|
|
240
401
|
|
|
241
402
|
/**
|
|
242
|
-
*
|
|
243
|
-
*
|
|
403
|
+
* Set Agent status
|
|
404
|
+
*
|
|
405
|
+
* @param {Object} options - Configuration options for setting agent status
|
|
406
|
+
* @param {string} options.agentId - Required identifier of the agent to update
|
|
407
|
+
* @param {Object} options.statusData - Required status data object
|
|
408
|
+
* @param {string} options.statusData.status - Agent status value
|
|
409
|
+
* @param {string} [options.statusData.busyReason] - Reason for busy status
|
|
410
|
+
* @param {number} [options.statusData.expireIn] - Time in seconds until status expires
|
|
411
|
+
* @param {boolean} [options.notifyStatusChange] - Flag to notify about status change
|
|
412
|
+
* @param {Object} [options.statusChangeContext] - Context data for status change
|
|
413
|
+
* @param {number} [options.version] - API version
|
|
414
|
+
*
|
|
415
|
+
* @returns {Promise<void>} Promise that resolves when status is successfully set
|
|
416
|
+
*
|
|
417
|
+
* @throws HITLAuthenticationError
|
|
418
|
+
* @throws HITLValidationError
|
|
419
|
+
* @throws HITLApiError
|
|
420
|
+
*
|
|
421
|
+
* @example
|
|
422
|
+
* ```typescript
|
|
423
|
+
* await Agents.setAgentStatus({
|
|
424
|
+
* agentId: 'agent123',
|
|
425
|
+
* notifyStatusChange: false,
|
|
426
|
+
* statusData: {
|
|
427
|
+
* status: 'BUSY',
|
|
428
|
+
* busyReason: 'In meeting',
|
|
429
|
+
* expireIn: 3600
|
|
430
|
+
* }
|
|
431
|
+
* });
|
|
432
|
+
* ```
|
|
433
|
+
*
|
|
434
|
+
* @remarks
|
|
435
|
+
* Makes a PUT request to the `/agents/status` endpoint with agentId as a query parameter
|
|
436
|
+
* @public
|
|
244
437
|
*/
|
|
245
438
|
public static async setAgentStatus(
|
|
246
439
|
{ agentId, ...options }: SetAgentStatusOptions,
|
|
@@ -261,8 +454,32 @@ export class Agents extends HITLBase {
|
|
|
261
454
|
}
|
|
262
455
|
|
|
263
456
|
/**
|
|
264
|
-
*
|
|
265
|
-
*
|
|
457
|
+
* Update Agents status by providing a raw SQL query
|
|
458
|
+
*
|
|
459
|
+
* @param {Object} options - Configuration options for updating agents' status
|
|
460
|
+
* @param {string} options.query - Required SQL query or filter conditions to select agents
|
|
461
|
+
* @param {Object} [options.statusChangeContext] - Context data for status change
|
|
462
|
+
* @param {number} [options.maxRetries=3] - Number of retry attempts for concurrent updates
|
|
463
|
+
* @param {number} [options.version] - API version
|
|
464
|
+
*
|
|
465
|
+
* @returns {Promise<any>} Promise resolving to the result of the batch update operation
|
|
466
|
+
*
|
|
467
|
+
* @throws HITLAuthenticationError
|
|
468
|
+
* @throws HITLValidationError
|
|
469
|
+
* @throws HITLApiError
|
|
470
|
+
*
|
|
471
|
+
* @example
|
|
472
|
+
* ```typescript
|
|
473
|
+
* const result = await Agents.updateAgentsStatusByQuery({
|
|
474
|
+
* query: `UPDATE hitl.agents SET status_data = jsonb_set(status_data, '{key}', '"busy"') WHERE status_data->>'key'='available' RETURNING*`,
|
|
475
|
+
* maxRetries: 5,
|
|
476
|
+
* version: 2
|
|
477
|
+
* });
|
|
478
|
+
* ```
|
|
479
|
+
*
|
|
480
|
+
* @remarks
|
|
481
|
+
* Makes a PUT request to the `/agents/status/query` endpoint with retry mechanism for concurrent updates
|
|
482
|
+
* @public
|
|
266
483
|
*/
|
|
267
484
|
public static async updateAgentsStatusByQuery(
|
|
268
485
|
{ maxRetries = 3, ...options }: UpdateAgentsStatusByQueryOptions,
|
package/src/types/agents.ts
CHANGED
|
@@ -9,12 +9,9 @@ import { ApiVersionOptions, NoAccountId } from './common';
|
|
|
9
9
|
|
|
10
10
|
/* eslint-disable @typescript-eslint/no-empty-object-type */
|
|
11
11
|
export interface Agent extends Omit<Agents.IAgent, 'agentId'> {}
|
|
12
|
-
// export type Agent = Omit<Agents.IAgent, 'agentId'>;
|
|
13
12
|
export type DefaultMeta = object;
|
|
14
13
|
export interface DefaultStatusChangeContext extends Agents.IStatusChangeContext {}
|
|
15
14
|
|
|
16
|
-
// export type DefaultStatusChangeContext = Agents.IStatusChangeContext;
|
|
17
|
-
|
|
18
15
|
export interface GetAgentsResponse {
|
|
19
16
|
readonly data: Partial<Agent>[];
|
|
20
17
|
readonly last?: {
|
|
@@ -26,9 +23,6 @@ export interface GetAgentsResponse {
|
|
|
26
23
|
export interface GetAgentsOptions
|
|
27
24
|
extends ApiVersionOptions,
|
|
28
25
|
NoAccountId<Agents.IGetAgentsOptions> {}
|
|
29
|
-
// export type GetAgentsOptions = ApiVersionOptions
|
|
30
|
-
// & NoAccountId<Agents.IGetAgentsOptions>;
|
|
31
|
-
|
|
32
26
|
|
|
33
27
|
export interface GetCompleteAgentsOptions extends ApiVersionOptions {
|
|
34
28
|
readonly accountId?: string;
|
|
@@ -38,9 +32,6 @@ export interface GetCompleteAgentByIdOptions
|
|
|
38
32
|
extends ApiVersionOptions,
|
|
39
33
|
Agents.IGetCompleteAgentByIdParams,
|
|
40
34
|
NoAccountId<Agents.IGetCompleteAgentByIdQuery>{}
|
|
41
|
-
// export type GetCompleteAgentByIdOptions = ApiVersionOptions
|
|
42
|
-
// & Agents.IGetCompleteAgentByIdParams
|
|
43
|
-
// & NoAccountId<Agents.IGetCompleteAgentByIdQuery>;
|
|
44
35
|
|
|
45
36
|
export interface SearchAgentsResponse {
|
|
46
37
|
readonly data: Partial<Agent>[];
|
|
@@ -48,28 +39,19 @@ export interface SearchAgentsResponse {
|
|
|
48
39
|
export interface SearchAgentsOptions
|
|
49
40
|
extends ApiVersionOptions,
|
|
50
41
|
Agents.ISearchAgentsBody{}
|
|
51
|
-
// export type SearchAgentsOptions = ApiVersionOptions
|
|
52
|
-
// & Agents.ISearchAgentsBody;
|
|
53
42
|
|
|
54
43
|
export interface UpdateAgentResponse
|
|
55
44
|
extends Partial<Agent>{}
|
|
56
|
-
// export type UpdateAgentResponse = Partial<Agent>;
|
|
57
45
|
export interface UpdateAgentOptions
|
|
58
46
|
extends ApiVersionOptions,
|
|
59
47
|
NoAccountId<Agents.IPutAgentQuery>,
|
|
60
48
|
Agents.IPutAgentBody{}
|
|
61
|
-
// export type UpdateAgentOptions = ApiVersionOptions
|
|
62
|
-
// & NoAccountId<Agents.IPutAgentQuery>
|
|
63
|
-
// & Agents.IPutAgentBody;
|
|
64
49
|
|
|
65
50
|
export interface UpdateAgentRuleGroupsResponse
|
|
66
51
|
extends Partial<Agent>{}
|
|
67
|
-
// export type UpdateAgentRuleGroupsResponse = Partial<Agent>;
|
|
68
52
|
export interface UpdateAgentRuleGroupsOptions
|
|
69
53
|
extends ApiVersionOptions,
|
|
70
54
|
NoAccountId<Agents.IPutAgentRuleGroupsOptions>{}
|
|
71
|
-
// export type UpdateAgentRuleGroupsOptions = ApiVersionOptions
|
|
72
|
-
// & NoAccountId<Agents.IPutAgentRuleGroupsOptions>;
|
|
73
55
|
|
|
74
56
|
// export type GetAgentStatusResponse = Agents.IAgentStatus | Agents.AgentStatus;
|
|
75
57
|
export interface GetAgentStatusResponse extends Agents.AgentStatus {}
|
|
@@ -89,13 +71,10 @@ export interface UpdateAgentsStatusByQueryOptions extends
|
|
|
89
71
|
readonly maxRetries?: number;
|
|
90
72
|
}
|
|
91
73
|
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
// & Agents.IUpdateAgentsStatusBody
|
|
99
|
-
// & { readonly maxRetries?: number; };
|
|
100
|
-
|
|
74
|
+
/**
|
|
75
|
+
* Re-exported enums and types from @onereach/types-hitl-api
|
|
76
|
+
* @enum AGENT_STATUS - Agent status enum
|
|
77
|
+
* @enum AGENT_BROADCAST_EVENTS - Agent broadcast events enum
|
|
78
|
+
* @enum USER_ROLE - User role enum
|
|
79
|
+
*/
|
|
101
80
|
export { AGENT_STATUS, AGENT_BROADCAST_EVENTS, USER_ROLE };
|