@epilot/sdk 2.20.83 → 2.20.85

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.
Files changed (155) hide show
  1. package/definitions/integration-toolkit.json +69 -2
  2. package/definitions/phone-integration-runtime.json +1 -1
  3. package/definitions/phone-integration.json +1485 -341
  4. package/dist/apis/access-token.cjs +6 -6
  5. package/dist/apis/access-token.js +1 -1
  6. package/dist/apis/address-suggestions.cjs +6 -6
  7. package/dist/apis/address-suggestions.js +1 -1
  8. package/dist/apis/address.cjs +6 -6
  9. package/dist/apis/address.js +1 -1
  10. package/dist/apis/ai-agents.cjs +6 -6
  11. package/dist/apis/ai-agents.js +1 -1
  12. package/dist/apis/app.cjs +6 -6
  13. package/dist/apis/app.js +1 -1
  14. package/dist/apis/audit-logs.cjs +6 -6
  15. package/dist/apis/audit-logs.js +1 -1
  16. package/dist/apis/automation.cjs +6 -6
  17. package/dist/apis/automation.js +1 -1
  18. package/dist/apis/billing.cjs +6 -6
  19. package/dist/apis/billing.js +1 -1
  20. package/dist/apis/blueprint-manifest.cjs +6 -6
  21. package/dist/apis/blueprint-manifest.js +1 -1
  22. package/dist/apis/calendar.cjs +6 -6
  23. package/dist/apis/calendar.js +1 -1
  24. package/dist/apis/chat.cjs +6 -6
  25. package/dist/apis/chat.js +1 -1
  26. package/dist/apis/configuration-hub.cjs +6 -6
  27. package/dist/apis/configuration-hub.js +1 -1
  28. package/dist/apis/consent.cjs +6 -6
  29. package/dist/apis/consent.js +1 -1
  30. package/dist/apis/customer-portal.cjs +6 -6
  31. package/dist/apis/customer-portal.js +1 -1
  32. package/dist/apis/dashboard.cjs +6 -6
  33. package/dist/apis/dashboard.js +1 -1
  34. package/dist/apis/data-governance.cjs +6 -6
  35. package/dist/apis/data-governance.js +1 -1
  36. package/dist/apis/deduplication.cjs +6 -6
  37. package/dist/apis/deduplication.js +1 -1
  38. package/dist/apis/design.cjs +6 -6
  39. package/dist/apis/design.js +1 -1
  40. package/dist/apis/document.cjs +6 -6
  41. package/dist/apis/document.js +1 -1
  42. package/dist/apis/email-settings.cjs +6 -6
  43. package/dist/apis/email-settings.js +1 -1
  44. package/dist/apis/email-template.cjs +6 -6
  45. package/dist/apis/email-template.js +1 -1
  46. package/dist/apis/entity-mapping.cjs +6 -6
  47. package/dist/apis/entity-mapping.js +1 -1
  48. package/dist/apis/entity.cjs +6 -6
  49. package/dist/apis/entity.js +1 -1
  50. package/dist/apis/environments.cjs +6 -6
  51. package/dist/apis/environments.js +1 -1
  52. package/dist/apis/event-catalog.cjs +6 -6
  53. package/dist/apis/event-catalog.js +1 -1
  54. package/dist/apis/external-values.cjs +6 -6
  55. package/dist/apis/external-values.js +1 -1
  56. package/dist/apis/file.cjs +6 -6
  57. package/dist/apis/file.js +1 -1
  58. package/dist/apis/iban.cjs +6 -6
  59. package/dist/apis/iban.js +1 -1
  60. package/dist/apis/identity.cjs +6 -6
  61. package/dist/apis/identity.js +1 -1
  62. package/dist/apis/integration-toolkit.cjs +76 -7
  63. package/dist/apis/integration-toolkit.d.cts +2 -2
  64. package/dist/apis/integration-toolkit.d.ts +2 -2
  65. package/dist/apis/integration-toolkit.js +71 -2
  66. package/dist/apis/journey.cjs +6 -6
  67. package/dist/apis/journey.js +1 -1
  68. package/dist/apis/kanban.cjs +6 -6
  69. package/dist/apis/kanban.js +1 -1
  70. package/dist/apis/message.cjs +6 -6
  71. package/dist/apis/message.js +1 -1
  72. package/dist/apis/metering.cjs +6 -6
  73. package/dist/apis/metering.js +1 -1
  74. package/dist/apis/notes.cjs +6 -6
  75. package/dist/apis/notes.js +1 -1
  76. package/dist/apis/notification.cjs +6 -6
  77. package/dist/apis/notification.js +1 -1
  78. package/dist/apis/organization.cjs +6 -6
  79. package/dist/apis/organization.js +1 -1
  80. package/dist/apis/partner-directory.cjs +6 -6
  81. package/dist/apis/partner-directory.js +1 -1
  82. package/dist/apis/permissions.cjs +6 -6
  83. package/dist/apis/permissions.js +1 -1
  84. package/dist/apis/phone-integration.cjs +8 -8
  85. package/dist/apis/phone-integration.d.cts +2 -2
  86. package/dist/apis/phone-integration.d.ts +2 -2
  87. package/dist/apis/phone-integration.js +2 -2
  88. package/dist/apis/pricing-tier.cjs +6 -6
  89. package/dist/apis/pricing-tier.js +1 -1
  90. package/dist/apis/pricing.cjs +6 -6
  91. package/dist/apis/pricing.js +1 -1
  92. package/dist/apis/purpose.cjs +6 -6
  93. package/dist/apis/purpose.js +1 -1
  94. package/dist/apis/query.cjs +6 -6
  95. package/dist/apis/query.js +1 -1
  96. package/dist/apis/sandbox.cjs +6 -6
  97. package/dist/apis/sandbox.js +1 -1
  98. package/dist/apis/sharing.cjs +6 -6
  99. package/dist/apis/sharing.js +1 -1
  100. package/dist/apis/snapshot.cjs +6 -6
  101. package/dist/apis/snapshot.js +1 -1
  102. package/dist/apis/submission.cjs +6 -6
  103. package/dist/apis/submission.js +1 -1
  104. package/dist/apis/target.cjs +6 -6
  105. package/dist/apis/target.js +1 -1
  106. package/dist/apis/targeting.cjs +6 -6
  107. package/dist/apis/targeting.js +1 -1
  108. package/dist/apis/template-variables.cjs +6 -6
  109. package/dist/apis/template-variables.js +1 -1
  110. package/dist/apis/user.cjs +6 -6
  111. package/dist/apis/user.js +1 -1
  112. package/dist/apis/validation-rules.cjs +6 -6
  113. package/dist/apis/validation-rules.js +1 -1
  114. package/dist/apis/webhooks.cjs +6 -6
  115. package/dist/apis/webhooks.js +1 -1
  116. package/dist/apis/workflow-definition.cjs +6 -6
  117. package/dist/apis/workflow-definition.js +1 -1
  118. package/dist/apis/workflow.cjs +6 -6
  119. package/dist/apis/workflow.js +1 -1
  120. package/dist/{chunk-HFBZFYTU.js → chunk-7T4BNWMN.js} +3 -6
  121. package/dist/chunk-E6N33SVB.js +14 -0
  122. package/dist/chunk-U4AOZZGW.cjs +14 -0
  123. package/dist/{chunk-KGIFSOWS.cjs → chunk-ZSZ4IWLQ.cjs} +3 -6
  124. package/dist/index.cjs +10 -10
  125. package/dist/index.d.cts +2 -2
  126. package/dist/index.d.ts +2 -2
  127. package/dist/index.js +2 -2
  128. package/dist/integration-toolkit-DER5W7ID.cjs +7 -0
  129. package/dist/integration-toolkit-EMCDJARR.js +7 -0
  130. package/dist/{integration-toolkit.d-BGF0LVB7.d.cts → integration-toolkit.d-BJgyGgcU.d.cts} +45 -2
  131. package/dist/{integration-toolkit.d-BGF0LVB7.d.ts → integration-toolkit.d-BJgyGgcU.d.ts} +45 -2
  132. package/dist/phone-integration-6GDKV5EH.js +7 -0
  133. package/dist/phone-integration-UENU7EVN.cjs +7 -0
  134. package/dist/{phone-integration-runtime-7PWKKUBM.cjs → phone-integration-runtime-4SDHGFMR.cjs} +2 -2
  135. package/dist/{phone-integration-runtime-5VAA6Q4L.js → phone-integration-runtime-PWUZOJVD.js} +1 -1
  136. package/dist/phone-integration.d-Cx4ZOtzD.d.cts +1429 -0
  137. package/dist/phone-integration.d-Cx4ZOtzD.d.ts +1429 -0
  138. package/docs/integration-toolkit.md +54 -8
  139. package/docs/phone-integration.md +772 -0
  140. package/package.json +1 -1
  141. package/dist/chunk-NHA2IXWN.cjs +0 -14
  142. package/dist/chunk-QFTXKO2I.js +0 -14
  143. package/dist/erp-integration-735KQ73W.js +0 -5295
  144. package/dist/erp-integration-PAVHSUDM.cjs +0 -7
  145. package/dist/erp-integration-SBQJ6HEG.js +0 -7
  146. package/dist/erp-integration-W7FZDJOB.cjs +0 -5295
  147. package/dist/erp-integration-runtime-JGVGQ22V.js +0 -13
  148. package/dist/erp-integration-runtime-OZ4YSTQX.cjs +0 -13
  149. package/dist/integration-toolkit-3XNG4PL5.cjs +0 -7
  150. package/dist/integration-toolkit-VLTS5HKV.js +0 -7
  151. package/dist/phone-integration-ARSGAHNJ.cjs +0 -7
  152. package/dist/phone-integration-MGH7LYID.js +0 -7
  153. package/dist/phone-integration.d-BNqwHuQ6.d.cts +0 -623
  154. package/dist/phone-integration.d-BNqwHuQ6.d.ts +0 -623
  155. package/docs/erp-integration.md +0 -6011
