@l7mp/tivadar-ai-api-sdk 0.2.14 → 0.2.16

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 (86) hide show
  1. package/dist/api-client.d.ts +20 -1
  2. package/dist/api-client.js +13 -0
  3. package/dist/apis/AdminPhoneNumbersApi.d.ts +80 -1
  4. package/dist/apis/AdminPhoneNumbersApi.js +245 -1
  5. package/dist/apis/OutboundCallsApi.d.ts +32 -0
  6. package/dist/apis/OutboundCallsApi.js +77 -0
  7. package/dist/apis/SIPApi.d.ts +34 -1
  8. package/dist/apis/SIPApi.js +89 -1
  9. package/dist/apis/index.d.ts +1 -0
  10. package/dist/apis/index.js +1 -0
  11. package/dist/esm/api-client.d.ts +20 -1
  12. package/dist/esm/api-client.js +13 -0
  13. package/dist/esm/apis/AdminPhoneNumbersApi.d.ts +80 -1
  14. package/dist/esm/apis/AdminPhoneNumbersApi.js +245 -1
  15. package/dist/esm/apis/OutboundCallsApi.d.ts +32 -0
  16. package/dist/esm/apis/OutboundCallsApi.js +73 -0
  17. package/dist/esm/apis/SIPApi.d.ts +34 -1
  18. package/dist/esm/apis/SIPApi.js +89 -1
  19. package/dist/esm/apis/index.d.ts +1 -0
  20. package/dist/esm/apis/index.js +1 -0
  21. package/dist/esm/models/AdminPhoneNumberAssignOutbound.d.ts +32 -0
  22. package/dist/esm/models/AdminPhoneNumberAssignOutbound.js +43 -0
  23. package/dist/esm/models/AdminPhoneNumberDetail.d.ts +30 -0
  24. package/dist/esm/models/AdminPhoneNumberDetail.js +10 -0
  25. package/dist/esm/models/AdminPhoneNumberUpdate.d.ts +18 -0
  26. package/dist/esm/models/AdminPhoneNumberUpdate.js +6 -0
  27. package/dist/esm/models/OutboundCall.d.ts +68 -0
  28. package/dist/esm/models/OutboundCall.js +53 -0
  29. package/dist/esm/models/OutboundCallRequest.d.ts +44 -0
  30. package/dist/esm/models/OutboundCallRequest.js +47 -0
  31. package/dist/esm/models/PhoneNumber.d.ts +18 -0
  32. package/dist/esm/models/PhoneNumber.js +6 -0
  33. package/dist/esm/models/PhoneNumberCreate.d.ts +24 -0
  34. package/dist/esm/models/PhoneNumberCreate.js +8 -0
  35. package/dist/esm/models/PhoneNumberOrder.d.ts +101 -0
  36. package/dist/esm/models/PhoneNumberOrder.js +69 -0
  37. package/dist/esm/models/PhoneNumberOrderDetail.d.ts +119 -0
  38. package/dist/esm/models/PhoneNumberOrderDetail.js +75 -0
  39. package/dist/esm/models/PhoneNumberOrdersListResponse.d.ts +39 -0
  40. package/dist/esm/models/PhoneNumberOrdersListResponse.js +44 -0
  41. package/dist/esm/models/ProcessOrdersResult.d.ts +38 -0
  42. package/dist/esm/models/ProcessOrdersResult.js +43 -0
  43. package/dist/esm/models/index.d.ts +7 -0
  44. package/dist/esm/models/index.js +7 -0
  45. package/dist/models/AdminPhoneNumberAssignOutbound.d.ts +32 -0
  46. package/dist/models/AdminPhoneNumberAssignOutbound.js +50 -0
  47. package/dist/models/AdminPhoneNumberDetail.d.ts +30 -0
  48. package/dist/models/AdminPhoneNumberDetail.js +10 -0
  49. package/dist/models/AdminPhoneNumberUpdate.d.ts +18 -0
  50. package/dist/models/AdminPhoneNumberUpdate.js +6 -0
  51. package/dist/models/OutboundCall.d.ts +68 -0
  52. package/dist/models/OutboundCall.js +60 -0
  53. package/dist/models/OutboundCallRequest.d.ts +44 -0
  54. package/dist/models/OutboundCallRequest.js +54 -0
  55. package/dist/models/PhoneNumber.d.ts +18 -0
  56. package/dist/models/PhoneNumber.js +6 -0
  57. package/dist/models/PhoneNumberCreate.d.ts +24 -0
  58. package/dist/models/PhoneNumberCreate.js +8 -0
  59. package/dist/models/PhoneNumberOrder.d.ts +101 -0
  60. package/dist/models/PhoneNumberOrder.js +77 -0
  61. package/dist/models/PhoneNumberOrderDetail.d.ts +119 -0
  62. package/dist/models/PhoneNumberOrderDetail.js +83 -0
  63. package/dist/models/PhoneNumberOrdersListResponse.d.ts +39 -0
  64. package/dist/models/PhoneNumberOrdersListResponse.js +51 -0
  65. package/dist/models/ProcessOrdersResult.d.ts +38 -0
  66. package/dist/models/ProcessOrdersResult.js +50 -0
  67. package/dist/models/index.d.ts +7 -0
  68. package/dist/models/index.js +7 -0
  69. package/package.json +1 -1
  70. package/src/api-client.ts +28 -0
  71. package/src/apis/AdminPhoneNumbersApi.ts +332 -0
  72. package/src/apis/OutboundCallsApi.ts +95 -0
  73. package/src/apis/SIPApi.ts +124 -0
  74. package/src/apis/index.ts +1 -0
  75. package/src/models/AdminPhoneNumberAssignOutbound.ts +66 -0
  76. package/src/models/AdminPhoneNumberDetail.ts +40 -0
  77. package/src/models/AdminPhoneNumberUpdate.ts +24 -0
  78. package/src/models/OutboundCall.ts +113 -0
  79. package/src/models/OutboundCallRequest.ts +82 -0
  80. package/src/models/PhoneNumber.ts +24 -0
  81. package/src/models/PhoneNumberCreate.ts +32 -0
  82. package/src/models/PhoneNumberOrder.ts +157 -0
  83. package/src/models/PhoneNumberOrderDetail.ts +181 -0
  84. package/src/models/PhoneNumberOrdersListResponse.ts +81 -0
  85. package/src/models/ProcessOrdersResult.ts +73 -0
  86. package/src/models/index.ts +7 -0
