@linqapp/sdk 0.79.0 → 0.81.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/CHANGELOG.md +14 -0
- package/client.d.mts +77 -2
- package/client.d.mts.map +1 -1
- package/client.d.ts +77 -2
- package/client.d.ts.map +1 -1
- package/client.js +75 -0
- package/client.js.map +1 -1
- package/client.mjs +75 -0
- package/client.mjs.map +1 -1
- package/package.json +1 -1
- package/resources/available-number.d.mts +13 -0
- package/resources/available-number.d.mts.map +1 -1
- package/resources/available-number.d.ts +13 -0
- package/resources/available-number.d.ts.map +1 -1
- package/resources/available-number.js +13 -0
- package/resources/available-number.js.map +1 -1
- package/resources/available-number.mjs +13 -0
- package/resources/available-number.mjs.map +1 -1
- package/resources/call-voice.d.mts +82 -0
- package/resources/call-voice.d.mts.map +1 -0
- package/resources/call-voice.d.ts +82 -0
- package/resources/call-voice.d.ts.map +1 -0
- package/resources/call-voice.js +35 -0
- package/resources/call-voice.js.map +1 -0
- package/resources/call-voice.mjs +31 -0
- package/resources/call-voice.mjs.map +1 -0
- package/resources/chats/chats.d.mts +16 -3
- package/resources/chats/chats.d.mts.map +1 -1
- package/resources/chats/chats.d.ts +16 -3
- package/resources/chats/chats.d.ts.map +1 -1
- package/resources/chats/chats.js.map +1 -1
- package/resources/chats/chats.mjs.map +1 -1
- package/resources/chats/messages.d.mts +10 -3
- package/resources/chats/messages.d.mts.map +1 -1
- package/resources/chats/messages.d.ts +10 -3
- package/resources/chats/messages.d.ts.map +1 -1
- package/resources/chats/polls.d.mts +1 -1
- package/resources/chats/polls.d.ts +1 -1
- package/resources/contact-card.d.mts +8 -0
- package/resources/contact-card.d.mts.map +1 -1
- package/resources/contact-card.d.ts +8 -0
- package/resources/contact-card.d.ts.map +1 -1
- package/resources/contact-card.js +8 -0
- package/resources/contact-card.js.map +1 -1
- package/resources/contact-card.mjs +8 -0
- package/resources/contact-card.mjs.map +1 -1
- package/resources/index.d.mts +3 -1
- package/resources/index.d.mts.map +1 -1
- package/resources/index.d.ts +3 -1
- package/resources/index.d.ts.map +1 -1
- package/resources/index.js +5 -1
- package/resources/index.js.map +1 -1
- package/resources/index.mjs +2 -0
- package/resources/index.mjs.map +1 -1
- package/resources/messages/messages.d.mts +16 -7
- package/resources/messages/messages.d.mts.map +1 -1
- package/resources/messages/messages.d.ts +16 -7
- package/resources/messages/messages.d.ts.map +1 -1
- package/resources/messages/messages.js +6 -4
- package/resources/messages/messages.js.map +1 -1
- package/resources/messages/messages.mjs +6 -4
- package/resources/messages/messages.mjs.map +1 -1
- package/resources/phone-numbers.d.mts +20 -0
- package/resources/phone-numbers.d.mts.map +1 -1
- package/resources/phone-numbers.d.ts +20 -0
- package/resources/phone-numbers.d.ts.map +1 -1
- package/resources/phone-numbers.js +13 -0
- package/resources/phone-numbers.js.map +1 -1
- package/resources/phone-numbers.mjs +13 -0
- package/resources/phone-numbers.mjs.map +1 -1
- package/resources/phonenumbers.d.mts +13 -0
- package/resources/phonenumbers.d.mts.map +1 -1
- package/resources/phonenumbers.d.ts +13 -0
- package/resources/phonenumbers.d.ts.map +1 -1
- package/resources/phonenumbers.js +13 -0
- package/resources/phonenumbers.js.map +1 -1
- package/resources/phonenumbers.mjs +13 -0
- package/resources/phonenumbers.mjs.map +1 -1
- package/resources/shared.d.mts +4 -2
- package/resources/shared.d.mts.map +1 -1
- package/resources/shared.d.ts +4 -2
- package/resources/shared.d.ts.map +1 -1
- package/resources/sip-profiles.d.mts +224 -0
- package/resources/sip-profiles.d.mts.map +1 -0
- package/resources/sip-profiles.d.ts +224 -0
- package/resources/sip-profiles.d.ts.map +1 -0
- package/resources/sip-profiles.js +168 -0
- package/resources/sip-profiles.js.map +1 -0
- package/resources/sip-profiles.mjs +164 -0
- package/resources/sip-profiles.mjs.map +1 -0
- package/resources/webhook-events.d.mts +1 -1
- package/resources/webhook-events.d.mts.map +1 -1
- package/resources/webhook-events.d.ts +1 -1
- package/resources/webhook-events.d.ts.map +1 -1
- package/resources/webhooks.d.mts +524 -44
- package/resources/webhooks.d.mts.map +1 -1
- package/resources/webhooks.d.ts +524 -44
- package/resources/webhooks.d.ts.map +1 -1
- package/src/client.ts +121 -0
- package/src/resources/available-number.ts +13 -0
- package/src/resources/call-voice.ts +110 -0
- package/src/resources/chats/chats.ts +18 -3
- package/src/resources/chats/messages.ts +11 -3
- package/src/resources/chats/polls.ts +1 -1
- package/src/resources/contact-card.ts +8 -0
- package/src/resources/index.ts +23 -0
- package/src/resources/messages/messages.ts +17 -7
- package/src/resources/phone-numbers.ts +21 -0
- package/src/resources/phonenumbers.ts +13 -0
- package/src/resources/shared.ts +4 -2
- package/src/resources/sip-profiles.ts +282 -0
- package/src/resources/webhook-events.ts +1 -7
- package/src/resources/webhooks.ts +1263 -277
- package/src/version.ts +1 -1
- package/version.d.mts +1 -1
- package/version.d.ts +1 -1
- package/version.js +1 -1
- package/version.mjs +1 -1
|
@@ -0,0 +1,224 @@
|
|
|
1
|
+
import { APIResource } from "../core/resource.js";
|
|
2
|
+
import { APIPromise } from "../core/api-promise.js";
|
|
3
|
+
import { RequestOptions } from "../internal/request-options.js";
|
|
4
|
+
/**
|
|
5
|
+
* ## SIP configuration
|
|
6
|
+
*
|
|
7
|
+
* Add these IP ranges to your SIP endpoint's allowlist:
|
|
8
|
+
*
|
|
9
|
+
* ```
|
|
10
|
+
* 54.172.60.0/30
|
|
11
|
+
* 54.244.51.0/30
|
|
12
|
+
* 168.86.128.0/18
|
|
13
|
+
* ```
|
|
14
|
+
*
|
|
15
|
+
* Set `primary_uri` to your endpoint as scheme + host — `sips:` for TLS or
|
|
16
|
+
* `sip:` for UDP, with no user part (we add it). Each call arrives at your
|
|
17
|
+
* endpoint as:
|
|
18
|
+
*
|
|
19
|
+
* ```
|
|
20
|
+
* sip:<called-number>@<your-host>
|
|
21
|
+
* ```
|
|
22
|
+
*
|
|
23
|
+
* so you can route on the dialed number. The caller's number is in the
|
|
24
|
+
* `From` header in E.164. Media (RTP) uses UDP ports 10000–60000.
|
|
25
|
+
*/
|
|
26
|
+
export declare class SipProfiles extends APIResource {
|
|
27
|
+
/**
|
|
28
|
+
* ## SIP configuration
|
|
29
|
+
*
|
|
30
|
+
* Add these IP ranges to your SIP endpoint's allowlist:
|
|
31
|
+
*
|
|
32
|
+
* ```
|
|
33
|
+
* 54.172.60.0/30
|
|
34
|
+
* 54.244.51.0/30
|
|
35
|
+
* 168.86.128.0/18
|
|
36
|
+
* ```
|
|
37
|
+
*
|
|
38
|
+
* Set `primary_uri` to your endpoint as scheme + host — `sips:` for TLS or `sip:`
|
|
39
|
+
* for UDP, with no user part (we add it). Each call arrives at your endpoint as:
|
|
40
|
+
*
|
|
41
|
+
* ```
|
|
42
|
+
* sip:<called-number>@<your-host>
|
|
43
|
+
* ```
|
|
44
|
+
*
|
|
45
|
+
* so you can route on the dialed number. The caller's number is in the `From`
|
|
46
|
+
* header in E.164. Media (RTP) uses UDP ports 10000–60000.
|
|
47
|
+
*
|
|
48
|
+
* ---
|
|
49
|
+
*
|
|
50
|
+
* Create a SIP routing profile for your inbound calls, then assign it to a phone
|
|
51
|
+
* number to start routing calls to its SIP URI.
|
|
52
|
+
*
|
|
53
|
+
* @example
|
|
54
|
+
* ```ts
|
|
55
|
+
* const sipProfile = await client.sipProfiles.create({
|
|
56
|
+
* name: 'byoc-primary',
|
|
57
|
+
* primary_uri: 'sips:sip.partner.example',
|
|
58
|
+
* });
|
|
59
|
+
* ```
|
|
60
|
+
*/
|
|
61
|
+
create(body: SipProfileCreateParams, options?: RequestOptions): APIPromise<SipProfile>;
|
|
62
|
+
/**
|
|
63
|
+
* Retrieve details for a specific SIP profile.
|
|
64
|
+
*
|
|
65
|
+
* @example
|
|
66
|
+
* ```ts
|
|
67
|
+
* const sipProfile = await client.sipProfiles.retrieve(
|
|
68
|
+
* 'sip_8a3f9c2b1d4e4f5a9b8c7d6e5f4a3b2c',
|
|
69
|
+
* );
|
|
70
|
+
* ```
|
|
71
|
+
*/
|
|
72
|
+
retrieve(sipProfileID: string, options?: RequestOptions): APIPromise<SipProfile>;
|
|
73
|
+
/**
|
|
74
|
+
* Update a SIP profile. Only the fields you send are changed; omitted fields keep
|
|
75
|
+
* their current value. Set `backup_uri` to an empty string to clear it.
|
|
76
|
+
*
|
|
77
|
+
* @example
|
|
78
|
+
* ```ts
|
|
79
|
+
* const sipProfile = await client.sipProfiles.update(
|
|
80
|
+
* 'sip_8a3f9c2b1d4e4f5a9b8c7d6e5f4a3b2c',
|
|
81
|
+
* { name: 'byoc-east' },
|
|
82
|
+
* );
|
|
83
|
+
* ```
|
|
84
|
+
*/
|
|
85
|
+
update(sipProfileID: string, body: SipProfileUpdateParams, options?: RequestOptions): APIPromise<SipProfile>;
|
|
86
|
+
/**
|
|
87
|
+
* Retrieve all SIP profiles for the authenticated partner.
|
|
88
|
+
*
|
|
89
|
+
* @example
|
|
90
|
+
* ```ts
|
|
91
|
+
* const sipProfiles = await client.sipProfiles.list();
|
|
92
|
+
* ```
|
|
93
|
+
*/
|
|
94
|
+
list(options?: RequestOptions): APIPromise<SipProfileListResponse>;
|
|
95
|
+
/**
|
|
96
|
+
* Delete a SIP profile. The profile must not be assigned to any phone number;
|
|
97
|
+
* unassign it first or the request is rejected.
|
|
98
|
+
*
|
|
99
|
+
* @example
|
|
100
|
+
* ```ts
|
|
101
|
+
* await client.sipProfiles.delete(
|
|
102
|
+
* 'sip_8a3f9c2b1d4e4f5a9b8c7d6e5f4a3b2c',
|
|
103
|
+
* );
|
|
104
|
+
* ```
|
|
105
|
+
*/
|
|
106
|
+
delete(sipProfileID: string, options?: RequestOptions): APIPromise<void>;
|
|
107
|
+
/**
|
|
108
|
+
* ## SIP configuration
|
|
109
|
+
*
|
|
110
|
+
* Add these IP ranges to your SIP endpoint's allowlist:
|
|
111
|
+
*
|
|
112
|
+
* ```
|
|
113
|
+
* 54.172.60.0/30
|
|
114
|
+
* 54.244.51.0/30
|
|
115
|
+
* 168.86.128.0/18
|
|
116
|
+
* ```
|
|
117
|
+
*
|
|
118
|
+
* Set `primary_uri` to your endpoint as scheme + host — `sips:` for TLS or `sip:`
|
|
119
|
+
* for UDP, with no user part (we add it). Each call arrives at your endpoint as:
|
|
120
|
+
*
|
|
121
|
+
* ```
|
|
122
|
+
* sip:<called-number>@<your-host>
|
|
123
|
+
* ```
|
|
124
|
+
*
|
|
125
|
+
* so you can route on the dialed number. The caller's number is in the `From`
|
|
126
|
+
* header in E.164. Media (RTP) uses UDP ports 10000–60000.
|
|
127
|
+
*
|
|
128
|
+
* ---
|
|
129
|
+
*
|
|
130
|
+
* Assign a SIP profile to route inbound calls to its SIP URI. This takes
|
|
131
|
+
* precedence over an existing `forwarding_number` without clearing it. Send
|
|
132
|
+
* `sip_profile_id: null` to remove the SIP assignment and resume existing
|
|
133
|
+
* forwarding, if configured. Allow about 5 minutes for routing changes to
|
|
134
|
+
* propagate. The phone number must belong to the authenticated partner.
|
|
135
|
+
*
|
|
136
|
+
* @example
|
|
137
|
+
* ```ts
|
|
138
|
+
* const response = await client.sipProfiles.assign(
|
|
139
|
+
* '+14254758217',
|
|
140
|
+
* {
|
|
141
|
+
* sip_profile_id: 'sip_8a3f9c2b1d4e4f5a9b8c7d6e5f4a3b2c',
|
|
142
|
+
* },
|
|
143
|
+
* );
|
|
144
|
+
* ```
|
|
145
|
+
*/
|
|
146
|
+
assign(phoneNumber: string, body: SipProfileAssignParams, options?: RequestOptions): APIPromise<SipProfileAssignResponse>;
|
|
147
|
+
}
|
|
148
|
+
export interface SipProfile {
|
|
149
|
+
/**
|
|
150
|
+
* Unique identifier for the SIP profile
|
|
151
|
+
*/
|
|
152
|
+
id: string;
|
|
153
|
+
/**
|
|
154
|
+
* How many phone numbers reference this profile
|
|
155
|
+
*/
|
|
156
|
+
assigned_number_count: number;
|
|
157
|
+
created_at: string;
|
|
158
|
+
/**
|
|
159
|
+
* Human-readable name
|
|
160
|
+
*/
|
|
161
|
+
name: string;
|
|
162
|
+
/**
|
|
163
|
+
* Your SIP endpoint as scheme + host (`sip:` UDP / `sips:` TLS); no user part — we
|
|
164
|
+
* set it to the called number on each call.
|
|
165
|
+
*/
|
|
166
|
+
primary_uri: string;
|
|
167
|
+
updated_at: string;
|
|
168
|
+
/**
|
|
169
|
+
* Monotonic version, incremented on each update
|
|
170
|
+
*/
|
|
171
|
+
version: number;
|
|
172
|
+
/**
|
|
173
|
+
* Optional failover SIP URI. Null when unset.
|
|
174
|
+
*/
|
|
175
|
+
backup_uri?: string | null;
|
|
176
|
+
}
|
|
177
|
+
export interface SipProfileListResponse {
|
|
178
|
+
/**
|
|
179
|
+
* The partner's SIP profiles
|
|
180
|
+
*/
|
|
181
|
+
sip_profiles: Array<SipProfile>;
|
|
182
|
+
}
|
|
183
|
+
export interface SipProfileAssignResponse {
|
|
184
|
+
/**
|
|
185
|
+
* The phone number whose assignment changed
|
|
186
|
+
*/
|
|
187
|
+
phone_number: string;
|
|
188
|
+
/**
|
|
189
|
+
* The assigned SIP profile id, or null when cleared
|
|
190
|
+
*/
|
|
191
|
+
sip_profile_id: string | null;
|
|
192
|
+
}
|
|
193
|
+
export interface SipProfileCreateParams {
|
|
194
|
+
name: string;
|
|
195
|
+
/**
|
|
196
|
+
* Your SIP endpoint as scheme + host, e.g. `sips:sip.partner.example`. Must start
|
|
197
|
+
* with `sip:` (UDP) or `sips:` (TLS) — the scheme sets the transport. Do not
|
|
198
|
+
* include a user part: we set it to the called number on each call
|
|
199
|
+
* (`sip:<called-number>@<your-host>`). A bare host with no scheme is rejected.
|
|
200
|
+
*/
|
|
201
|
+
primary_uri: string;
|
|
202
|
+
/**
|
|
203
|
+
* Optional failover SIP URI
|
|
204
|
+
*/
|
|
205
|
+
backup_uri?: string;
|
|
206
|
+
}
|
|
207
|
+
export interface SipProfileUpdateParams {
|
|
208
|
+
/**
|
|
209
|
+
* Set to "" to clear the backup URI.
|
|
210
|
+
*/
|
|
211
|
+
backup_uri?: string;
|
|
212
|
+
name?: string;
|
|
213
|
+
primary_uri?: string;
|
|
214
|
+
}
|
|
215
|
+
export interface SipProfileAssignParams {
|
|
216
|
+
/**
|
|
217
|
+
* The SIP profile to assign, or null to clear the number's current assignment.
|
|
218
|
+
*/
|
|
219
|
+
sip_profile_id: string | null;
|
|
220
|
+
}
|
|
221
|
+
export declare namespace SipProfiles {
|
|
222
|
+
export { type SipProfile as SipProfile, type SipProfileListResponse as SipProfileListResponse, type SipProfileAssignResponse as SipProfileAssignResponse, type SipProfileCreateParams as SipProfileCreateParams, type SipProfileUpdateParams as SipProfileUpdateParams, type SipProfileAssignParams as SipProfileAssignParams, };
|
|
223
|
+
}
|
|
224
|
+
//# sourceMappingURL=sip-profiles.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sip-profiles.d.ts","sourceRoot":"","sources":["../src/resources/sip-profiles.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,WAAW,EAAE,4BAAyB;AAC/C,OAAO,EAAE,UAAU,EAAE,+BAA4B;AAEjD,OAAO,EAAE,cAAc,EAAE,uCAAoC;AAG7D;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH,qBAAa,WAAY,SAAQ,WAAW;IAC1C;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OAiCG;IACH,MAAM,CAAC,IAAI,EAAE,sBAAsB,EAAE,OAAO,CAAC,EAAE,cAAc,GAAG,UAAU,CAAC,UAAU,CAAC;IAItF;;;;;;;;;OASG;IACH,QAAQ,CAAC,YAAY,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,cAAc,GAAG,UAAU,CAAC,UAAU,CAAC;IAIhF;;;;;;;;;;;OAWG;IACH,MAAM,CACJ,YAAY,EAAE,MAAM,EACpB,IAAI,EAAE,sBAAsB,EAC5B,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CAAC,UAAU,CAAC;IAIzB;;;;;;;OAOG;IACH,IAAI,CAAC,OAAO,CAAC,EAAE,cAAc,GAAG,UAAU,CAAC,sBAAsB,CAAC;IAI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IACrC;;OAEG;IACH,cAAc,EAAE,MAAM,GAAG,IAAI,CAAC;CAC/B;AAED,MAAM,CAAC,OAAO,WAAW,WAAW,CAAC;IACnC,OAAO,EACL,KAAK,UAAU,IAAI,UAAU,EAC7B,KAAK,sBAAsB,IAAI,sBAAsB,EACrD,KAAK,wBAAwB,IAAI,wBAAwB,EACzD,KAAK,sBAAsB,IAAI,sBAAsB,EACrD,KAAK,sBAAsB,IAAI,sBAAsB,EACrD,KAAK,sBAAsB,IAAI,sBAAsB,GACtD,CAAC;CACH"}
|
|
@@ -0,0 +1,168 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
3
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
+
exports.SipProfiles = void 0;
|
|
5
|
+
const resource_1 = require("../core/resource.js");
|
|
6
|
+
const headers_1 = require("../internal/headers.js");
|
|
7
|
+
const path_1 = require("../internal/utils/path.js");
|
|
8
|
+
/**
|
|
9
|
+
* ## SIP configuration
|
|
10
|
+
*
|
|
11
|
+
* Add these IP ranges to your SIP endpoint's allowlist:
|
|
12
|
+
*
|
|
13
|
+
* ```
|
|
14
|
+
* 54.172.60.0/30
|
|
15
|
+
* 54.244.51.0/30
|
|
16
|
+
* 168.86.128.0/18
|
|
17
|
+
* ```
|
|
18
|
+
*
|
|
19
|
+
* Set `primary_uri` to your endpoint as scheme + host — `sips:` for TLS or
|
|
20
|
+
* `sip:` for UDP, with no user part (we add it). Each call arrives at your
|
|
21
|
+
* endpoint as:
|
|
22
|
+
*
|
|
23
|
+
* ```
|
|
24
|
+
* sip:<called-number>@<your-host>
|
|
25
|
+
* ```
|
|
26
|
+
*
|
|
27
|
+
* so you can route on the dialed number. The caller's number is in the
|
|
28
|
+
* `From` header in E.164. Media (RTP) uses UDP ports 10000–60000.
|
|
29
|
+
*/
|
|
30
|
+
class SipProfiles extends resource_1.APIResource {
|
|
31
|
+
/**
|
|
32
|
+
* ## SIP configuration
|
|
33
|
+
*
|
|
34
|
+
* Add these IP ranges to your SIP endpoint's allowlist:
|
|
35
|
+
*
|
|
36
|
+
* ```
|
|
37
|
+
* 54.172.60.0/30
|
|
38
|
+
* 54.244.51.0/30
|
|
39
|
+
* 168.86.128.0/18
|
|
40
|
+
* ```
|
|
41
|
+
*
|
|
42
|
+
* Set `primary_uri` to your endpoint as scheme + host — `sips:` for TLS or `sip:`
|
|
43
|
+
* for UDP, with no user part (we add it). Each call arrives at your endpoint as:
|
|
44
|
+
*
|
|
45
|
+
* ```
|
|
46
|
+
* sip:<called-number>@<your-host>
|
|
47
|
+
* ```
|
|
48
|
+
*
|
|
49
|
+
* so you can route on the dialed number. The caller's number is in the `From`
|
|
50
|
+
* header in E.164. Media (RTP) uses UDP ports 10000–60000.
|
|
51
|
+
*
|
|
52
|
+
* ---
|
|
53
|
+
*
|
|
54
|
+
* Create a SIP routing profile for your inbound calls, then assign it to a phone
|
|
55
|
+
* number to start routing calls to its SIP URI.
|
|
56
|
+
*
|
|
57
|
+
* @example
|
|
58
|
+
* ```ts
|
|
59
|
+
* const sipProfile = await client.sipProfiles.create({
|
|
60
|
+
* name: 'byoc-primary',
|
|
61
|
+
* primary_uri: 'sips:sip.partner.example',
|
|
62
|
+
* });
|
|
63
|
+
* ```
|
|
64
|
+
*/
|
|
65
|
+
create(body, options) {
|
|
66
|
+
return this._client.post('/v3/sip-profiles', { body, ...options });
|
|
67
|
+
}
|
|
68
|
+
/**
|
|
69
|
+
* Retrieve details for a specific SIP profile.
|
|
70
|
+
*
|
|
71
|
+
* @example
|
|
72
|
+
* ```ts
|
|
73
|
+
* const sipProfile = await client.sipProfiles.retrieve(
|
|
74
|
+
* 'sip_8a3f9c2b1d4e4f5a9b8c7d6e5f4a3b2c',
|
|
75
|
+
* );
|
|
76
|
+
* ```
|
|
77
|
+
*/
|
|
78
|
+
retrieve(sipProfileID, options) {
|
|
79
|
+
return this._client.get((0, path_1.path) `/v3/sip-profiles/${sipProfileID}`, options);
|
|
80
|
+
}
|
|
81
|
+
/**
|
|
82
|
+
* Update a SIP profile. Only the fields you send are changed; omitted fields keep
|
|
83
|
+
* their current value. Set `backup_uri` to an empty string to clear it.
|
|
84
|
+
*
|
|
85
|
+
* @example
|
|
86
|
+
* ```ts
|
|
87
|
+
* const sipProfile = await client.sipProfiles.update(
|
|
88
|
+
* 'sip_8a3f9c2b1d4e4f5a9b8c7d6e5f4a3b2c',
|
|
89
|
+
* { name: 'byoc-east' },
|
|
90
|
+
* );
|
|
91
|
+
* ```
|
|
92
|
+
*/
|
|
93
|
+
update(sipProfileID, body, options) {
|
|
94
|
+
return this._client.put((0, path_1.path) `/v3/sip-profiles/${sipProfileID}`, { body, ...options });
|
|
95
|
+
}
|
|
96
|
+
/**
|
|
97
|
+
* Retrieve all SIP profiles for the authenticated partner.
|
|
98
|
+
*
|
|
99
|
+
* @example
|
|
100
|
+
* ```ts
|
|
101
|
+
* const sipProfiles = await client.sipProfiles.list();
|
|
102
|
+
* ```
|
|
103
|
+
*/
|
|
104
|
+
list(options) {
|
|
105
|
+
return this._client.get('/v3/sip-profiles', options);
|
|
106
|
+
}
|
|
107
|
+
/**
|
|
108
|
+
* Delete a SIP profile. The profile must not be assigned to any phone number;
|
|
109
|
+
* unassign it first or the request is rejected.
|
|
110
|
+
*
|
|
111
|
+
* @example
|
|
112
|
+
* ```ts
|
|
113
|
+
* await client.sipProfiles.delete(
|
|
114
|
+
* 'sip_8a3f9c2b1d4e4f5a9b8c7d6e5f4a3b2c',
|
|
115
|
+
* );
|
|
116
|
+
* ```
|
|
117
|
+
*/
|
|
118
|
+
delete(sipProfileID, options) {
|
|
119
|
+
return this._client.delete((0, path_1.path) `/v3/sip-profiles/${sipProfileID}`, {
|
|
120
|
+
...options,
|
|
121
|
+
headers: (0, headers_1.buildHeaders)([{ Accept: '*/*' }, options?.headers]),
|
|
122
|
+
});
|
|
123
|
+
}
|
|
124
|
+
/**
|
|
125
|
+
* ## SIP configuration
|
|
126
|
+
*
|
|
127
|
+
* Add these IP ranges to your SIP endpoint's allowlist:
|
|
128
|
+
*
|
|
129
|
+
* ```
|
|
130
|
+
* 54.172.60.0/30
|
|
131
|
+
* 54.244.51.0/30
|
|
132
|
+
* 168.86.128.0/18
|
|
133
|
+
* ```
|
|
134
|
+
*
|
|
135
|
+
* Set `primary_uri` to your endpoint as scheme + host — `sips:` for TLS or `sip:`
|
|
136
|
+
* for UDP, with no user part (we add it). Each call arrives at your endpoint as:
|
|
137
|
+
*
|
|
138
|
+
* ```
|
|
139
|
+
* sip:<called-number>@<your-host>
|
|
140
|
+
* ```
|
|
141
|
+
*
|
|
142
|
+
* so you can route on the dialed number. The caller's number is in the `From`
|
|
143
|
+
* header in E.164. Media (RTP) uses UDP ports 10000–60000.
|
|
144
|
+
*
|
|
145
|
+
* ---
|
|
146
|
+
*
|
|
147
|
+
* Assign a SIP profile to route inbound calls to its SIP URI. This takes
|
|
148
|
+
* precedence over an existing `forwarding_number` without clearing it. Send
|
|
149
|
+
* `sip_profile_id: null` to remove the SIP assignment and resume existing
|
|
150
|
+
* forwarding, if configured. Allow about 5 minutes for routing changes to
|
|
151
|
+
* propagate. The phone number must belong to the authenticated partner.
|
|
152
|
+
*
|
|
153
|
+
* @example
|
|
154
|
+
* ```ts
|
|
155
|
+
* const response = await client.sipProfiles.assign(
|
|
156
|
+
* '+14254758217',
|
|
157
|
+
* {
|
|
158
|
+
* sip_profile_id: 'sip_8a3f9c2b1d4e4f5a9b8c7d6e5f4a3b2c',
|
|
159
|
+
* },
|
|
160
|
+
* );
|
|
161
|
+
* ```
|
|
162
|
+
*/
|
|
163
|
+
assign(phoneNumber, body, options) {
|
|
164
|
+
return this._client.put((0, path_1.path) `/v3/phone-numbers/${phoneNumber}/sip-profile`, { body, ...options });
|
|
165
|
+
}
|
|
166
|
+
}
|
|
167
|
+
exports.SipProfiles = SipProfiles;
|
|
168
|
+
//# sourceMappingURL=sip-profiles.js.map
|
|
@@ -0,0 +1 @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AO,EAAE,OAAO,CAAC,CAAC;SAC7D,CAAC,CAAC;IACL,CAAC;IAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OAsCG;IACH,MAAM,CACJ,WAAmB,EACnB,IAA4B,EAC5B,OAAwB;QAExB,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,IAAA,WAAI,EAAA,qBAAqB,WAAW,cAAc,EAAE,EAAE,IAAI,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IACpG,CAAC;CACF;AArJD,kCAqJC"}
|
|
@@ -0,0 +1,164 @@
|
|
|
1
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
import { APIResource } from "../core/resource.mjs";
|
|
3
|
+
import { buildHeaders } from "../internal/headers.mjs";
|
|
4
|
+
import { path } from "../internal/utils/path.mjs";
|
|
5
|
+
/**
|
|
6
|
+
* ## SIP configuration
|
|
7
|
+
*
|
|
8
|
+
* Add these IP ranges to your SIP endpoint's allowlist:
|
|
9
|
+
*
|
|
10
|
+
* ```
|
|
11
|
+
* 54.172.60.0/30
|
|
12
|
+
* 54.244.51.0/30
|
|
13
|
+
* 168.86.128.0/18
|
|
14
|
+
* ```
|
|
15
|
+
*
|
|
16
|
+
* Set `primary_uri` to your endpoint as scheme + host — `sips:` for TLS or
|
|
17
|
+
* `sip:` for UDP, with no user part (we add it). Each call arrives at your
|
|
18
|
+
* endpoint as:
|
|
19
|
+
*
|
|
20
|
+
* ```
|
|
21
|
+
* sip:<called-number>@<your-host>
|
|
22
|
+
* ```
|
|
23
|
+
*
|
|
24
|
+
* so you can route on the dialed number. The caller's number is in the
|
|
25
|
+
* `From` header in E.164. Media (RTP) uses UDP ports 10000–60000.
|
|
26
|
+
*/
|
|
27
|
+
export class SipProfiles extends APIResource {
|
|
28
|
+
/**
|
|
29
|
+
* ## SIP configuration
|
|
30
|
+
*
|
|
31
|
+
* Add these IP ranges to your SIP endpoint's allowlist:
|
|
32
|
+
*
|
|
33
|
+
* ```
|
|
34
|
+
* 54.172.60.0/30
|
|
35
|
+
* 54.244.51.0/30
|
|
36
|
+
* 168.86.128.0/18
|
|
37
|
+
* ```
|
|
38
|
+
*
|
|
39
|
+
* Set `primary_uri` to your endpoint as scheme + host — `sips:` for TLS or `sip:`
|
|
40
|
+
* for UDP, with no user part (we add it). Each call arrives at your endpoint as:
|
|
41
|
+
*
|
|
42
|
+
* ```
|
|
43
|
+
* sip:<called-number>@<your-host>
|
|
44
|
+
* ```
|
|
45
|
+
*
|
|
46
|
+
* so you can route on the dialed number. The caller's number is in the `From`
|
|
47
|
+
* header in E.164. Media (RTP) uses UDP ports 10000–60000.
|
|
48
|
+
*
|
|
49
|
+
* ---
|
|
50
|
+
*
|
|
51
|
+
* Create a SIP routing profile for your inbound calls, then assign it to a phone
|
|
52
|
+
* number to start routing calls to its SIP URI.
|
|
53
|
+
*
|
|
54
|
+
* @example
|
|
55
|
+
* ```ts
|
|
56
|
+
* const sipProfile = await client.sipProfiles.create({
|
|
57
|
+
* name: 'byoc-primary',
|
|
58
|
+
* primary_uri: 'sips:sip.partner.example',
|
|
59
|
+
* });
|
|
60
|
+
* ```
|
|
61
|
+
*/
|
|
62
|
+
create(body, options) {
|
|
63
|
+
return this._client.post('/v3/sip-profiles', { body, ...options });
|
|
64
|
+
}
|
|
65
|
+
/**
|
|
66
|
+
* Retrieve details for a specific SIP profile.
|
|
67
|
+
*
|
|
68
|
+
* @example
|
|
69
|
+
* ```ts
|
|
70
|
+
* const sipProfile = await client.sipProfiles.retrieve(
|
|
71
|
+
* 'sip_8a3f9c2b1d4e4f5a9b8c7d6e5f4a3b2c',
|
|
72
|
+
* );
|
|
73
|
+
* ```
|
|
74
|
+
*/
|
|
75
|
+
retrieve(sipProfileID, options) {
|
|
76
|
+
return this._client.get(path `/v3/sip-profiles/${sipProfileID}`, options);
|
|
77
|
+
}
|
|
78
|
+
/**
|
|
79
|
+
* Update a SIP profile. Only the fields you send are changed; omitted fields keep
|
|
80
|
+
* their current value. Set `backup_uri` to an empty string to clear it.
|
|
81
|
+
*
|
|
82
|
+
* @example
|
|
83
|
+
* ```ts
|
|
84
|
+
* const sipProfile = await client.sipProfiles.update(
|
|
85
|
+
* 'sip_8a3f9c2b1d4e4f5a9b8c7d6e5f4a3b2c',
|
|
86
|
+
* { name: 'byoc-east' },
|
|
87
|
+
* );
|
|
88
|
+
* ```
|
|
89
|
+
*/
|
|
90
|
+
update(sipProfileID, body, options) {
|
|
91
|
+
return this._client.put(path `/v3/sip-profiles/${sipProfileID}`, { body, ...options });
|
|
92
|
+
}
|
|
93
|
+
/**
|
|
94
|
+
* Retrieve all SIP profiles for the authenticated partner.
|
|
95
|
+
*
|
|
96
|
+
* @example
|
|
97
|
+
* ```ts
|
|
98
|
+
* const sipProfiles = await client.sipProfiles.list();
|
|
99
|
+
* ```
|
|
100
|
+
*/
|
|
101
|
+
list(options) {
|
|
102
|
+
return this._client.get('/v3/sip-profiles', options);
|
|
103
|
+
}
|
|
104
|
+
/**
|
|
105
|
+
* Delete a SIP profile. The profile must not be assigned to any phone number;
|
|
106
|
+
* unassign it first or the request is rejected.
|
|
107
|
+
*
|
|
108
|
+
* @example
|
|
109
|
+
* ```ts
|
|
110
|
+
* await client.sipProfiles.delete(
|
|
111
|
+
* 'sip_8a3f9c2b1d4e4f5a9b8c7d6e5f4a3b2c',
|
|
112
|
+
* );
|
|
113
|
+
* ```
|
|
114
|
+
*/
|
|
115
|
+
delete(sipProfileID, options) {
|
|
116
|
+
return this._client.delete(path `/v3/sip-profiles/${sipProfileID}`, {
|
|
117
|
+
...options,
|
|
118
|
+
headers: buildHeaders([{ Accept: '*/*' }, options?.headers]),
|
|
119
|
+
});
|
|
120
|
+
}
|
|
121
|
+
/**
|
|
122
|
+
* ## SIP configuration
|
|
123
|
+
*
|
|
124
|
+
* Add these IP ranges to your SIP endpoint's allowlist:
|
|
125
|
+
*
|
|
126
|
+
* ```
|
|
127
|
+
* 54.172.60.0/30
|
|
128
|
+
* 54.244.51.0/30
|
|
129
|
+
* 168.86.128.0/18
|
|
130
|
+
* ```
|
|
131
|
+
*
|
|
132
|
+
* Set `primary_uri` to your endpoint as scheme + host — `sips:` for TLS or `sip:`
|
|
133
|
+
* for UDP, with no user part (we add it). Each call arrives at your endpoint as:
|
|
134
|
+
*
|
|
135
|
+
* ```
|
|
136
|
+
* sip:<called-number>@<your-host>
|
|
137
|
+
* ```
|
|
138
|
+
*
|
|
139
|
+
* so you can route on the dialed number. The caller's number is in the `From`
|
|
140
|
+
* header in E.164. Media (RTP) uses UDP ports 10000–60000.
|
|
141
|
+
*
|
|
142
|
+
* ---
|
|
143
|
+
*
|
|
144
|
+
* Assign a SIP profile to route inbound calls to its SIP URI. This takes
|
|
145
|
+
* precedence over an existing `forwarding_number` without clearing it. Send
|
|
146
|
+
* `sip_profile_id: null` to remove the SIP assignment and resume existing
|
|
147
|
+
* forwarding, if configured. Allow about 5 minutes for routing changes to
|
|
148
|
+
* propagate. The phone number must belong to the authenticated partner.
|
|
149
|
+
*
|
|
150
|
+
* @example
|
|
151
|
+
* ```ts
|
|
152
|
+
* const response = await client.sipProfiles.assign(
|
|
153
|
+
* '+14254758217',
|
|
154
|
+
* {
|
|
155
|
+
* sip_profile_id: 'sip_8a3f9c2b1d4e4f5a9b8c7d6e5f4a3b2c',
|
|
156
|
+
* },
|
|
157
|
+
* );
|
|
158
|
+
* ```
|
|
159
|
+
*/
|
|
160
|
+
assign(phoneNumber, body, options) {
|
|
161
|
+
return this._client.put(path `/v3/phone-numbers/${phoneNumber}/sip-profile`, { body, ...options });
|
|
162
|
+
}
|
|
163
|
+
}
|
|
164
|
+
//# sourceMappingURL=sip-profiles.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sip-profiles.mjs","sourceRoot":"","sources":["../src/resources/sip-profiles.ts"],"names":[],"mappings":"AAAA,sFAAsF;AAEtF,OAAO,EAAE,WAAW,EAAE,6BAAyB;AAE/C,OAAO,EA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sCG;IACH,MAAM,CACJ,WAAmB,EACnB,IAA4B,EAC5B,OAAwB;QAExB,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,IAAI,CAAA,qBAAqB,WAAW,cAAc,EAAE,EAAE,IAAI,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IACpG,CAAC;CACF"}
|
|
@@ -144,7 +144,7 @@ export declare class WebhookEvents extends APIResource {
|
|
|
144
144
|
* `webhook_version: "2026-02-03"`. Subscribing to this event on a v2025
|
|
145
145
|
* subscription will not produce any deliveries.
|
|
146
146
|
*/
|
|
147
|
-
export type WebhookEventType = 'message.sent' | 'message.received' | 'message.read' | 'message.delivered' | 'message.failed' | 'message.edited' | 'reaction.added' | 'reaction.removed' | 'poll.received' | 'poll.failed' | 'poll.sent' | 'poll.delivered' | 'poll.read' | 'poll.updated' | 'poll.vote.added' | 'poll.vote.removed' | 'poll.reaction.added' | 'participant.added' | 'participant.removed' | 'chat.created' | 'chat.group_name_updated' | 'chat.group_icon_updated' | 'chat.group_name_update_failed' | 'chat.group_icon_update_failed' | 'chat.background_updated' | 'chat.background_update_failed' | 'chat.typing_indicator.started' | 'chat.typing_indicator.stopped' | 'phone_number.status_updated' | 'phone_number.assigned' | 'phone_number.released' | '
|
|
147
|
+
export type WebhookEventType = 'message.sent' | 'message.received' | 'message.read' | 'message.delivered' | 'message.failed' | 'message.edited' | 'reaction.added' | 'reaction.removed' | 'poll.received' | 'poll.failed' | 'poll.sent' | 'poll.delivered' | 'poll.read' | 'poll.updated' | 'poll.vote.added' | 'poll.vote.removed' | 'poll.reaction.added' | 'participant.added' | 'participant.removed' | 'chat.created' | 'chat.group_name_updated' | 'chat.group_icon_updated' | 'chat.group_name_update_failed' | 'chat.group_icon_update_failed' | 'chat.background_updated' | 'chat.background_update_failed' | 'chat.typing_indicator.started' | 'chat.typing_indicator.stopped' | 'phone_number.status_updated' | 'phone_number.assigned' | 'phone_number.released' | 'phone_number.line_type_updated' | 'contact_card.received' | 'location.sharing.started' | 'location.sharing.stopped' | 'payment.succeeded' | 'payment.canceled' | 'payment.expired' | 'payment.declined' | 'payment.authorized' | 'connection.created' | 'connection.revoked' | 'zero_day_retention.updated' | 'phone_number.forwarding_updated' | 'environment.line_moved' | 'contact_card.created' | 'contact_card.updated' | 'contact_card.deleted' | 'api_token.created' | 'api_token.renamed' | 'api_token.expiry_scheduled' | 'api_token.expired' | 'api_token.activated' | 'api_token.deleted' | 'environment.created' | 'environment.renamed' | 'environment.deleted' | 'webhook_subscription.created' | 'webhook_subscription.deleted' | 'webhook_subscription.target_url_changed' | 'webhook_subscription.enabled' | 'webhook_subscription.disabled' | 'webhook_subscription.events.updated' | 'webhook_subscription.phone_numbers.updated' | 'webhook_subscription.routing_headers_set' | 'webhook_subscription.routing_headers_cleared' | 'team_member.added' | 'team_member.signed_in' | 'team_member.signed_out';
|
|
148
148
|
export interface WebhookEventListResponse {
|
|
149
149
|
/**
|
|
150
150
|
* URL to the webhook events documentation
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"webhook-events.d.mts","sourceRoot":"","sources":["../src/resources/webhook-events.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,WAAW,EAAE,6BAAyB;AAC/C,OAAO,EAAE,UAAU,EAAE,gCAA4B;AACjD,OAAO,EAAE,cAAc,EAAE,wCAAoC;AAE7D;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+HG;AACH,qBAAa,aAAc,SAAQ,WAAW;IAC5C;;;;OAIG;IACH,IAAI,CAAC,OAAO,CAAC,EAAE,cAAc,GAAG,UAAU,CAAC,wBAAwB,CAAC;CAGrE;AAED;;;;;;GAMG;AACH,MAAM,MAAM,gBAAgB,GACxB,cAAc,GACd,kBAAkB,GAClB,cAAc,GACd,mBAAmB,GACnB,gBAAgB,GAChB,gBAAgB,GAChB,gBAAgB,GAChB,kBAAkB,GAClB,eAAe,GACf,aAAa,GACb,WAAW,GACX,gBAAgB,GAChB,WAAW,GACX,cAAc,GACd,iBAAiB,GACjB,mBAAmB,GACnB,qBAAqB,GACrB,mBAAmB,GACnB,qBAAqB,GACrB,cAAc,GACd,yBAAyB,GACzB,yBAAyB,GACzB,+BAA+B,GAC/B,+BAA+B,GAC/B,yBAAyB,GACzB,+BAA+B,GAC/B,+BAA+B,GAC/B,+BAA+B,GAC/B,6BAA6B,GAC7B,uBAAuB,GACvB,uBAAuB,GACvB,uBAAuB,GACvB,
|
|
1
|
+
{"version":3,"file":"webhook-events.d.mts","sourceRoot":"","sources":["../src/resources/webhook-events.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,WAAW,EAAE,6BAAyB;AAC/C,OAAO,EAAE,UAAU,EAAE,gCAA4B;AACjD,OAAO,EAAE,cAAc,EAAE,wCAAoC;AAE7D;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+HG;AACH,qBAAa,aAAc,SAAQ,WAAW;IAC5C;;;;OAIG;IACH,IAAI,CAAC,OAAO,CAAC,EAAE,cAAc,GAAG,UAAU,CAAC,wBAAwB,CAAC;CAGrE;AAED;;;;;;GAMG;AACH,MAAM,MAAM,gBAAgB,GACxB,cAAc,GACd,kBAAkB,GAClB,cAAc,GACd,mBAAmB,GACnB,gBAAgB,GAChB,gBAAgB,GAChB,gBAAgB,GAChB,kBAAkB,GAClB,eAAe,GACf,aAAa,GACb,WAAW,GACX,gBAAgB,GAChB,WAAW,GACX,cAAc,GACd,iBAAiB,GACjB,mBAAmB,GACnB,qBAAqB,GACrB,mBAAmB,GACnB,qBAAqB,GACrB,cAAc,GACd,yBAAyB,GACzB,yBAAyB,GACzB,+BAA+B,GAC/B,+BAA+B,GAC/B,yBAAyB,GACzB,+BAA+B,GAC/B,+BAA+B,GAC/B,+BAA+B,GAC/B,6BAA6B,GAC7B,uBAAuB,GACvB,uBAAuB,GACvB,gCAAgC,GAChC,uBAAuB,GACvB,0BAA0B,GAC1B,0BAA0B,GAC1B,mBAAmB,GACnB,kBAAkB,GAClB,iBAAiB,GACjB,kBAAkB,GAClB,oBAAoB,GACpB,oBAAoB,GACpB,oBAAoB,GACpB,4BAA4B,GAC5B,iCAAiC,GACjC,wBAAwB,GACxB,sBAAsB,GACtB,sBAAsB,GACtB,sBAAsB,GACtB,mBAAmB,GACnB,mBAAmB,GACnB,4BAA4B,GAC5B,mBAAmB,GACnB,qBAAqB,GACrB,mBAAmB,GACnB,qBAAqB,GACrB,qBAAqB,GACrB,qBAAqB,GACrB,8BAA8B,GAC9B,8BAA8B,GAC9B,yCAAyC,GACzC,8BAA8B,GAC9B,+BAA+B,GAC/B,qCAAqC,GACrC,4CAA4C,GAC5C,0CAA0C,GAC1C,8CAA8C,GAC9C,mBAAmB,GACnB,uBAAuB,GACvB,wBAAwB,CAAC;AAE7B,MAAM,WAAW,wBAAwB;IACvC;;OAEG;IACH,OAAO,EAAE,kEAAkE,CAAC;IAE5E;;OAEG;IACH,MAAM,EAAE,KAAK,CAAC,gBAAgB,CAAC,CAAC;CACjC;AAED,MAAM,CAAC,OAAO,WAAW,aAAa,CAAC;IACrC,OAAO,EACL,KAAK,gBAAgB,IAAI,gBAAgB,EACzC,KAAK,wBAAwB,IAAI,wBAAwB,GAC1D,CAAC;CACH"}
|
|
@@ -144,7 +144,7 @@ export declare class WebhookEvents extends APIResource {
|
|
|
144
144
|
* `webhook_version: "2026-02-03"`. Subscribing to this event on a v2025
|
|
145
145
|
* subscription will not produce any deliveries.
|
|
146
146
|
*/
|
|
147
|
-
export type WebhookEventType = 'message.sent' | 'message.received' | 'message.read' | 'message.delivered' | 'message.failed' | 'message.edited' | 'reaction.added' | 'reaction.removed' | 'poll.received' | 'poll.failed' | 'poll.sent' | 'poll.delivered' | 'poll.read' | 'poll.updated' | 'poll.vote.added' | 'poll.vote.removed' | 'poll.reaction.added' | 'participant.added' | 'participant.removed' | 'chat.created' | 'chat.group_name_updated' | 'chat.group_icon_updated' | 'chat.group_name_update_failed' | 'chat.group_icon_update_failed' | 'chat.background_updated' | 'chat.background_update_failed' | 'chat.typing_indicator.started' | 'chat.typing_indicator.stopped' | 'phone_number.status_updated' | 'phone_number.assigned' | 'phone_number.released' | '
|
|
147
|
+
export type WebhookEventType = 'message.sent' | 'message.received' | 'message.read' | 'message.delivered' | 'message.failed' | 'message.edited' | 'reaction.added' | 'reaction.removed' | 'poll.received' | 'poll.failed' | 'poll.sent' | 'poll.delivered' | 'poll.read' | 'poll.updated' | 'poll.vote.added' | 'poll.vote.removed' | 'poll.reaction.added' | 'participant.added' | 'participant.removed' | 'chat.created' | 'chat.group_name_updated' | 'chat.group_icon_updated' | 'chat.group_name_update_failed' | 'chat.group_icon_update_failed' | 'chat.background_updated' | 'chat.background_update_failed' | 'chat.typing_indicator.started' | 'chat.typing_indicator.stopped' | 'phone_number.status_updated' | 'phone_number.assigned' | 'phone_number.released' | 'phone_number.line_type_updated' | 'contact_card.received' | 'location.sharing.started' | 'location.sharing.stopped' | 'payment.succeeded' | 'payment.canceled' | 'payment.expired' | 'payment.declined' | 'payment.authorized' | 'connection.created' | 'connection.revoked' | 'zero_day_retention.updated' | 'phone_number.forwarding_updated' | 'environment.line_moved' | 'contact_card.created' | 'contact_card.updated' | 'contact_card.deleted' | 'api_token.created' | 'api_token.renamed' | 'api_token.expiry_scheduled' | 'api_token.expired' | 'api_token.activated' | 'api_token.deleted' | 'environment.created' | 'environment.renamed' | 'environment.deleted' | 'webhook_subscription.created' | 'webhook_subscription.deleted' | 'webhook_subscription.target_url_changed' | 'webhook_subscription.enabled' | 'webhook_subscription.disabled' | 'webhook_subscription.events.updated' | 'webhook_subscription.phone_numbers.updated' | 'webhook_subscription.routing_headers_set' | 'webhook_subscription.routing_headers_cleared' | 'team_member.added' | 'team_member.signed_in' | 'team_member.signed_out';
|
|
148
148
|
export interface WebhookEventListResponse {
|
|
149
149
|
/**
|
|
150
150
|
* URL to the webhook events documentation
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"webhook-events.d.ts","sourceRoot":"","sources":["../src/resources/webhook-events.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,WAAW,EAAE,4BAAyB;AAC/C,OAAO,EAAE,UAAU,EAAE,+BAA4B;AACjD,OAAO,EAAE,cAAc,EAAE,uCAAoC;AAE7D;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+HG;AACH,qBAAa,aAAc,SAAQ,WAAW;IAC5C;;;;OAIG;IACH,IAAI,CAAC,OAAO,CAAC,EAAE,cAAc,GAAG,UAAU,CAAC,wBAAwB,CAAC;CAGrE;AAED;;;;;;GAMG;AACH,MAAM,MAAM,gBAAgB,GACxB,cAAc,GACd,kBAAkB,GAClB,cAAc,GACd,mBAAmB,GACnB,gBAAgB,GAChB,gBAAgB,GAChB,gBAAgB,GAChB,kBAAkB,GAClB,eAAe,GACf,aAAa,GACb,WAAW,GACX,gBAAgB,GAChB,WAAW,GACX,cAAc,GACd,iBAAiB,GACjB,mBAAmB,GACnB,qBAAqB,GACrB,mBAAmB,GACnB,qBAAqB,GACrB,cAAc,GACd,yBAAyB,GACzB,yBAAyB,GACzB,+BAA+B,GAC/B,+BAA+B,GAC/B,yBAAyB,GACzB,+BAA+B,GAC/B,+BAA+B,GAC/B,+BAA+B,GAC/B,6BAA6B,GAC7B,uBAAuB,GACvB,uBAAuB,GACvB,uBAAuB,GACvB,
|
|
1
|
+
{"version":3,"file":"webhook-events.d.ts","sourceRoot":"","sources":["../src/resources/webhook-events.ts"],"names":[],"mappings":"AAEA,OAAO,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