agentphone 1.0.8 → 1.0.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/BaseClient.js +2 -2
- package/dist/cjs/Client.d.ts +3 -0
- package/dist/cjs/Client.js +17 -12
- package/dist/cjs/api/resources/agentSignup/client/Client.d.ts +1 -1
- package/dist/cjs/api/resources/agentSignup/client/Client.js +1 -1
- package/dist/cjs/api/resources/agents/client/Client.d.ts +1 -1
- package/dist/cjs/api/resources/agents/client/Client.js +1 -1
- package/dist/cjs/api/resources/agents/client/requests/CreateAgentRequest.d.ts +2 -0
- package/dist/cjs/api/resources/agents/client/requests/UpdateAgentRequest.d.ts +2 -0
- package/dist/cjs/api/resources/calls/client/Client.d.ts +20 -0
- package/dist/cjs/api/resources/calls/client/Client.js +56 -0
- package/dist/cjs/api/resources/calls/client/requests/EndCallV1CallsCallIdEndPostRequest.d.ts +9 -0
- package/dist/cjs/api/resources/calls/client/requests/EndCallV1CallsCallIdEndPostRequest.js +3 -0
- package/dist/cjs/api/resources/calls/client/requests/index.d.ts +1 -0
- package/dist/cjs/api/resources/contactCards/client/Client.d.ts +61 -0
- package/dist/cjs/api/resources/contactCards/client/Client.js +229 -0
- package/dist/cjs/api/resources/contactCards/client/index.d.ts +1 -0
- package/dist/cjs/api/resources/contactCards/client/index.js +17 -0
- package/dist/cjs/api/resources/contactCards/client/requests/ContactCardWriteRequest.d.ts +16 -0
- package/dist/cjs/api/resources/contactCards/client/requests/ContactCardWriteRequest.js +3 -0
- package/dist/cjs/api/resources/contactCards/client/requests/DeleteContactCardV1NumbersNumberIdContactCardDeleteRequest.d.ts +9 -0
- package/dist/cjs/api/resources/contactCards/client/requests/DeleteContactCardV1NumbersNumberIdContactCardDeleteRequest.js +3 -0
- package/dist/cjs/api/resources/contactCards/client/requests/GetContactCardV1NumbersNumberIdContactCardGetRequest.d.ts +9 -0
- package/dist/cjs/api/resources/contactCards/client/requests/GetContactCardV1NumbersNumberIdContactCardGetRequest.js +3 -0
- package/dist/cjs/api/resources/contactCards/client/requests/index.d.ts +3 -0
- package/dist/cjs/api/resources/contactCards/client/requests/index.js +2 -0
- package/dist/cjs/api/resources/contactCards/index.d.ts +1 -0
- package/dist/cjs/api/resources/contactCards/index.js +17 -0
- package/dist/cjs/api/resources/conversations/client/Client.d.ts +1 -0
- package/dist/cjs/api/resources/conversations/client/Client.js +1 -0
- package/dist/cjs/api/resources/index.d.ts +2 -0
- package/dist/cjs/api/resources/index.js +3 -1
- package/dist/cjs/api/resources/messages/client/Client.d.ts +10 -11
- package/dist/cjs/api/resources/messages/client/Client.js +10 -11
- package/dist/cjs/api/resources/messages/client/requests/SendMessageRequest.d.ts +20 -0
- package/dist/cjs/api/resources/messages/client/requests/SendMessageRequest.js +19 -0
- package/dist/cjs/api/resources/messages/client/requests/SendReactionRequest.d.ts +15 -2
- package/dist/cjs/api/resources/messages/client/requests/SendReactionRequest.js +13 -0
- package/dist/cjs/api/resources/messages/client/requests/index.d.ts +2 -2
- package/dist/cjs/api/resources/messages/client/requests/index.js +5 -0
- package/dist/cjs/api/resources/numbers/client/Client.d.ts +4 -4
- package/dist/cjs/api/resources/numbers/client/Client.js +4 -4
- package/dist/cjs/api/types/AgentResponse.d.ts +1 -0
- package/dist/cjs/api/types/ContactCardResponse.d.ts +6 -0
- package/dist/cjs/api/types/ContactCardResponse.js +3 -0
- package/dist/cjs/api/types/index.d.ts +1 -0
- package/dist/cjs/api/types/index.js +1 -0
- package/dist/cjs/environments.d.ts +1 -1
- package/dist/cjs/environments.js +1 -1
- package/dist/cjs/version.d.ts +1 -1
- package/dist/cjs/version.js +1 -1
- package/dist/esm/BaseClient.mjs +2 -2
- package/dist/esm/Client.d.mts +3 -0
- package/dist/esm/Client.mjs +5 -0
- package/dist/esm/api/resources/agentSignup/client/Client.d.mts +1 -1
- package/dist/esm/api/resources/agentSignup/client/Client.mjs +1 -1
- package/dist/esm/api/resources/agents/client/Client.d.mts +1 -1
- package/dist/esm/api/resources/agents/client/Client.mjs +1 -1
- package/dist/esm/api/resources/agents/client/requests/CreateAgentRequest.d.mts +2 -0
- package/dist/esm/api/resources/agents/client/requests/UpdateAgentRequest.d.mts +2 -0
- package/dist/esm/api/resources/calls/client/Client.d.mts +20 -0
- package/dist/esm/api/resources/calls/client/Client.mjs +56 -0
- package/dist/esm/api/resources/calls/client/requests/EndCallV1CallsCallIdEndPostRequest.d.mts +9 -0
- package/dist/esm/api/resources/calls/client/requests/EndCallV1CallsCallIdEndPostRequest.mjs +2 -0
- package/dist/esm/api/resources/calls/client/requests/index.d.mts +1 -0
- package/dist/esm/api/resources/contactCards/client/Client.d.mts +61 -0
- package/dist/esm/api/resources/contactCards/client/Client.mjs +192 -0
- package/dist/esm/api/resources/contactCards/client/index.d.mts +1 -0
- package/dist/esm/api/resources/contactCards/client/index.mjs +1 -0
- package/dist/esm/api/resources/contactCards/client/requests/ContactCardWriteRequest.d.mts +16 -0
- package/dist/esm/api/resources/contactCards/client/requests/ContactCardWriteRequest.mjs +2 -0
- package/dist/esm/api/resources/contactCards/client/requests/DeleteContactCardV1NumbersNumberIdContactCardDeleteRequest.d.mts +9 -0
- package/dist/esm/api/resources/contactCards/client/requests/DeleteContactCardV1NumbersNumberIdContactCardDeleteRequest.mjs +2 -0
- package/dist/esm/api/resources/contactCards/client/requests/GetContactCardV1NumbersNumberIdContactCardGetRequest.d.mts +9 -0
- package/dist/esm/api/resources/contactCards/client/requests/GetContactCardV1NumbersNumberIdContactCardGetRequest.mjs +2 -0
- package/dist/esm/api/resources/contactCards/client/requests/index.d.mts +3 -0
- package/dist/esm/api/resources/contactCards/client/requests/index.mjs +1 -0
- package/dist/esm/api/resources/contactCards/index.d.mts +1 -0
- package/dist/esm/api/resources/contactCards/index.mjs +1 -0
- package/dist/esm/api/resources/conversations/client/Client.d.mts +1 -0
- package/dist/esm/api/resources/conversations/client/Client.mjs +1 -0
- package/dist/esm/api/resources/index.d.mts +2 -0
- package/dist/esm/api/resources/index.mjs +2 -0
- package/dist/esm/api/resources/messages/client/Client.d.mts +10 -11
- package/dist/esm/api/resources/messages/client/Client.mjs +10 -11
- package/dist/esm/api/resources/messages/client/requests/SendMessageRequest.d.mts +20 -0
- package/dist/esm/api/resources/messages/client/requests/SendMessageRequest.mjs +18 -1
- package/dist/esm/api/resources/messages/client/requests/SendReactionRequest.d.mts +15 -2
- package/dist/esm/api/resources/messages/client/requests/SendReactionRequest.mjs +12 -1
- package/dist/esm/api/resources/messages/client/requests/index.d.mts +2 -2
- package/dist/esm/api/resources/messages/client/requests/index.mjs +2 -1
- package/dist/esm/api/resources/numbers/client/Client.d.mts +4 -4
- package/dist/esm/api/resources/numbers/client/Client.mjs +4 -4
- package/dist/esm/api/types/AgentResponse.d.mts +1 -0
- package/dist/esm/api/types/ContactCardResponse.d.mts +6 -0
- package/dist/esm/api/types/ContactCardResponse.mjs +2 -0
- package/dist/esm/api/types/index.d.mts +1 -0
- package/dist/esm/api/types/index.mjs +1 -0
- package/dist/esm/environments.d.mts +1 -1
- package/dist/esm/environments.mjs +1 -1
- package/dist/esm/version.d.mts +1 -1
- package/dist/esm/version.mjs +1 -1
- package/package.json +1 -1
- package/reference.md +286 -17
package/dist/cjs/BaseClient.js
CHANGED
|
@@ -43,8 +43,8 @@ function normalizeClientOptions(options) {
|
|
|
43
43
|
const headers = (0, headers_js_1.mergeHeaders)({
|
|
44
44
|
"X-Fern-Language": "JavaScript",
|
|
45
45
|
"X-Fern-SDK-Name": "agentphone",
|
|
46
|
-
"X-Fern-SDK-Version": "1.0.
|
|
47
|
-
"User-Agent": "agentphone/1.0.
|
|
46
|
+
"X-Fern-SDK-Version": "1.0.10",
|
|
47
|
+
"User-Agent": "agentphone/1.0.10",
|
|
48
48
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
49
49
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
50
50
|
}, options === null || options === void 0 ? void 0 : options.headers);
|
package/dist/cjs/Client.d.ts
CHANGED
|
@@ -2,6 +2,7 @@ import { AgentSignupClient } from "./api/resources/agentSignup/client/Client.js"
|
|
|
2
2
|
import { AgentsClient } from "./api/resources/agents/client/Client.js";
|
|
3
3
|
import { AgentWebhooksClient } from "./api/resources/agentWebhooks/client/Client.js";
|
|
4
4
|
import { CallsClient } from "./api/resources/calls/client/Client.js";
|
|
5
|
+
import { ContactCardsClient } from "./api/resources/contactCards/client/Client.js";
|
|
5
6
|
import { ContactsClient } from "./api/resources/contacts/client/Client.js";
|
|
6
7
|
import { ConversationsClient } from "./api/resources/conversations/client/Client.js";
|
|
7
8
|
import { MessagesClient } from "./api/resources/messages/client/Client.js";
|
|
@@ -27,6 +28,7 @@ export declare class AgentPhoneClient {
|
|
|
27
28
|
protected _calls: CallsClient | undefined;
|
|
28
29
|
protected _usage: UsageClient | undefined;
|
|
29
30
|
protected _messages: MessagesClient | undefined;
|
|
31
|
+
protected _contactCards: ContactCardsClient | undefined;
|
|
30
32
|
constructor(options?: AgentPhoneClient.Options);
|
|
31
33
|
get agentSignup(): AgentSignupClient;
|
|
32
34
|
get agents(): AgentsClient;
|
|
@@ -38,4 +40,5 @@ export declare class AgentPhoneClient {
|
|
|
38
40
|
get calls(): CallsClient;
|
|
39
41
|
get usage(): UsageClient;
|
|
40
42
|
get messages(): MessagesClient;
|
|
43
|
+
get contactCards(): ContactCardsClient;
|
|
41
44
|
}
|
package/dist/cjs/Client.js
CHANGED
|
@@ -6,12 +6,13 @@ const Client_js_1 = require("./api/resources/agentSignup/client/Client.js");
|
|
|
6
6
|
const Client_js_2 = require("./api/resources/agents/client/Client.js");
|
|
7
7
|
const Client_js_3 = require("./api/resources/agentWebhooks/client/Client.js");
|
|
8
8
|
const Client_js_4 = require("./api/resources/calls/client/Client.js");
|
|
9
|
-
const Client_js_5 = require("./api/resources/
|
|
10
|
-
const Client_js_6 = require("./api/resources/
|
|
11
|
-
const Client_js_7 = require("./api/resources/
|
|
12
|
-
const Client_js_8 = require("./api/resources/
|
|
13
|
-
const Client_js_9 = require("./api/resources/
|
|
14
|
-
const Client_js_10 = require("./api/resources/
|
|
9
|
+
const Client_js_5 = require("./api/resources/contactCards/client/Client.js");
|
|
10
|
+
const Client_js_6 = require("./api/resources/contacts/client/Client.js");
|
|
11
|
+
const Client_js_7 = require("./api/resources/conversations/client/Client.js");
|
|
12
|
+
const Client_js_8 = require("./api/resources/messages/client/Client.js");
|
|
13
|
+
const Client_js_9 = require("./api/resources/numbers/client/Client.js");
|
|
14
|
+
const Client_js_10 = require("./api/resources/usage/client/Client.js");
|
|
15
|
+
const Client_js_11 = require("./api/resources/webhooks/client/Client.js");
|
|
15
16
|
const BaseClient_js_1 = require("./BaseClient.js");
|
|
16
17
|
class AgentPhoneClient {
|
|
17
18
|
constructor(options = {}) {
|
|
@@ -27,11 +28,11 @@ class AgentPhoneClient {
|
|
|
27
28
|
}
|
|
28
29
|
get numbers() {
|
|
29
30
|
var _a;
|
|
30
|
-
return ((_a = this._numbers) !== null && _a !== void 0 ? _a : (this._numbers = new
|
|
31
|
+
return ((_a = this._numbers) !== null && _a !== void 0 ? _a : (this._numbers = new Client_js_9.NumbersClient(this._options)));
|
|
31
32
|
}
|
|
32
33
|
get webhooks() {
|
|
33
34
|
var _a;
|
|
34
|
-
return ((_a = this._webhooks) !== null && _a !== void 0 ? _a : (this._webhooks = new
|
|
35
|
+
return ((_a = this._webhooks) !== null && _a !== void 0 ? _a : (this._webhooks = new Client_js_11.WebhooksClient(this._options)));
|
|
35
36
|
}
|
|
36
37
|
get agentWebhooks() {
|
|
37
38
|
var _a;
|
|
@@ -39,11 +40,11 @@ class AgentPhoneClient {
|
|
|
39
40
|
}
|
|
40
41
|
get contacts() {
|
|
41
42
|
var _a;
|
|
42
|
-
return ((_a = this._contacts) !== null && _a !== void 0 ? _a : (this._contacts = new
|
|
43
|
+
return ((_a = this._contacts) !== null && _a !== void 0 ? _a : (this._contacts = new Client_js_6.ContactsClient(this._options)));
|
|
43
44
|
}
|
|
44
45
|
get conversations() {
|
|
45
46
|
var _a;
|
|
46
|
-
return ((_a = this._conversations) !== null && _a !== void 0 ? _a : (this._conversations = new
|
|
47
|
+
return ((_a = this._conversations) !== null && _a !== void 0 ? _a : (this._conversations = new Client_js_7.ConversationsClient(this._options)));
|
|
47
48
|
}
|
|
48
49
|
get calls() {
|
|
49
50
|
var _a;
|
|
@@ -51,11 +52,15 @@ class AgentPhoneClient {
|
|
|
51
52
|
}
|
|
52
53
|
get usage() {
|
|
53
54
|
var _a;
|
|
54
|
-
return ((_a = this._usage) !== null && _a !== void 0 ? _a : (this._usage = new
|
|
55
|
+
return ((_a = this._usage) !== null && _a !== void 0 ? _a : (this._usage = new Client_js_10.UsageClient(this._options)));
|
|
55
56
|
}
|
|
56
57
|
get messages() {
|
|
57
58
|
var _a;
|
|
58
|
-
return ((_a = this._messages) !== null && _a !== void 0 ? _a : (this._messages = new
|
|
59
|
+
return ((_a = this._messages) !== null && _a !== void 0 ? _a : (this._messages = new Client_js_8.MessagesClient(this._options)));
|
|
60
|
+
}
|
|
61
|
+
get contactCards() {
|
|
62
|
+
var _a;
|
|
63
|
+
return ((_a = this._contactCards) !== null && _a !== void 0 ? _a : (this._contactCards = new Client_js_5.ContactCardsClient(this._options)));
|
|
59
64
|
}
|
|
60
65
|
}
|
|
61
66
|
exports.AgentPhoneClient = AgentPhoneClient;
|
|
@@ -31,7 +31,7 @@ export declare class AgentSignupClient {
|
|
|
31
31
|
/**
|
|
32
32
|
* Verify the OTP and atomically provision everything.
|
|
33
33
|
*
|
|
34
|
-
* Creates: User + Project (+ mirrored Account) + starter hosted Agent +
|
|
34
|
+
* Creates: User + Project (+ mirrored Account) + starter hosted Agent + phone number
|
|
35
35
|
* + first-month charge + API key. Returns the key once — agents must save it.
|
|
36
36
|
*
|
|
37
37
|
* @param {AgentPhone.AgentVerifyRequest} request
|
|
@@ -113,7 +113,7 @@ class AgentSignupClient {
|
|
|
113
113
|
/**
|
|
114
114
|
* Verify the OTP and atomically provision everything.
|
|
115
115
|
*
|
|
116
|
-
* Creates: User + Project (+ mirrored Account) + starter hosted Agent +
|
|
116
|
+
* Creates: User + Project (+ mirrored Account) + starter hosted Agent + phone number
|
|
117
117
|
* + first-month charge + API key. Returns the key once — agents must save it.
|
|
118
118
|
*
|
|
119
119
|
* @param {AgentPhone.AgentVerifyRequest} request
|
|
@@ -11,7 +11,7 @@ export declare class AgentsClient {
|
|
|
11
11
|
protected readonly _options: NormalizedClientOptionsWithAuth<AgentsClient.Options>;
|
|
12
12
|
constructor(options?: AgentsClient.Options);
|
|
13
13
|
/**
|
|
14
|
-
* Return available voices
|
|
14
|
+
* Return available voices from the call provider (Retell).
|
|
15
15
|
*
|
|
16
16
|
* @param {AgentsClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
17
17
|
*
|
|
@@ -67,7 +67,7 @@ class AgentsClient {
|
|
|
67
67
|
this._options = (0, BaseClient_js_1.normalizeClientOptionsWithAuth)(options);
|
|
68
68
|
}
|
|
69
69
|
/**
|
|
70
|
-
* Return available voices
|
|
70
|
+
* Return available voices from the call provider (Retell).
|
|
71
71
|
*
|
|
72
72
|
* @param {AgentsClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
73
73
|
*
|
|
@@ -8,6 +8,8 @@ export interface CreateAgentRequest {
|
|
|
8
8
|
name: string;
|
|
9
9
|
description?: string | null;
|
|
10
10
|
voiceMode?: CreateAgentRequest.VoiceMode;
|
|
11
|
+
/** When true, hosted-mode agents can send and read SMS/iMessage during calls. Defaults to true. */
|
|
12
|
+
enableMessaging?: boolean | null;
|
|
11
13
|
modelTier?: CreateAgentRequest.ModelTier;
|
|
12
14
|
systemPrompt?: string | null;
|
|
13
15
|
beginMessage?: string | null;
|
|
@@ -9,6 +9,8 @@ export interface UpdateAgentRequest {
|
|
|
9
9
|
name?: string | null;
|
|
10
10
|
description?: string | null;
|
|
11
11
|
voiceMode?: UpdateAgentRequest.VoiceMode;
|
|
12
|
+
/** When true, hosted-mode agents can send and read SMS/iMessage during calls. */
|
|
13
|
+
enableMessaging?: boolean | null;
|
|
12
14
|
modelTier?: UpdateAgentRequest.ModelTier;
|
|
13
15
|
systemPrompt?: string | null;
|
|
14
16
|
beginMessage?: string | null;
|
|
@@ -90,6 +90,26 @@ export declare class CallsClient {
|
|
|
90
90
|
*/
|
|
91
91
|
getCall(request: AgentPhone.GetCallV1CallsCallIdGetRequest, requestOptions?: CallsClient.RequestOptions): core.HttpResponsePromise<unknown>;
|
|
92
92
|
private __getCall;
|
|
93
|
+
/**
|
|
94
|
+
* Terminate an ongoing call.
|
|
95
|
+
*
|
|
96
|
+
* Works for both hosted-mode and webhook-mode calls. The call_ended
|
|
97
|
+
* webhook from Retell updates status/endedAt asynchronously, so this
|
|
98
|
+
* endpoint returns the current call as soon as the stop request is
|
|
99
|
+
* accepted by Retell.
|
|
100
|
+
*
|
|
101
|
+
* @param {AgentPhone.EndCallV1CallsCallIdEndPostRequest} request
|
|
102
|
+
* @param {CallsClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
103
|
+
*
|
|
104
|
+
* @throws {@link AgentPhone.UnprocessableEntityError}
|
|
105
|
+
*
|
|
106
|
+
* @example
|
|
107
|
+
* await client.calls.endCall({
|
|
108
|
+
* call_id: "call_id"
|
|
109
|
+
* })
|
|
110
|
+
*/
|
|
111
|
+
endCall(request: AgentPhone.EndCallV1CallsCallIdEndPostRequest, requestOptions?: CallsClient.RequestOptions): core.HttpResponsePromise<unknown>;
|
|
112
|
+
private __endCall;
|
|
93
113
|
/**
|
|
94
114
|
* Returns the audio file (WAV format) for a completed call.
|
|
95
115
|
*
|
|
@@ -291,6 +291,62 @@ class CallsClient {
|
|
|
291
291
|
return (0, handleNonStatusCodeError_js_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "GET", "/v1/calls/{call_id}");
|
|
292
292
|
});
|
|
293
293
|
}
|
|
294
|
+
/**
|
|
295
|
+
* Terminate an ongoing call.
|
|
296
|
+
*
|
|
297
|
+
* Works for both hosted-mode and webhook-mode calls. The call_ended
|
|
298
|
+
* webhook from Retell updates status/endedAt asynchronously, so this
|
|
299
|
+
* endpoint returns the current call as soon as the stop request is
|
|
300
|
+
* accepted by Retell.
|
|
301
|
+
*
|
|
302
|
+
* @param {AgentPhone.EndCallV1CallsCallIdEndPostRequest} request
|
|
303
|
+
* @param {CallsClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
304
|
+
*
|
|
305
|
+
* @throws {@link AgentPhone.UnprocessableEntityError}
|
|
306
|
+
*
|
|
307
|
+
* @example
|
|
308
|
+
* await client.calls.endCall({
|
|
309
|
+
* call_id: "call_id"
|
|
310
|
+
* })
|
|
311
|
+
*/
|
|
312
|
+
endCall(request, requestOptions) {
|
|
313
|
+
return core.HttpResponsePromise.fromPromise(this.__endCall(request, requestOptions));
|
|
314
|
+
}
|
|
315
|
+
__endCall(request, requestOptions) {
|
|
316
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
317
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
318
|
+
const { call_id: callId } = request;
|
|
319
|
+
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
320
|
+
const _headers = (0, headers_js_1.mergeHeaders)(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
321
|
+
const _response = yield core.fetcher({
|
|
322
|
+
url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.AgentPhoneEnvironment.Production, `v1/calls/${core.url.encodePathParam(callId)}/end`),
|
|
323
|
+
method: "POST",
|
|
324
|
+
headers: _headers,
|
|
325
|
+
queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
|
|
326
|
+
timeoutMs: ((_f = (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.timeoutInSeconds) !== null && _f !== void 0 ? _f : 60) * 1000,
|
|
327
|
+
maxRetries: (_g = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _g !== void 0 ? _g : (_h = this._options) === null || _h === void 0 ? void 0 : _h.maxRetries,
|
|
328
|
+
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
329
|
+
fetchFn: (_j = this._options) === null || _j === void 0 ? void 0 : _j.fetch,
|
|
330
|
+
logging: this._options.logging,
|
|
331
|
+
});
|
|
332
|
+
if (_response.ok) {
|
|
333
|
+
return { data: _response.body, rawResponse: _response.rawResponse };
|
|
334
|
+
}
|
|
335
|
+
if (_response.error.reason === "status-code") {
|
|
336
|
+
switch (_response.error.statusCode) {
|
|
337
|
+
case 422:
|
|
338
|
+
throw new AgentPhone.UnprocessableEntityError(_response.error.body, _response.rawResponse);
|
|
339
|
+
default:
|
|
340
|
+
throw new errors.AgentPhoneError({
|
|
341
|
+
statusCode: _response.error.statusCode,
|
|
342
|
+
body: _response.error.body,
|
|
343
|
+
rawResponse: _response.rawResponse,
|
|
344
|
+
});
|
|
345
|
+
}
|
|
346
|
+
}
|
|
347
|
+
return (0, handleNonStatusCodeError_js_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "POST", "/v1/calls/{call_id}/end");
|
|
348
|
+
});
|
|
349
|
+
}
|
|
294
350
|
/**
|
|
295
351
|
* Returns the audio file (WAV format) for a completed call.
|
|
296
352
|
*
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
export type { CreateOutboundCallRequest } from "./CreateOutboundCallRequest.js";
|
|
2
2
|
export type { CreateWebCallRequest } from "./CreateWebCallRequest.js";
|
|
3
|
+
export type { EndCallV1CallsCallIdEndPostRequest } from "./EndCallV1CallsCallIdEndPostRequest.js";
|
|
3
4
|
export type { GetCallRecordingV1CallsCallIdRecordingGetRequest } from "./GetCallRecordingV1CallsCallIdRecordingGetRequest.js";
|
|
4
5
|
export type { GetCallTranscriptV1CallsCallIdTranscriptGetRequest } from "./GetCallTranscriptV1CallsCallIdTranscriptGetRequest.js";
|
|
5
6
|
export type { GetCallV1CallsCallIdGetRequest } from "./GetCallV1CallsCallIdGetRequest.js";
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
import type { BaseClientOptions, BaseRequestOptions } from "../../../../BaseClient.js";
|
|
2
|
+
import { type NormalizedClientOptionsWithAuth } from "../../../../BaseClient.js";
|
|
3
|
+
import * as core from "../../../../core/index.js";
|
|
4
|
+
import * as AgentPhone from "../../../index.js";
|
|
5
|
+
export declare namespace ContactCardsClient {
|
|
6
|
+
type Options = BaseClientOptions;
|
|
7
|
+
interface RequestOptions extends BaseRequestOptions {
|
|
8
|
+
}
|
|
9
|
+
}
|
|
10
|
+
export declare class ContactCardsClient {
|
|
11
|
+
protected readonly _options: NormalizedClientOptionsWithAuth<ContactCardsClient.Options>;
|
|
12
|
+
constructor(options?: ContactCardsClient.Options);
|
|
13
|
+
/**
|
|
14
|
+
* Fetch the iMessage contact card set on this number.
|
|
15
|
+
*
|
|
16
|
+
* @param {AgentPhone.GetContactCardV1NumbersNumberIdContactCardGetRequest} request
|
|
17
|
+
* @param {ContactCardsClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
18
|
+
*
|
|
19
|
+
* @throws {@link AgentPhone.UnprocessableEntityError}
|
|
20
|
+
*
|
|
21
|
+
* @example
|
|
22
|
+
* await client.contactCards.getContactCard({
|
|
23
|
+
* number_id: "number_id"
|
|
24
|
+
* })
|
|
25
|
+
*/
|
|
26
|
+
getContactCard(request: AgentPhone.GetContactCardV1NumbersNumberIdContactCardGetRequest, requestOptions?: ContactCardsClient.RequestOptions): core.HttpResponsePromise<AgentPhone.ContactCardResponse>;
|
|
27
|
+
private __getContactCard;
|
|
28
|
+
/**
|
|
29
|
+
* Create or replace the iMessage contact card on this number.
|
|
30
|
+
*
|
|
31
|
+
* @param {AgentPhone.ContactCardWriteRequest} request
|
|
32
|
+
* @param {ContactCardsClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
33
|
+
*
|
|
34
|
+
* @throws {@link AgentPhone.UnprocessableEntityError}
|
|
35
|
+
*
|
|
36
|
+
* @example
|
|
37
|
+
* await client.contactCards.putContactCard({
|
|
38
|
+
* number_id: "number_id",
|
|
39
|
+
* firstName: "firstName",
|
|
40
|
+
* lastName: "lastName",
|
|
41
|
+
* avatarUrl: "avatarUrl"
|
|
42
|
+
* })
|
|
43
|
+
*/
|
|
44
|
+
putContactCard(request: AgentPhone.ContactCardWriteRequest, requestOptions?: ContactCardsClient.RequestOptions): core.HttpResponsePromise<AgentPhone.ContactCardResponse>;
|
|
45
|
+
private __putContactCard;
|
|
46
|
+
/**
|
|
47
|
+
* Remove the iMessage contact card from this number.
|
|
48
|
+
*
|
|
49
|
+
* @param {AgentPhone.DeleteContactCardV1NumbersNumberIdContactCardDeleteRequest} request
|
|
50
|
+
* @param {ContactCardsClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
51
|
+
*
|
|
52
|
+
* @throws {@link AgentPhone.UnprocessableEntityError}
|
|
53
|
+
*
|
|
54
|
+
* @example
|
|
55
|
+
* await client.contactCards.deleteContactCard({
|
|
56
|
+
* number_id: "number_id"
|
|
57
|
+
* })
|
|
58
|
+
*/
|
|
59
|
+
deleteContactCard(request: AgentPhone.DeleteContactCardV1NumbersNumberIdContactCardDeleteRequest, requestOptions?: ContactCardsClient.RequestOptions): core.HttpResponsePromise<void>;
|
|
60
|
+
private __deleteContactCard;
|
|
61
|
+
}
|
|
@@ -0,0 +1,229 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// This file was auto-generated by Fern from our API Definition.
|
|
3
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
4
|
+
if (k2 === undefined) k2 = k;
|
|
5
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
6
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
7
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
8
|
+
}
|
|
9
|
+
Object.defineProperty(o, k2, desc);
|
|
10
|
+
}) : (function(o, m, k, k2) {
|
|
11
|
+
if (k2 === undefined) k2 = k;
|
|
12
|
+
o[k2] = m[k];
|
|
13
|
+
}));
|
|
14
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
15
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
16
|
+
}) : function(o, v) {
|
|
17
|
+
o["default"] = v;
|
|
18
|
+
});
|
|
19
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
20
|
+
var ownKeys = function(o) {
|
|
21
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
22
|
+
var ar = [];
|
|
23
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
24
|
+
return ar;
|
|
25
|
+
};
|
|
26
|
+
return ownKeys(o);
|
|
27
|
+
};
|
|
28
|
+
return function (mod) {
|
|
29
|
+
if (mod && mod.__esModule) return mod;
|
|
30
|
+
var result = {};
|
|
31
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
32
|
+
__setModuleDefault(result, mod);
|
|
33
|
+
return result;
|
|
34
|
+
};
|
|
35
|
+
})();
|
|
36
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
37
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
38
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
39
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
40
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
41
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
42
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
43
|
+
});
|
|
44
|
+
};
|
|
45
|
+
var __rest = (this && this.__rest) || function (s, e) {
|
|
46
|
+
var t = {};
|
|
47
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
|
48
|
+
t[p] = s[p];
|
|
49
|
+
if (s != null && typeof Object.getOwnPropertySymbols === "function")
|
|
50
|
+
for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
|
51
|
+
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
|
|
52
|
+
t[p[i]] = s[p[i]];
|
|
53
|
+
}
|
|
54
|
+
return t;
|
|
55
|
+
};
|
|
56
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
57
|
+
exports.ContactCardsClient = void 0;
|
|
58
|
+
const BaseClient_js_1 = require("../../../../BaseClient.js");
|
|
59
|
+
const headers_js_1 = require("../../../../core/headers.js");
|
|
60
|
+
const core = __importStar(require("../../../../core/index.js"));
|
|
61
|
+
const environments = __importStar(require("../../../../environments.js"));
|
|
62
|
+
const handleNonStatusCodeError_js_1 = require("../../../../errors/handleNonStatusCodeError.js");
|
|
63
|
+
const errors = __importStar(require("../../../../errors/index.js"));
|
|
64
|
+
const AgentPhone = __importStar(require("../../../index.js"));
|
|
65
|
+
class ContactCardsClient {
|
|
66
|
+
constructor(options = {}) {
|
|
67
|
+
this._options = (0, BaseClient_js_1.normalizeClientOptionsWithAuth)(options);
|
|
68
|
+
}
|
|
69
|
+
/**
|
|
70
|
+
* Fetch the iMessage contact card set on this number.
|
|
71
|
+
*
|
|
72
|
+
* @param {AgentPhone.GetContactCardV1NumbersNumberIdContactCardGetRequest} request
|
|
73
|
+
* @param {ContactCardsClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
74
|
+
*
|
|
75
|
+
* @throws {@link AgentPhone.UnprocessableEntityError}
|
|
76
|
+
*
|
|
77
|
+
* @example
|
|
78
|
+
* await client.contactCards.getContactCard({
|
|
79
|
+
* number_id: "number_id"
|
|
80
|
+
* })
|
|
81
|
+
*/
|
|
82
|
+
getContactCard(request, requestOptions) {
|
|
83
|
+
return core.HttpResponsePromise.fromPromise(this.__getContactCard(request, requestOptions));
|
|
84
|
+
}
|
|
85
|
+
__getContactCard(request, requestOptions) {
|
|
86
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
87
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
88
|
+
const { number_id: numberId } = request;
|
|
89
|
+
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
90
|
+
const _headers = (0, headers_js_1.mergeHeaders)(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
91
|
+
const _response = yield core.fetcher({
|
|
92
|
+
url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.AgentPhoneEnvironment.Production, `v1/numbers/${core.url.encodePathParam(numberId)}/contact-card`),
|
|
93
|
+
method: "GET",
|
|
94
|
+
headers: _headers,
|
|
95
|
+
queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
|
|
96
|
+
timeoutMs: ((_f = (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.timeoutInSeconds) !== null && _f !== void 0 ? _f : 60) * 1000,
|
|
97
|
+
maxRetries: (_g = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _g !== void 0 ? _g : (_h = this._options) === null || _h === void 0 ? void 0 : _h.maxRetries,
|
|
98
|
+
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
99
|
+
fetchFn: (_j = this._options) === null || _j === void 0 ? void 0 : _j.fetch,
|
|
100
|
+
logging: this._options.logging,
|
|
101
|
+
});
|
|
102
|
+
if (_response.ok) {
|
|
103
|
+
return { data: _response.body, rawResponse: _response.rawResponse };
|
|
104
|
+
}
|
|
105
|
+
if (_response.error.reason === "status-code") {
|
|
106
|
+
switch (_response.error.statusCode) {
|
|
107
|
+
case 422:
|
|
108
|
+
throw new AgentPhone.UnprocessableEntityError(_response.error.body, _response.rawResponse);
|
|
109
|
+
default:
|
|
110
|
+
throw new errors.AgentPhoneError({
|
|
111
|
+
statusCode: _response.error.statusCode,
|
|
112
|
+
body: _response.error.body,
|
|
113
|
+
rawResponse: _response.rawResponse,
|
|
114
|
+
});
|
|
115
|
+
}
|
|
116
|
+
}
|
|
117
|
+
return (0, handleNonStatusCodeError_js_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "GET", "/v1/numbers/{number_id}/contact-card");
|
|
118
|
+
});
|
|
119
|
+
}
|
|
120
|
+
/**
|
|
121
|
+
* Create or replace the iMessage contact card on this number.
|
|
122
|
+
*
|
|
123
|
+
* @param {AgentPhone.ContactCardWriteRequest} request
|
|
124
|
+
* @param {ContactCardsClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
125
|
+
*
|
|
126
|
+
* @throws {@link AgentPhone.UnprocessableEntityError}
|
|
127
|
+
*
|
|
128
|
+
* @example
|
|
129
|
+
* await client.contactCards.putContactCard({
|
|
130
|
+
* number_id: "number_id",
|
|
131
|
+
* firstName: "firstName",
|
|
132
|
+
* lastName: "lastName",
|
|
133
|
+
* avatarUrl: "avatarUrl"
|
|
134
|
+
* })
|
|
135
|
+
*/
|
|
136
|
+
putContactCard(request, requestOptions) {
|
|
137
|
+
return core.HttpResponsePromise.fromPromise(this.__putContactCard(request, requestOptions));
|
|
138
|
+
}
|
|
139
|
+
__putContactCard(request, requestOptions) {
|
|
140
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
141
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
142
|
+
const { number_id: numberId } = request, _body = __rest(request, ["number_id"]);
|
|
143
|
+
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
144
|
+
const _headers = (0, headers_js_1.mergeHeaders)(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
145
|
+
const _response = yield core.fetcher({
|
|
146
|
+
url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.AgentPhoneEnvironment.Production, `v1/numbers/${core.url.encodePathParam(numberId)}/contact-card`),
|
|
147
|
+
method: "PUT",
|
|
148
|
+
headers: _headers,
|
|
149
|
+
contentType: "application/json",
|
|
150
|
+
queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
|
|
151
|
+
requestType: "json",
|
|
152
|
+
body: _body,
|
|
153
|
+
timeoutMs: ((_f = (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.timeoutInSeconds) !== null && _f !== void 0 ? _f : 60) * 1000,
|
|
154
|
+
maxRetries: (_g = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _g !== void 0 ? _g : (_h = this._options) === null || _h === void 0 ? void 0 : _h.maxRetries,
|
|
155
|
+
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
156
|
+
fetchFn: (_j = this._options) === null || _j === void 0 ? void 0 : _j.fetch,
|
|
157
|
+
logging: this._options.logging,
|
|
158
|
+
});
|
|
159
|
+
if (_response.ok) {
|
|
160
|
+
return { data: _response.body, rawResponse: _response.rawResponse };
|
|
161
|
+
}
|
|
162
|
+
if (_response.error.reason === "status-code") {
|
|
163
|
+
switch (_response.error.statusCode) {
|
|
164
|
+
case 422:
|
|
165
|
+
throw new AgentPhone.UnprocessableEntityError(_response.error.body, _response.rawResponse);
|
|
166
|
+
default:
|
|
167
|
+
throw new errors.AgentPhoneError({
|
|
168
|
+
statusCode: _response.error.statusCode,
|
|
169
|
+
body: _response.error.body,
|
|
170
|
+
rawResponse: _response.rawResponse,
|
|
171
|
+
});
|
|
172
|
+
}
|
|
173
|
+
}
|
|
174
|
+
return (0, handleNonStatusCodeError_js_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "PUT", "/v1/numbers/{number_id}/contact-card");
|
|
175
|
+
});
|
|
176
|
+
}
|
|
177
|
+
/**
|
|
178
|
+
* Remove the iMessage contact card from this number.
|
|
179
|
+
*
|
|
180
|
+
* @param {AgentPhone.DeleteContactCardV1NumbersNumberIdContactCardDeleteRequest} request
|
|
181
|
+
* @param {ContactCardsClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
182
|
+
*
|
|
183
|
+
* @throws {@link AgentPhone.UnprocessableEntityError}
|
|
184
|
+
*
|
|
185
|
+
* @example
|
|
186
|
+
* await client.contactCards.deleteContactCard({
|
|
187
|
+
* number_id: "number_id"
|
|
188
|
+
* })
|
|
189
|
+
*/
|
|
190
|
+
deleteContactCard(request, requestOptions) {
|
|
191
|
+
return core.HttpResponsePromise.fromPromise(this.__deleteContactCard(request, requestOptions));
|
|
192
|
+
}
|
|
193
|
+
__deleteContactCard(request, requestOptions) {
|
|
194
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
195
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
196
|
+
const { number_id: numberId } = request;
|
|
197
|
+
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
198
|
+
const _headers = (0, headers_js_1.mergeHeaders)(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
199
|
+
const _response = yield core.fetcher({
|
|
200
|
+
url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.AgentPhoneEnvironment.Production, `v1/numbers/${core.url.encodePathParam(numberId)}/contact-card`),
|
|
201
|
+
method: "DELETE",
|
|
202
|
+
headers: _headers,
|
|
203
|
+
queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
|
|
204
|
+
timeoutMs: ((_f = (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.timeoutInSeconds) !== null && _f !== void 0 ? _f : 60) * 1000,
|
|
205
|
+
maxRetries: (_g = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _g !== void 0 ? _g : (_h = this._options) === null || _h === void 0 ? void 0 : _h.maxRetries,
|
|
206
|
+
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
207
|
+
fetchFn: (_j = this._options) === null || _j === void 0 ? void 0 : _j.fetch,
|
|
208
|
+
logging: this._options.logging,
|
|
209
|
+
});
|
|
210
|
+
if (_response.ok) {
|
|
211
|
+
return { data: undefined, rawResponse: _response.rawResponse };
|
|
212
|
+
}
|
|
213
|
+
if (_response.error.reason === "status-code") {
|
|
214
|
+
switch (_response.error.statusCode) {
|
|
215
|
+
case 422:
|
|
216
|
+
throw new AgentPhone.UnprocessableEntityError(_response.error.body, _response.rawResponse);
|
|
217
|
+
default:
|
|
218
|
+
throw new errors.AgentPhoneError({
|
|
219
|
+
statusCode: _response.error.statusCode,
|
|
220
|
+
body: _response.error.body,
|
|
221
|
+
rawResponse: _response.rawResponse,
|
|
222
|
+
});
|
|
223
|
+
}
|
|
224
|
+
}
|
|
225
|
+
return (0, handleNonStatusCodeError_js_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "DELETE", "/v1/numbers/{number_id}/contact-card");
|
|
226
|
+
});
|
|
227
|
+
}
|
|
228
|
+
}
|
|
229
|
+
exports.ContactCardsClient = ContactCardsClient;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./requests/index.js";
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./requests/index.js"), exports);
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @example
|
|
3
|
+
* {
|
|
4
|
+
* number_id: "number_id",
|
|
5
|
+
* firstName: "firstName",
|
|
6
|
+
* lastName: "lastName",
|
|
7
|
+
* avatarUrl: "avatarUrl"
|
|
8
|
+
* }
|
|
9
|
+
*/
|
|
10
|
+
export interface ContactCardWriteRequest {
|
|
11
|
+
number_id: string;
|
|
12
|
+
firstName: string;
|
|
13
|
+
lastName: string;
|
|
14
|
+
displayName?: string | null;
|
|
15
|
+
avatarUrl: string;
|
|
16
|
+
}
|