@@ -33,6 +33,36 @@ export interface AdminPhoneNumberDetail {
33
33
  * @memberof AdminPhoneNumberDetail
34
34
  */
35
35
  supports_call_redirect?: boolean;
36
+ /**
37
+ *
38
+ * @type {boolean}
39
+ * @memberof AdminPhoneNumberDetail
40
+ */
41
+ supports_outbound?: boolean;
42
+ /**
43
+ *
44
+ * @type {string}
45
+ * @memberof AdminPhoneNumberDetail
46
+ */
47
+ sip_address?: string | null;
48
+ /**
49
+ *
50
+ * @type {boolean}
51
+ * @memberof AdminPhoneNumberDetail
52
+ */
53
+ outbound_configured?: boolean;
54
+ /**
55
+ *
56
+ * @type {string}
57
+ * @memberof AdminPhoneNumberDetail
58
+ */
59
+ outbound_organization_id?: string | null;
60
+ /**
61
+ *
62
+ * @type {string}
63
+ * @memberof AdminPhoneNumberDetail
64
+ */
65
+ outbound_organization_name?: string | null;
36
66
  /**
37
67
  *
38
68
  * @type {string}
@@ -35,6 +35,11 @@ export function AdminPhoneNumberDetailFromJSONTyped(json, ignoreDiscriminator) {
35
35
  'id': json['id'] == null ? undefined : json['id'],
36
36
  'number': json['number'] == null ? undefined : json['number'],
37
37
  'supports_call_redirect': json['supports_call_redirect'] == null ? undefined : json['supports_call_redirect'],
38
+ 'supports_outbound': json['supports_outbound'] == null ? undefined : json['supports_outbound'],
39
+ 'sip_address': json['sip_address'] == null ? undefined : json['sip_address'],
40
+ 'outbound_configured': json['outbound_configured'] == null ? undefined : json['outbound_configured'],
41
+ 'outbound_organization_id': json['outbound_organization_id'] == null ? undefined : json['outbound_organization_id'],
42
+ 'outbound_organization_name': json['outbound_organization_name'] == null ? undefined : json['outbound_organization_name'],
38
43
  'status': json['status'] == null ? undefined : json['status'],
39
44
  'created_at': json['created_at'] == null ? undefined : (new Date(json['created_at'])),
40
45
  'sip_trunk_id': json['sip_trunk_id'] == null ? undefined : json['sip_trunk_id'],
@@ -56,6 +61,11 @@ export function AdminPhoneNumberDetailToJSONTyped(value, ignoreDiscriminator = f
56
61
  'id': value['id'],
57
62
  'number': value['number'],
58
63
  'supports_call_redirect': value['supports_call_redirect'],
64
+ 'supports_outbound': value['supports_outbound'],
65
+ 'sip_address': value['sip_address'],
66
+ 'outbound_configured': value['outbound_configured'],
67
+ 'outbound_organization_id': value['outbound_organization_id'],
68
+ 'outbound_organization_name': value['outbound_organization_name'],
59
69
  'status': value['status'],
60
70
  'created_at': value['created_at'] == null ? value['created_at'] : value['created_at'].toISOString(),
61
71
  'sip_trunk_id': value['sip_trunk_id'],
@@ -27,6 +27,24 @@ export interface AdminPhoneNumberUpdate {
27
27
  * @memberof AdminPhoneNumberUpdate
28
28
  */
29
29
  supports_call_redirect?: boolean;
30
+ /**
31
+ * Update the outbound SIP address (outbound numbers only).
32
+ * @type {string}
33
+ * @memberof AdminPhoneNumberUpdate
34
+ */
35
+ sip_address?: string;
36
+ /**
37
+ * Update the outbound SIP auth username (re-encrypted).
38
+ * @type {string}
39
+ * @memberof AdminPhoneNumberUpdate
40
+ */
41
+ auth_username?: string;
42
+ /**
43
+ * Update the outbound SIP auth password (re-encrypted).
44
+ * @type {string}
45
+ * @memberof AdminPhoneNumberUpdate
46
+ */
47
+ auth_password?: string;
30
48
  }