@@ -1,623 +0,0 @@
1
- import { OpenAPIClient, Parameters, AxiosRequestConfig, OperationResponse, UnknownParamsObject } from 'openapi-client-axios';
2
-
3
- /* Auto-copied from phone-integration-client */
4
-
5
-
6
- declare namespace Components {
7
- namespace Responses {
8
- export type BadGateway = Schemas.ErrorResponse;
9
- export type BadRequest = Schemas.ErrorResponse;
10
- export type Forbidden = Schemas.ErrorResponse;
11
- export type ServiceUnavailable = Schemas.ErrorResponse;
12
- export type Unauthorized = Schemas.ErrorResponse;
13
- }
14
- namespace Schemas {
15
- export interface AssignPhoneAgentRequest {
16
- /**
17
- * epilot user id of an active member of the caller's organization
18
- */
19
- user_id: string; // ^[A-Za-z0-9_-]+$
20
- }
21
- export interface CustomerBatchSearchResult {
22
- /**
23
- * One result per distinct identifier
24
- */
25
- results: CustomerSearchResult[];
26
- }
27
- export interface CustomerIdentifier {
28
- type: "id" | "customer_number" | "external_id" | "phone_number" | "email";
29
- /**
30
- * The identifier as sent
31
- * example:
32
- * +4917012345678
33
- */
34
- value: string;
35
- }
36
- export interface CustomerSearchResult {
37
- identifier: CustomerIdentifier;
38
- /**
39
- * - `found` — exactly one contact has the identifier; see `customer`
40
- * - `not_found` — no contact the caller may see has it
41
- * - `ambiguous` — several contacts share it; none is chosen
42
- * - `invalid` — not a usable identifier (a phone number that does
43
- * not parse), so nothing was searched
44
- * - `error` — the search for this identifier failed; try again
45
- *
46
- */
47
- status: "found" | "not_found" | "ambiguous" | "invalid" | "error";
48
- customer?: /* Present when `status` is `found` */ CustomerSummary;
49
- }
50
- /**
51
- * Present when `status` is `found`
52
- */
53
- export interface CustomerSummary {
54
- /**
55
- * epilot entity id of the customer (Contact)
56
- * example:
57
- * dba8e5f9-8b3f-4608-b887-cd0798fce624
58
- */
59
- id: string;
60
- /**
61
- * The contact's title, else its first and last name; null when it has neither
62
- * example:
63
- * Max Mustermann
64
- */
65
- name: string | null;
66
- /**
67
- * Omitted when the contact has none
68
- * example:
69
- * 4711
70
- */
71
- customer_number?: string;
72
- }
73
- export interface ErrorResponse {
74
- /**
75
- * HTTP status code.
76
- */
77
- status: number;
78
- /**
79
- * Human-readable error message.
80
- */
81
- error: string;
82
- /**
83
- * Stable machine-readable error code, when the operation defines one.
84
- */
85
- code?: string;
86
- }
87
- export interface ManagerStatus {
88
- /**
89
- * Telephony provider behind this organization
90
- */
91
- provider: "babelforce";
92
- /**
93
- * Agents can be assigned
94
- */
95
- ready: boolean;
96
- /**
97
- * Why the organization is not ready (empty when ready)
98
- */
99
- reasons: ("provider_tenant_missing" | "sso_not_configured" | "scim_not_configured" | "identity_enablement_missing")[];
100
- }
101
- export interface PhoneAgent {
102
- /**
103
- * epilot user id
104
- */
105
- user_id: string;
106
- email: string;
107
- display_name?: string;
108
- /**
109
- * `active`: holds the phone and has an enabled provider user. `pending`: assigned in epilot but
110
- * the provider user is not activated yet. `disabled`: provider user disabled. `missing_provider`:
111
- * holds `phone:use` but no provider user is bound (assign again to repair). `missing_role`:
112
- * assigned here, but the `phone_agent` role (`phone:use`) was removed elsewhere, e.g. in the
113
- * users and permissions settings (assign again to restore it, or remove to deactivate the
114
- * provider user).
115
- *
116
- */
117
- status: "active" | "pending" | "disabled" | "missing_provider" | "missing_role";
118
- /**
119
- * The provider's id of the bound user
120
- */
121
- provider_user_id?: string;
122
- provider_roles?: string[];
123
- assigned_at?: string; // date-time
124
- /**
125
- * epilot user id of the manager who assigned the phone
126
- */
127
- assigned_by?: string;
128
- }
129
- export interface ProviderSetup {
130
- provider: "babelforce";
131
- org_id: string;
132
- /**
133
- * Everything below is in place
134
- */
135
- ready: boolean;
136
- /**
137
- * The provider tenant for this organization (null until created)
138
- */
139
- tenant: {
140
- id: string;
141
- name: string;
142
- org_key: string;
143
- created_at?: string; // date-time
144
- } | null;
145
- scim: {
146
- configured: boolean;
147
- roles_enabled: boolean;
148
- };
149
- sso: {
150
- configured: boolean;
151
- /**
152
- * The identity-api client the tenant's SSO configuration points at
153
- */
154
- identity_client_id?: string;
155
- configured_at?: string; // date-time
156
- };
157
- /**
158
- * Admin-portal operator (email) who last ran the setup
159
- */
160
- last_setup_by?: string;
161
- }
162
- export interface ProviderSetupRequest {
163
- /**
164
- * Provider tenant name, unique across the provider (3 to 100 characters). Required the first
165
- * time (`400` with code `account_name_required` without it); ignored once the tenant exists.
166
- *
167
- */
168
- account_name?: string;
169
- /**
170
- * identity-api client registered for the provider (its partner application for this stage)
171
- */
172
- identity_client_id: string; // ^[A-Za-z0-9._~-]+$
173
- /**
174
- * The client's current secret, forwarded to the provider's SSO configuration and never stored
175
- */
176
- identity_client_secret: string;
177
- }
178
- /**
179
- * One organization's provider setup, as listed in the overview (no live SCIM or SSO reads).
180
- */
181
- export interface ProviderSetupSummary {
182
- /**
183
- * epilot organization id (the provider tenant's org key)
184
- */
185
- org_id: string;
186
- provider: "babelforce";
187
- /**
188
- * Phone agents can be assigned (same rule as getManagerStatus)
189
- */
190
- ready: boolean;
191
- /**
192
- * `setupProvider` has run for this organization at least once. `false` for a tenant created by
193
- * hand at the provider: run the setup once to record it.
194
- *
195
- */
196
- setup_recorded: boolean;
197
- tenant: {
198
- /**
199
- * The provider's tenant id (Babelforce sub-account id)
200
- */
201
- id: string;
202
- name: string;
203
- org_key: string;
204
- };
205
- /**
206
- * The identity-api client the recorded SSO configuration points at
207
- */
208
- sso_identity_client_id?: string;
209
- /**
210
- * The operator who last ran the setup (email)
211
- */
212
- last_setup_by?: string;
213
- /**
214
- * When the setup record last changed
215
- */
216
- updated_at?: string; // date-time
217
- }
218
- }
219
- }
220
- declare namespace Paths {
221
- namespace AssignPhoneAgent {
222
- export type RequestBody = Components.Schemas.AssignPhoneAgentRequest;
223
- namespace Responses {
224
- export type $200 = Components.Schemas.PhoneAgent;
225
- export type $201 = Components.Schemas.PhoneAgent;
226
- export type $400 = Components.Responses.BadRequest;
227
- export type $401 = Components.Responses.Unauthorized;
228
- export type $403 = Components.Responses.Forbidden;
229
- export type $404 = Components.Schemas.ErrorResponse;
230
- export type $409 = Components.Schemas.ErrorResponse;
231
- export type $502 = Components.Responses.BadGateway;
232
- }
233
- }
234
- namespace BatchSearchCustomers {
235
- export interface HeaderParameters {
236
- "x-trace-id"?: Parameters.XTraceId;
237
- }
238
- namespace Parameters {
239
- export type CustomerNumber = string[];
240
- export type Email = string[];
241
- export type ExternalId = string[];
242
- export type Id = string[];
243
- export type PhoneNumber = string[];
244
- export type XTraceId = string;
245
- }
246
- export interface QueryParameters {
247
- id?: Parameters.Id;
248
- customer_number?: Parameters.CustomerNumber;
249
- external_id?: Parameters.ExternalId;
250
- phone_number?: Parameters.PhoneNumber;
251
- email?: Parameters.Email;
252
- }
253
- namespace Responses {
254
- export type $200 = Components.Schemas.CustomerBatchSearchResult;
255
- export type $400 = Components.Schemas.ErrorResponse;
256
- export type $401 = Components.Schemas.ErrorResponse;
257
- export type $403 = Components.Schemas.ErrorResponse;
258
- }
259
- }
260
- namespace GetManagerStatus {
261
- namespace Responses {
262
- export type $200 = Components.Schemas.ManagerStatus;
263
- export type $401 = Components.Responses.Unauthorized;
264
- export type $403 = Components.Responses.Forbidden;
265
- }
266
- }
267
- namespace GetProviderSetup {
268
- namespace Responses {
269
- export type $200 = Components.Schemas.ProviderSetup;
270
- export type $400 = Components.Responses.BadRequest;
271
- export type $401 = Components.Responses.Unauthorized;
272
- export type $403 = Components.Responses.Forbidden;
273
- export type $502 = Components.Responses.BadGateway;
274
- export type $503 = Components.Responses.ServiceUnavailable;
275
- }
276
- }
277
- namespace ListPhoneAgents {
278
- namespace Responses {
279
- export interface $200 {
280
- results: Components.Schemas.PhoneAgent[];
281
- }
282
- export type $401 = Components.Responses.Unauthorized;
283
- export type $403 = Components.Responses.Forbidden;
284
- export type $502 = Components.Responses.BadGateway;
285
- }
286
- }
287
- namespace ListProviderSetups {
288
- namespace Responses {
289
- export interface $200 {
290
- results: /* One organization's provider setup, as listed in the overview (no live SCIM or SSO reads). */ Components.Schemas.ProviderSetupSummary[];
291
- }
292
- export type $401 = Components.Responses.Unauthorized;
293
- export type $403 = Components.Responses.Forbidden;
294
- export type $502 = Components.Responses.BadGateway;
295
- export type $503 = Components.Responses.ServiceUnavailable;
296
- }
297
- }
298
- namespace RemovePhoneAgent {
299
- namespace Responses {
300
- export interface $204 {
301
- }
302
- export type $400 = Components.Responses.BadRequest;
303
- export type $401 = Components.Responses.Unauthorized;
304
- export type $403 = Components.Responses.Forbidden;
305
- export type $404 = Components.Schemas.ErrorResponse;
306
- export type $502 = Components.Schemas.ErrorResponse;
307
- }
308
- }
309
- namespace SetupProvider {
310
- export type RequestBody = Components.Schemas.ProviderSetupRequest;
311
- namespace Responses {
312
- export type $200 = Components.Schemas.ProviderSetup;
313
- export type $400 = Components.Responses.BadRequest;
314
- export type $401 = Components.Responses.Unauthorized;
315
- export type $403 = Components.Responses.Forbidden;
316
- export type $409 = Components.Schemas.ErrorResponse;
317
- export type $502 = Components.Responses.BadGateway;
318
- export type $503 = Components.Responses.ServiceUnavailable;
319
- }
320
- }
321
- namespace V1ManagerAgents$UserId {
322
- namespace Parameters {
323
- export type UserId = string; // ^[A-Za-z0-9_-]+$
324
- }
325
- export interface PathParameters {
326
- user_id: Parameters.UserId /* ^[A-Za-z0-9_-]+$ */;
327
- }
328
- }
329
- namespace V1OperatorOrganizations$OrgIdProvider {
330
- namespace Parameters {
331
- export type OrgId = string; // ^[A-Za-z0-9_-]+$
332
- }
333
- export interface PathParameters {
334
- org_id: Parameters.OrgId /* ^[A-Za-z0-9_-]+$ */;
335
- }
336
- }
337
- namespace V1OperatorOrganizations$OrgIdProviderSetup {
338
- namespace Parameters {
339
- export type OrgId = string; // ^[A-Za-z0-9_-]+$
340
- }
341
- export interface PathParameters {
342
- org_id: Parameters.OrgId /* ^[A-Za-z0-9_-]+$ */;
343
- }
344
- }
345
- }
346
-
347
-
348
- interface OperationMethods {
349
- /**
350
- * batchSearchCustomers - batchSearchCustomers
351
- *
352
- * Resolves up to 50 identifiers to epilot customers (Contacts) in one
353
- * request — for example every number in an agent's call history.
354
- *
355
- * Each identifier is an exact key of a Contact: its entity `id`, its
356
- * `customer_number`, its `external_id`, one of its `email` addresses or
357
- * one of its `phone` numbers. Repeat a parameter to pass several values,
358
- * and combine parameters freely. Phone numbers are normalized on the
359
- * server, so E.164, national and formatted forms of one number match the
360
- * same contact; the other identifiers match exactly, ignoring case and
361
- * surrounding whitespace.
362
- *
363
- * Every distinct identifier gets its own result, so one unknown or
364
- * ambiguous identifier never fails the others. Results are ordered by
365
- * parameter (`id`, `customer_number`, `external_id`, `phone_number`,
366
- * `email`), then as sent; match them by `identifier`.
367
- *
368
- * The search runs with the caller's token: the organization and the
369
- * permissions applied are the caller's own, as for entity search.
370
- *
371
- */
372
- 'batchSearchCustomers'(
373
- parameters?: Parameters<Paths.BatchSearchCustomers.QueryParameters & Paths.BatchSearchCustomers.HeaderParameters> | null,
374
- data?: any,
375
- config?: AxiosRequestConfig
376
- ): OperationResponse<Paths.BatchSearchCustomers.Responses.$200>
377
- /**
378
- * getManagerStatus - getManagerStatus
379
- *
380
- * Whether the caller's organization is ready for phone agents: the telephony provider tenant
381
- * exists and is configured. The control center shows a "not set up" state when `ready` is false.
382
- * Requires `phone:manage`.
383
- *
384
- */
385
- 'getManagerStatus'(
386
- parameters?: Parameters<UnknownParamsObject> | null,
387
- data?: any,
388
- config?: AxiosRequestConfig
389
- ): OperationResponse<Paths.GetManagerStatus.Responses.$200>
390
- /**
391
- * listPhoneAgents - listPhoneAgents
392
- *
393
- * Organization members who hold the phone (`phone:use`), each joined with the provider user behind
394
- * them. Requires `phone:manage`.
395
- *
396
- */
397
- 'listPhoneAgents'(
398
- parameters?: Parameters<UnknownParamsObject> | null,
399
- data?: any,
400
- config?: AxiosRequestConfig
401
- ): OperationResponse<Paths.ListPhoneAgents.Responses.$200>
402
- /**
403
- * assignPhoneAgent - assignPhoneAgent
404
- *
405
- * Gives an organization member the phone. In order: the member is verified with user-api, their
406
- * pairwise subject for the provider is read from identity-api, the provider user is created (or
407
- * found) bound to that subject with the `agent` role, and only then the `phone_agent` role
408
- * (`phone:use`) is assigned in epilot. Idempotent: an already assigned member answers `200`.
409
- * Requires `phone:manage`.
410
- *
411
- */
412
- 'assignPhoneAgent'(
413
- parameters?: Parameters<UnknownParamsObject> | null,
414
- data?: Paths.AssignPhoneAgent.RequestBody,
415
- config?: AxiosRequestConfig
416
- ): OperationResponse<Paths.AssignPhoneAgent.Responses.$200 | Paths.AssignPhoneAgent.Responses.$201>
417
- /**
418
- * removePhoneAgent - removePhoneAgent
419
- *
420
- * Takes the phone away from a member: the `phone_agent` role is removed first, then the provider
421
- * user is deactivated (never deleted: call history keeps referring to it). Requires `phone:manage`.
422
- *
423
- */
424
- 'removePhoneAgent'(
425
- parameters?: Parameters<Paths.V1ManagerAgents$UserId.PathParameters> | null,
426
- data?: any,
427
- config?: AxiosRequestConfig
428
- ): OperationResponse<Paths.RemovePhoneAgent.Responses.$204>
429
- /**
430
- * listProviderSetups - listProviderSetups
431
- *
432
- * Every organization that has a telephony provider tenant, for the admin portal's overview: the
433
- * provider's sub-accounts (one per organization, keyed by the organization id) joined with this
434
- * service's setup record. `ready` follows getManagerStatus: an organization whose tenant was created
435
- * by hand, outside `setupProvider`, has no record and is not ready until the setup runs once.
436
- * Sorted by organization id; not paged (one tenant per organization, a few hundred at most).
437
- *
438
- */
439
- 'listProviderSetups'(
440
- parameters?: Parameters<UnknownParamsObject> | null,
441
- data?: any,
442
- config?: AxiosRequestConfig
443
- ): OperationResponse<Paths.ListProviderSetups.Responses.$200>
444
- /**
445
- * getProviderSetup - getProviderSetup
446
- *
447
- * What has been set up at the telephony provider for this organization.
448
- */
449
- 'getProviderSetup'(
450
- parameters?: Parameters<Paths.V1OperatorOrganizations$OrgIdProvider.PathParameters> | null,
451
- data?: any,
452
- config?: AxiosRequestConfig
453
- ): OperationResponse<Paths.GetProviderSetup.Responses.$200>
454
- /**
455
- * setupProvider - setupProvider
456
- *
457
- * Prepares the telephony provider for an organization, idempotently and in order: the provider
458
- * tenant (Babelforce sub-account keyed by the organization id), its SCIM configuration with role
459
- * management on, and its SSO configuration pointing at the identity-api client given here. The
460
- * client secret is forwarded to the provider and never stored by this service. Re-running updates
461
- * the SSO configuration (new client or rotated secret) and leaves the rest untouched.
462
- *
463
- */
464
- 'setupProvider'(
465
- parameters?: Parameters<Paths.V1OperatorOrganizations$OrgIdProviderSetup.PathParameters> | null,
466
- data?: Paths.SetupProvider.RequestBody,
467
- config?: AxiosRequestConfig
468
- ): OperationResponse<Paths.SetupProvider.Responses.$200>
469
- }
470
-
471
- interface PathsDictionary {
472
- ['/v1/customer:batchSearch']: {
473
- /**
474
- * batchSearchCustomers - batchSearchCustomers
475
- *
476
- * Resolves up to 50 identifiers to epilot customers (Contacts) in one
477
- * request — for example every number in an agent's call history.
478
- *
479
- * Each identifier is an exact key of a Contact: its entity `id`, its
480
- * `customer_number`, its `external_id`, one of its `email` addresses or
481
- * one of its `phone` numbers. Repeat a parameter to pass several values,
482
- * and combine parameters freely. Phone numbers are normalized on the
483
- * server, so E.164, national and formatted forms of one number match the
484
- * same contact; the other identifiers match exactly, ignoring case and
485
- * surrounding whitespace.
486
- *
487
- * Every distinct identifier gets its own result, so one unknown or
488
- * ambiguous identifier never fails the others. Results are ordered by
489
- * parameter (`id`, `customer_number`, `external_id`, `phone_number`,
490
- * `email`), then as sent; match them by `identifier`.
491
- *
492
- * The search runs with the caller's token: the organization and the
493
- * permissions applied are the caller's own, as for entity search.
494
- *
495
- */
496
- 'get'(
497
- parameters?: Parameters<Paths.BatchSearchCustomers.QueryParameters & Paths.BatchSearchCustomers.HeaderParameters> | null,
498
- data?: any,
499
- config?: AxiosRequestConfig
500
- ): OperationResponse<Paths.BatchSearchCustomers.Responses.$200>
501
- }
502
- ['/v1/manager/status']: {
503
- /**
504
- * getManagerStatus - getManagerStatus
505
- *
506
- * Whether the caller's organization is ready for phone agents: the telephony provider tenant
507
- * exists and is configured. The control center shows a "not set up" state when `ready` is false.
508
- * Requires `phone:manage`.
509
- *
510
- */
511
- 'get'(
512
- parameters?: Parameters<UnknownParamsObject> | null,
513
- data?: any,
514
- config?: AxiosRequestConfig
515
- ): OperationResponse<Paths.GetManagerStatus.Responses.$200>
516
- }
517
- ['/v1/manager/agents']: {
518
- /**
519
- * listPhoneAgents - listPhoneAgents
520
- *
521
- * Organization members who hold the phone (`phone:use`), each joined with the provider user behind
522
- * them. Requires `phone:manage`.
523
- *
524
- */
525
- 'get'(
526
- parameters?: Parameters<UnknownParamsObject> | null,
527
- data?: any,
528
- config?: AxiosRequestConfig
529
- ): OperationResponse<Paths.ListPhoneAgents.Responses.$200>
530
- /**
531
- * assignPhoneAgent - assignPhoneAgent
532
- *
533
- * Gives an organization member the phone. In order: the member is verified with user-api, their
534
- * pairwise subject for the provider is read from identity-api, the provider user is created (or
535
- * found) bound to that subject with the `agent` role, and only then the `phone_agent` role
536
- * (`phone:use`) is assigned in epilot. Idempotent: an already assigned member answers `200`.
537
- * Requires `phone:manage`.
538
- *
539
- */
540
- 'post'(
541
- parameters?: Parameters<UnknownParamsObject> | null,
542
- data?: Paths.AssignPhoneAgent.RequestBody,
543
- config?: AxiosRequestConfig
544
- ): OperationResponse<Paths.AssignPhoneAgent.Responses.$200 | Paths.AssignPhoneAgent.Responses.$201>
545
- }
546
- ['/v1/manager/agents/{user_id}']: {
547
- /**
548
- * removePhoneAgent - removePhoneAgent
549
- *
550
- * Takes the phone away from a member: the `phone_agent` role is removed first, then the provider
551
- * user is deactivated (never deleted: call history keeps referring to it). Requires `phone:manage`.
552
- *
553
- */
554
- 'delete'(
555
- parameters?: Parameters<Paths.V1ManagerAgents$UserId.PathParameters> | null,
556
- data?: any,
557
- config?: AxiosRequestConfig
558
- ): OperationResponse<Paths.RemovePhoneAgent.Responses.$204>
559
- }
560
- ['/v1/operator/provider-setups']: {
561
- /**
562
- * listProviderSetups - listProviderSetups
563
- *
564
- * Every organization that has a telephony provider tenant, for the admin portal's overview: the
565
- * provider's sub-accounts (one per organization, keyed by the organization id) joined with this
566
- * service's setup record. `ready` follows getManagerStatus: an organization whose tenant was created
567
- * by hand, outside `setupProvider`, has no record and is not ready until the setup runs once.
568
- * Sorted by organization id; not paged (one tenant per organization, a few hundred at most).
569
- *
570
- */
571
- 'get'(
572
- parameters?: Parameters<UnknownParamsObject> | null,
573
- data?: any,
574
- config?: AxiosRequestConfig
575
- ): OperationResponse<Paths.ListProviderSetups.Responses.$200>
576
- }
577
- ['/v1/operator/organizations/{org_id}/provider']: {
578
- /**
579
- * getProviderSetup - getProviderSetup
580
- *
581
- * What has been set up at the telephony provider for this organization.
582
- */
583
- 'get'(
584
- parameters?: Parameters<Paths.V1OperatorOrganizations$OrgIdProvider.PathParameters> | null,
585
- data?: any,
586
- config?: AxiosRequestConfig
587
- ): OperationResponse<Paths.GetProviderSetup.Responses.$200>
588
- }
589
- ['/v1/operator/organizations/{org_id}/provider:setup']: {
590
- /**
591
- * setupProvider - setupProvider
592
- *
593
- * Prepares the telephony provider for an organization, idempotently and in order: the provider
594
- * tenant (Babelforce sub-account keyed by the organization id), its SCIM configuration with role
595
- * management on, and its SSO configuration pointing at the identity-api client given here. The
596
- * client secret is forwarded to the provider and never stored by this service. Re-running updates
597
- * the SSO configuration (new client or rotated secret) and leaves the rest untouched.
598
- *
599
- */
600
- 'post'(
601
- parameters?: Parameters<Paths.V1OperatorOrganizations$OrgIdProviderSetup.PathParameters> | null,
602
- data?: Paths.SetupProvider.RequestBody,
603
- config?: AxiosRequestConfig
604
- ): OperationResponse<Paths.SetupProvider.Responses.$200>
605
- }
606
- }
607
-
608
- type Client = OpenAPIClient<OperationMethods, PathsDictionary>
609
-
610
-
611
- type AssignPhoneAgentRequest = Components.Schemas.AssignPhoneAgentRequest;
612
- type CustomerBatchSearchResult = Components.Schemas.CustomerBatchSearchResult;
613
- type CustomerIdentifier = Components.Schemas.CustomerIdentifier;
614
- type CustomerSearchResult = Components.Schemas.CustomerSearchResult;
615
- type CustomerSummary = Components.Schemas.CustomerSummary;
616
- type ErrorResponse = Components.Schemas.ErrorResponse;
617
- type ManagerStatus = Components.Schemas.ManagerStatus;
618
- type PhoneAgent = Components.Schemas.PhoneAgent;
619
- type ProviderSetup = Components.Schemas.ProviderSetup;
620
- type ProviderSetupRequest = Components.Schemas.ProviderSetupRequest;
621
- type ProviderSetupSummary = Components.Schemas.ProviderSetupSummary;
622
-
623
- export { type AssignPhoneAgentRequest as A, type Client as C, type ErrorResponse as E, type ManagerStatus as M, type OperationMethods as O, Paths as P, Components as a, type PathsDictionary as b, type CustomerBatchSearchResult as c, type CustomerIdentifier as d, type CustomerSearchResult as e, type CustomerSummary as f, type PhoneAgent as g, type ProviderSetup as h, type ProviderSetupRequest as i, type ProviderSetupSummary as j };