31
49
  /**
32
50
  * Check if a given object implements the AdminPhoneNumberUpdate interface.
@@ -27,6 +27,9 @@ export function AdminPhoneNumberUpdateFromJSONTyped(json, ignoreDiscriminator) {
27
27
  return {
28
28
  'number': json['number'] == null ? undefined : json['number'],
29
29
  'supports_call_redirect': json['supports_call_redirect'] == null ? undefined : json['supports_call_redirect'],
30
+ 'sip_address': json['sip_address'] == null ? undefined : json['sip_address'],
31
+ 'auth_username': json['auth_username'] == null ? undefined : json['auth_username'],
32
+ 'auth_password': json['auth_password'] == null ? undefined : json['auth_password'],
30
33
  };
31
34
  }
32
35
  export function AdminPhoneNumberUpdateToJSON(json) {
@@ -39,5 +42,8 @@ export function AdminPhoneNumberUpdateToJSONTyped(value, ignoreDiscriminator = f
39
42
  return {
40
43
  'number': value['number'],
41
44
  'supports_call_redirect': value['supports_call_redirect'],
45
+ 'sip_address': value['sip_address'],
46
+ 'auth_username': value['auth_username'],
47
+ 'auth_password': value['auth_password'],
42
48
  };
43
49
  }
@@ -0,0 +1,68 @@
1
+ /**
2
+ * Tivadar AI Backend API
3
+ * Unified REST API for Tivadar AI Voice Agents platform
4
+ *
5
+ * The version of the OpenAPI document: 1.0.0
6
+ *
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ /**
13
+ *
14
+ * @export
15
+ * @interface OutboundCall
16
+ */
17
+ export interface OutboundCall {
18
+ /**
19
+ *
20
+ * @type {string}
21
+ * @memberof OutboundCall
22
+ */
23
+ call_id?: string | null;
24
+ /**
25
+ *
26
+ * @type {string}
27
+ * @memberof OutboundCall
28
+ */
29
+ room_name?: string;
30
+ /**
31
+ *
32
+ * @type {string}
33
+ * @memberof OutboundCall
34
+ */
35
+ destination?: string;
36
+ /**
37
+ *
38
+ * @type {string}
39
+ * @memberof OutboundCall
40
+ */
41
+ from_number?: string;
42
+ /**
43
+ *
44
+ * @type {string}
45
+ * @memberof OutboundCall
46
+ */
47
+ participant_identity?: string;
48
+ /**
49
+ *
50
+ * @type {string}
51
+ * @memberof OutboundCall
52
+ */
53
+ sip_participant_id?: string | null;
54
+ /**
55
+ *
56
+ * @type {boolean}
57
+ * @memberof OutboundCall
58
+ */
59
+ dispatched?: boolean;
60
+ }
61
+ /**
62
+ * Check if a given object implements the OutboundCall interface.
63
+ */
64
+ export declare function instanceOfOutboundCall(value: object): value is OutboundCall;
65
+ export declare function OutboundCallFromJSON(json: any): OutboundCall;
66
+ export declare function OutboundCallFromJSONTyped(json: any, ignoreDiscriminator: boolean): OutboundCall;
67
+ export declare function OutboundCallToJSON(json: any): OutboundCall;
68
+ export declare function OutboundCallToJSONTyped(value?: OutboundCall | null, ignoreDiscriminator?: boolean): any;
@@ -0,0 +1,53 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * Tivadar AI Backend API
5
+ * Unified REST API for Tivadar AI Voice Agents platform
6
+ *
7
+ * The version of the OpenAPI document: 1.0.0
8
+ *
9
+ *
10
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
+ * https://openapi-generator.tech
12
+ * Do not edit the class manually.
13
+ */
14
+ /**
15
+ * Check if a given object implements the OutboundCall interface.
16
+ */
17
+ export function instanceOfOutboundCall(value) {
18
+ return true;
19
+ }
20
+ export function OutboundCallFromJSON(json) {
21
+ return OutboundCallFromJSONTyped(json, false);
22
+ }
23
+ export function OutboundCallFromJSONTyped(json, ignoreDiscriminator) {
24
+ if (json == null) {
25
+ return json;
26
+ }
27
+ return {
28
+ 'call_id': json['call_id'] == null ? undefined : json['call_id'],
29
+ 'room_name': json['room_name'] == null ? undefined : json['room_name'],
30
+ 'destination': json['destination'] == null ? undefined : json['destination'],
31
+ 'from_number': json['from_number'] == null ? undefined : json['from_number'],
32
+ 'participant_identity': json['participant_identity'] == null ? undefined : json['participant_identity'],
33
+ 'sip_participant_id': json['sip_participant_id'] == null ? undefined : json['sip_participant_id'],
34
+ 'dispatched': json['dispatched'] == null ? undefined : json['dispatched'],
35
+ };
36
+ }
37
+ export function OutboundCallToJSON(json) {
38
+ return OutboundCallToJSONTyped(json, false);
39
+ }
40
+ export function OutboundCallToJSONTyped(value, ignoreDiscriminator = false) {
41
+ if (value == null) {
42
+ return value;
43
+ }
44
+ return {
45
+ 'call_id': value['call_id'],
46
+ 'room_name': value['room_name'],
47
+ 'destination': value['destination'],
48
+ 'from_number': value['from_number'],
49
+ 'participant_identity': value['participant_identity'],
50
+ 'sip_participant_id': value['sip_participant_id'],
51
+ 'dispatched': value['dispatched'],
52
+ };
53
+ }
@@ -0,0 +1,44 @@
1
+ /**
2
+ * Tivadar AI Backend API
3
+ * Unified REST API for Tivadar AI Voice Agents platform
4
+ *
5
+ * The version of the OpenAPI document: 1.0.0
6
+ *
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ /**
13
+ *
14
+ * @export
15
+ * @interface OutboundCallRequest
16
+ */
17
+ export interface OutboundCallRequest {
18
+ /**
19
+ *
20
+ * @type {string}
21
+ * @memberof OutboundCallRequest
22
+ */
23
+ voice_agent_id: string;
24
+ /**
25
+ * Destination from a phonebook entry. Provide this OR destination_number.
26
+ * @type {string}
27
+ * @memberof OutboundCallRequest
28
+ */
29
+ phonebook_entry_id?: string;
30
+ /**
31
+ * Custom destination phone number. Provide this OR phonebook_entry_id.
32
+ * @type {string}
33
+ * @memberof OutboundCallRequest
34
+ */
35
+ destination_number?: string;
36
+ }
37
+ /**
38
+ * Check if a given object implements the OutboundCallRequest interface.
39
+ */
40
+ export declare function instanceOfOutboundCallRequest(value: object): value is OutboundCallRequest;
41
+ export declare function OutboundCallRequestFromJSON(json: any): OutboundCallRequest;
42
+ export declare function OutboundCallRequestFromJSONTyped(json: any, ignoreDiscriminator: boolean): OutboundCallRequest;
43
+ export declare function OutboundCallRequestToJSON(json: any): OutboundCallRequest;
44
+ export declare function OutboundCallRequestToJSONTyped(value?: OutboundCallRequest | null, ignoreDiscriminator?: boolean): any;
@@ -0,0 +1,47 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * Tivadar AI Backend API
5
+ * Unified REST API for Tivadar AI Voice Agents platform
6
+ *
7
+ * The version of the OpenAPI document: 1.0.0
8
+ *
9
+ *
10
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
+ * https://openapi-generator.tech
12
+ * Do not edit the class manually.
13
+ */
14
+ /**
15
+ * Check if a given object implements the OutboundCallRequest interface.
16
+ */
17
+ export function instanceOfOutboundCallRequest(value) {
18
+ if (!('voice_agent_id' in value) || value['voice_agent_id'] === undefined)
19
+ return false;
20
+ return true;
21
+ }
22
+ export function OutboundCallRequestFromJSON(json) {
23
+ return OutboundCallRequestFromJSONTyped(json, false);
24
+ }
25
+ export function OutboundCallRequestFromJSONTyped(json, ignoreDiscriminator) {
26
+ if (json == null) {
27
+ return json;
28
+ }
29
+ return {
30
+ 'voice_agent_id': json['voice_agent_id'],
31
+ 'phonebook_entry_id': json['phonebook_entry_id'] == null ? undefined : json['phonebook_entry_id'],
32
+ 'destination_number': json['destination_number'] == null ? undefined : json['destination_number'],
33
+ };
34
+ }
35
+ export function OutboundCallRequestToJSON(json) {
36
+ return OutboundCallRequestToJSONTyped(json, false);
37
+ }
38
+ export function OutboundCallRequestToJSONTyped(value, ignoreDiscriminator = false) {
39
+ if (value == null) {
40
+ return value;
41
+ }
42
+ return {
43
+ 'voice_agent_id': value['voice_agent_id'],
44
+ 'phonebook_entry_id': value['phonebook_entry_id'],
45
+ 'destination_number': value['destination_number'],
46
+ };
47
+ }
@@ -39,6 +39,24 @@ export interface PhoneNumber {
39
39
  * @memberof PhoneNumber
40
40
  */
41
41
  supports_call_redirect?: boolean;
42
+ /**
43
+ * Whether this number can place outbound calls (has an outbound trunk).
44
+ * @type {boolean}
45
+ * @memberof PhoneNumber
46
+ */
47
+ supports_outbound?: boolean;
48
+ /**
49
+ * Outbound SIP provider host/address (outbound numbers only).
50
+ * @type {string}
51
+ * @memberof PhoneNumber
52
+ */
53
+ sip_address?: string | null;
54
+ /**
55
+ * Whether the outbound trunk + credentials are configured. Secrets are never returned.
56
+ * @type {boolean}
57
+ * @memberof PhoneNumber
58
+ */
59
+ outbound_configured?: boolean;
42
60
  /**
43
61
  *
44
62
  * @type {Date}
@@ -29,6 +29,9 @@ export function PhoneNumberFromJSONTyped(json, ignoreDiscriminator) {
29
29
  'number': json['number'] == null ? undefined : json['number'],
30
30
  'sip_trunk_id': json['sip_trunk_id'] == null ? undefined : json['sip_trunk_id'],
31
31
  'supports_call_redirect': json['supports_call_redirect'] == null ? undefined : json['supports_call_redirect'],
32
+ 'supports_outbound': json['supports_outbound'] == null ? undefined : json['supports_outbound'],
33
+ 'sip_address': json['sip_address'] == null ? undefined : json['sip_address'],
34
+ 'outbound_configured': json['outbound_configured'] == null ? undefined : json['outbound_configured'],
32
35
  'created_at': json['created_at'] == null ? undefined : (new Date(json['created_at'])),
33
36
  };
34
37
  }
@@ -44,6 +47,9 @@ export function PhoneNumberToJSONTyped(value, ignoreDiscriminator = false) {
44
47
  'number': value['number'],
45
48
  'sip_trunk_id': value['sip_trunk_id'],
46
49
  'supports_call_redirect': value['supports_call_redirect'],
50
+ 'supports_outbound': value['supports_outbound'],
51
+ 'sip_address': value['sip_address'],
52
+ 'outbound_configured': value['outbound_configured'],
47
53
  'created_at': value['created_at'] == null ? value['created_at'] : value['created_at'].toISOString(),
48
54
  };
49
55
  }
@@ -27,6 +27,30 @@ export interface PhoneNumberCreate {
27
27
  * @memberof PhoneNumberCreate
28
28
  */
29
29
  supports_call_redirect?: boolean;
30
+ /**
31
+ * Whether this number can place outbound calls. When true, sip_address, auth_username and auth_password are required.
32
+ * @type {boolean}
33
+ * @memberof PhoneNumberCreate
34
+ */
35
+ supports_outbound?: boolean;
36
+ /**
37
+ * Outbound SIP provider host/address (required when supports_outbound is true).
38
+ * @type {string}
39
+ * @memberof PhoneNumberCreate
40
+ */
41
+ sip_address?: string;
42
+ /**
43
+ * Outbound SIP auth username (required when supports_outbound is true). Stored encrypted.
44
+ * @type {string}
45
+ * @memberof PhoneNumberCreate
46
+ */
47
+ auth_username?: string;
48
+ /**
49
+ * Outbound SIP auth password (required when supports_outbound is true). Stored encrypted, never returned.
50
+ * @type {string}
51
+ * @memberof PhoneNumberCreate
52
+ */
53
+ auth_password?: string;
30
54
  }
31
55
  /**
32
56
  * Check if a given object implements the PhoneNumberCreate interface.
@@ -29,6 +29,10 @@ export function PhoneNumberCreateFromJSONTyped(json, ignoreDiscriminator) {
29
29
  return {
30
30
  'number': json['number'],
31
31
  'supports_call_redirect': json['supports_call_redirect'] == null ? undefined : json['supports_call_redirect'],
32
+ 'supports_outbound': json['supports_outbound'] == null ? undefined : json['supports_outbound'],
33
+ 'sip_address': json['sip_address'] == null ? undefined : json['sip_address'],
34
+ 'auth_username': json['auth_username'] == null ? undefined : json['auth_username'],
35
+ 'auth_password': json['auth_password'] == null ? undefined : json['auth_password'],
32
36
  };
33
37
  }
34
38
  export function PhoneNumberCreateToJSON(json) {
@@ -41,5 +45,9 @@ export function PhoneNumberCreateToJSONTyped(value, ignoreDiscriminator = false)
41
45
  return {
42
46
  'number': value['number'],
43
47
  'supports_call_redirect': value['supports_call_redirect'],
48
+ 'supports_outbound': value['supports_outbound'],
49
+ 'sip_address': value['sip_address'],
50
+ 'auth_username': value['auth_username'],
51
+ 'auth_password': value['auth_password'],
44
52
  };
45
53
  }
@@ -0,0 +1,101 @@
1
+ /**
2
+ * Tivadar AI Backend API
3
+ * Unified REST API for Tivadar AI Voice Agents platform
4
+ *
5
+ * The version of the OpenAPI document: 1.0.0
6
+ *
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ /**
13
+ * A backorder for a phone number, fulfilled automatically when the pool expands.
14
+ * @export
15
+ * @interface PhoneNumberOrder
16
+ */
17
+ export interface PhoneNumberOrder {
18
+ /**
19
+ *
20
+ * @type {string}
21
+ * @memberof PhoneNumberOrder
22
+ */
23
+ id?: string;
24
+ /**
25
+ *
26
+ * @type {string}
27
+ * @memberof PhoneNumberOrder
28
+ */
29
+ organization_id?: string;
30
+ /**
31
+ *
32
+ * @type {string}
33
+ * @memberof PhoneNumberOrder
34
+ */
35
+ agent_id?: string | null;
36
+ /**
37
+ *
38
+ * @type {boolean}
39
+ * @memberof PhoneNumberOrder
40
+ */
41
+ requires_call_redirect?: boolean;
42
+ /**
43
+ *
44
+ * @type {string}
45
+ * @memberof PhoneNumberOrder
46
+ */
47
+ status?: PhoneNumberOrderStatusEnum;
48
+ /**
49
+ *
50
+ * @type {number}
51
+ * @memberof PhoneNumberOrder
52
+ */
53
+ phone_number_id?: number | null;
54
+ /**
55
+ *
56
+ * @type {string}
57
+ * @memberof PhoneNumberOrder
58
+ */
59
+ sip_trunk_id?: string | null;
60
+ /**
61
+ *
62
+ * @type {string}
63
+ * @memberof PhoneNumberOrder
64
+ */
65
+ note?: string | null;
66
+ /**
67
+ *
68
+ * @type {Date}
69
+ * @memberof PhoneNumberOrder
70
+ */
71
+ created_at?: Date;
72
+ /**
73
+ *
74
+ * @type {Date}
75
+ * @memberof PhoneNumberOrder
76
+ */
77
+ fulfilled_at?: Date | null;
78
+ /**
79
+ *
80
+ * @type {Date}
81
+ * @memberof PhoneNumberOrder
82
+ */
83
+ canceled_at?: Date | null;
84
+ }
85
+ /**
86
+ * @export
87
+ */
88
+ export declare const PhoneNumberOrderStatusEnum: {
89
+ readonly Pending: "pending";
90
+ readonly Active: "active";
91
+ readonly Canceled: "canceled";
92
+ };
93
+ export type PhoneNumberOrderStatusEnum = typeof PhoneNumberOrderStatusEnum[keyof typeof PhoneNumberOrderStatusEnum];
94
+ /**
95
+ * Check if a given object implements the PhoneNumberOrder interface.
96
+ */
97
+ export declare function instanceOfPhoneNumberOrder(value: object): value is PhoneNumberOrder;
98
+ export declare function PhoneNumberOrderFromJSON(json: any): PhoneNumberOrder;
99
+ export declare function PhoneNumberOrderFromJSONTyped(json: any, ignoreDiscriminator: boolean): PhoneNumberOrder;
100
+ export declare function PhoneNumberOrderToJSON(json: any): PhoneNumberOrder;
101
+ export declare function PhoneNumberOrderToJSONTyped(value?: PhoneNumberOrder | null, ignoreDiscriminator?: boolean): any;
@@ -0,0 +1,69 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * Tivadar AI Backend API
5
+ * Unified REST API for Tivadar AI Voice Agents platform
6
+ *
7
+ * The version of the OpenAPI document: 1.0.0
8
+ *
9
+ *
10
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
+ * https://openapi-generator.tech
12
+ * Do not edit the class manually.
13
+ */
14
+ /**
15
+ * @export
16
+ */
17
+ export const PhoneNumberOrderStatusEnum = {
18
+ Pending: 'pending',
19
+ Active: 'active',
20
+ Canceled: 'canceled'
21
+ };
22
+ /**
23
+ * Check if a given object implements the PhoneNumberOrder interface.
24
+ */
25
+ export function instanceOfPhoneNumberOrder(value) {
26
+ return true;
27
+ }
28
+ export function PhoneNumberOrderFromJSON(json) {
29
+ return PhoneNumberOrderFromJSONTyped(json, false);
30
+ }
31
+ export function PhoneNumberOrderFromJSONTyped(json, ignoreDiscriminator) {
32
+ if (json == null) {
33
+ return json;
34
+ }
35
+ return {
36
+ 'id': json['id'] == null ? undefined : json['id'],
37
+ 'organization_id': json['organization_id'] == null ? undefined : json['organization_id'],
38
+ 'agent_id': json['agent_id'] == null ? undefined : json['agent_id'],
39
+ 'requires_call_redirect': json['requires_call_redirect'] == null ? undefined : json['requires_call_redirect'],
40
+ 'status': json['status'] == null ? undefined : json['status'],
41
+ 'phone_number_id': json['phone_number_id'] == null ? undefined : json['phone_number_id'],
42
+ 'sip_trunk_id': json['sip_trunk_id'] == null ? undefined : json['sip_trunk_id'],
43
+ 'note': json['note'] == null ? undefined : json['note'],
44
+ 'created_at': json['created_at'] == null ? undefined : (new Date(json['created_at'])),
45
+ 'fulfilled_at': json['fulfilled_at'] == null ? undefined : (new Date(json['fulfilled_at'])),
46
+ 'canceled_at': json['canceled_at'] == null ? undefined : (new Date(json['canceled_at'])),
47
+ };
48
+ }
49
+ export function PhoneNumberOrderToJSON(json) {
50
+ return PhoneNumberOrderToJSONTyped(json, false);
51
+ }
52
+ export function PhoneNumberOrderToJSONTyped(value, ignoreDiscriminator = false) {
53
+ if (value == null) {
54
+ return value;
55
+ }
56
+ return {
57
+ 'id': value['id'],
58
+ 'organization_id': value['organization_id'],
59
+ 'agent_id': value['agent_id'],
60
+ 'requires_call_redirect': value['requires_call_redirect'],
61
+ 'status': value['status'],
62
+ 'phone_number_id': value['phone_number_id'],
63
+ 'sip_trunk_id': value['sip_trunk_id'],
64
+ 'note': value['note'],
65
+ 'created_at': value['created_at'] == null ? value['created_at'] : value['created_at'].toISOString(),
66
+ 'fulfilled_at': value['fulfilled_at'] == null ? value['fulfilled_at'] : value['fulfilled_at'].toISOString(),
67
+ 'canceled_at': value['canceled_at'] == null ? value['canceled_at'] : value['canceled_at'].toISOString(),
68
+ };
69
+ }