Skip to content

Commit 56059a2

Browse files
committed
Release 0.7.0
1 parent 08c527e commit 56059a2

File tree

153 files changed

+1914
-1011
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

153 files changed

+1914
-1011
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@vapi-ai/server-sdk",
3-
"version": "0.6.6",
3+
"version": "0.7.0",
44
"private": false,
55
"repository": "https://github.com/VapiAI/server-sdk-typescript",
66
"main": "./index.js",

src/api/resources/analytics/client/Client.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -59,8 +59,8 @@ export class Analytics {
5959
Authorization: await this._getAuthorizationHeader(),
6060
"X-Fern-Language": "JavaScript",
6161
"X-Fern-SDK-Name": "@vapi-ai/server-sdk",
62-
"X-Fern-SDK-Version": "0.6.6",
63-
"User-Agent": "@vapi-ai/server-sdk/0.6.6",
62+
"X-Fern-SDK-Version": "0.7.0",
63+
"User-Agent": "@vapi-ai/server-sdk/0.7.0",
6464
"X-Fern-Runtime": core.RUNTIME.type,
6565
"X-Fern-Runtime-Version": core.RUNTIME.version,
6666
...requestOptions?.headers,

src/api/resources/assistants/client/Client.ts

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -107,8 +107,8 @@ export class Assistants {
107107
Authorization: await this._getAuthorizationHeader(),
108108
"X-Fern-Language": "JavaScript",
109109
"X-Fern-SDK-Name": "@vapi-ai/server-sdk",
110-
"X-Fern-SDK-Version": "0.6.6",
111-
"User-Agent": "@vapi-ai/server-sdk/0.6.6",
110+
"X-Fern-SDK-Version": "0.7.0",
111+
"User-Agent": "@vapi-ai/server-sdk/0.7.0",
112112
"X-Fern-Runtime": core.RUNTIME.type,
113113
"X-Fern-Runtime-Version": core.RUNTIME.version,
114114
...requestOptions?.headers,
@@ -176,8 +176,8 @@ export class Assistants {
176176
Authorization: await this._getAuthorizationHeader(),
177177
"X-Fern-Language": "JavaScript",
178178
"X-Fern-SDK-Name": "@vapi-ai/server-sdk",
179-
"X-Fern-SDK-Version": "0.6.6",
180-
"User-Agent": "@vapi-ai/server-sdk/0.6.6",
179+
"X-Fern-SDK-Version": "0.7.0",
180+
"User-Agent": "@vapi-ai/server-sdk/0.7.0",
181181
"X-Fern-Runtime": core.RUNTIME.type,
182182
"X-Fern-Runtime-Version": core.RUNTIME.version,
183183
...requestOptions?.headers,
@@ -242,8 +242,8 @@ export class Assistants {
242242
Authorization: await this._getAuthorizationHeader(),
243243
"X-Fern-Language": "JavaScript",
244244
"X-Fern-SDK-Name": "@vapi-ai/server-sdk",
245-
"X-Fern-SDK-Version": "0.6.6",
246-
"User-Agent": "@vapi-ai/server-sdk/0.6.6",
245+
"X-Fern-SDK-Version": "0.7.0",
246+
"User-Agent": "@vapi-ai/server-sdk/0.7.0",
247247
"X-Fern-Runtime": core.RUNTIME.type,
248248
"X-Fern-Runtime-Version": core.RUNTIME.version,
249249
...requestOptions?.headers,
@@ -307,8 +307,8 @@ export class Assistants {
307307
Authorization: await this._getAuthorizationHeader(),
308308
"X-Fern-Language": "JavaScript",
309309
"X-Fern-SDK-Name": "@vapi-ai/server-sdk",
310-
"X-Fern-SDK-Version": "0.6.6",
311-
"User-Agent": "@vapi-ai/server-sdk/0.6.6",
310+
"X-Fern-SDK-Version": "0.7.0",
311+
"User-Agent": "@vapi-ai/server-sdk/0.7.0",
312312
"X-Fern-Runtime": core.RUNTIME.type,
313313
"X-Fern-Runtime-Version": core.RUNTIME.version,
314314
...requestOptions?.headers,
@@ -355,15 +355,15 @@ export class Assistants {
355355
*/
356356
public update(
357357
id: string,
358-
request: Vapi.UpdateAssistantDto,
358+
request: Vapi.UpdateAssistantDto = {},
359359
requestOptions?: Assistants.RequestOptions,
360360
): core.HttpResponsePromise<Vapi.Assistant> {
361361
return core.HttpResponsePromise.fromPromise(this.__update(id, request, requestOptions));
362362
}
363363

364364
private async __update(
365365
id: string,
366-
request: Vapi.UpdateAssistantDto,
366+
request: Vapi.UpdateAssistantDto = {},
367367
requestOptions?: Assistants.RequestOptions,
368368
): Promise<core.WithRawResponse<Vapi.Assistant>> {
369369
const _response = await (this._options.fetcher ?? core.fetcher)({
@@ -378,8 +378,8 @@ export class Assistants {
378378
Authorization: await this._getAuthorizationHeader(),
379379
"X-Fern-Language": "JavaScript",
380380
"X-Fern-SDK-Name": "@vapi-ai/server-sdk",
381-
"X-Fern-SDK-Version": "0.6.6",
382-
"User-Agent": "@vapi-ai/server-sdk/0.6.6",
381+
"X-Fern-SDK-Version": "0.7.0",
382+
"User-Agent": "@vapi-ai/server-sdk/0.7.0",
383383
"X-Fern-Runtime": core.RUNTIME.type,
384384
"X-Fern-Runtime-Version": core.RUNTIME.version,
385385
...requestOptions?.headers,

src/api/resources/assistants/client/requests/UpdateAssistantDto.ts

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,8 @@ export interface UpdateAssistantDto {
3737
voicemailDetection?: Vapi.UpdateAssistantDtoVoicemailDetection;
3838
/** These are the messages that will be sent to your Client SDKs. Default is conversation-update,function-call,hang,model-output,speech-update,status-update,transfer-update,transcript,tool-calls,user-interrupted,voice-input,workflow.node.started. You can check the shape of the messages in ClientMessage schema. */
3939
clientMessages?: Vapi.UpdateAssistantDtoClientMessagesItem[];
40-
serverMessages: Record<string, unknown>[][];
40+
/** These are the messages that will be sent to your Server URL. Default is conversation-update,end-of-call-report,function-call,hang,speech-update,status-update,tool-calls,transfer-destination-request,user-interrupted. You can check the shape of the messages in ServerMessage schema. */
41+
serverMessages?: Vapi.UpdateAssistantDtoServerMessagesItem[];
4142
/**
4243
* How many seconds of silence to wait before ending the call. Defaults to 30.
4344
*
@@ -81,7 +82,7 @@ export interface UpdateAssistantDto {
8182
/** These are dynamic credentials that will be used for the assistant calls. By default, all the credentials are available for use in the call but you can supplement an additional credentials using this. Dynamic credentials override existing credentials. */
8283
credentials?: Vapi.UpdateAssistantDtoCredentialsItem[];
8384
/** This is a set of actions that will be performed on certain events. */
84-
hooks?: Vapi.AssistantHookCallEnding[];
85+
hooks?: Vapi.UpdateAssistantDtoHooksItem[];
8586
/**
8687
* This is the name of the assistant.
8788
*

src/api/resources/assistants/types/UpdateAssistantDtoCredentialsItem.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,4 +51,5 @@ export type UpdateAssistantDtoCredentialsItem =
5151
| Vapi.CreateGoogleCalendarOAuth2ClientCredentialDto
5252
| Vapi.CreateGoogleCalendarOAuth2AuthorizationCredentialDto
5353
| Vapi.CreateGoogleSheetsOAuth2AuthorizationCredentialDto
54-
| Vapi.CreateSlackOAuth2AuthorizationCredentialDto;
54+
| Vapi.CreateSlackOAuth2AuthorizationCredentialDto
55+
| Vapi.CreateGoHighLevelMcpCredentialDto;
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
/**
2+
* This file was auto-generated by Fern from our API Definition.
3+
*/
4+
5+
import * as Vapi from "../../../index";
6+
7+
export type UpdateAssistantDtoHooksItem =
8+
| Vapi.AssistantHookCallEnding
9+
| Vapi.AssistantHookAssistantSpeechInterrupted
10+
| Vapi.AssistantHookCustomerSpeechInterrupted;
Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
/**
2+
* This file was auto-generated by Fern from our API Definition.
3+
*/
4+
5+
export type UpdateAssistantDtoServerMessagesItem =
6+
| "conversation-update"
7+
| "end-of-call-report"
8+
| "function-call"
9+
| "hang"
10+
| "language-changed"
11+
| "language-change-detected"
12+
| "model-output"
13+
| "phone-call-control"
14+
| "speech-update"
15+
| "status-update"
16+
| "transcript"
17+
| 'transcript[transcriptType="final"]'
18+
| "tool-calls"
19+
| "transfer-destination-request"
20+
| "transfer-update"
21+
| "user-interrupted"
22+
| "voice-input";
23+
export const UpdateAssistantDtoServerMessagesItem = {
24+
ConversationUpdate: "conversation-update",
25+
EndOfCallReport: "end-of-call-report",
26+
FunctionCall: "function-call",
27+
Hang: "hang",
28+
LanguageChanged: "language-changed",
29+
LanguageChangeDetected: "language-change-detected",
30+
ModelOutput: "model-output",
31+
PhoneCallControl: "phone-call-control",
32+
SpeechUpdate: "speech-update",
33+
StatusUpdate: "status-update",
34+
Transcript: "transcript",
35+
TranscriptTranscriptTypeFinal: 'transcript[transcriptType="final"]',
36+
ToolCalls: "tool-calls",
37+
TransferDestinationRequest: "transfer-destination-request",
38+
TransferUpdate: "transfer-update",
39+
UserInterrupted: "user-interrupted",
40+
VoiceInput: "voice-input",
41+
} as const;

src/api/resources/assistants/types/index.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,8 @@ export * from "./UpdateAssistantDtoVoice";
44
export * from "./UpdateAssistantDtoFirstMessageMode";
55
export * from "./UpdateAssistantDtoVoicemailDetection";
66
export * from "./UpdateAssistantDtoClientMessagesItem";
7+
export * from "./UpdateAssistantDtoServerMessagesItem";
78
export * from "./UpdateAssistantDtoBackgroundSoundZero";
89
export * from "./UpdateAssistantDtoBackgroundSound";
910
export * from "./UpdateAssistantDtoCredentialsItem";
11+
export * from "./UpdateAssistantDtoHooksItem";

src/api/resources/calls/client/Client.ts

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -122,8 +122,8 @@ export class Calls {
122122
Authorization: await this._getAuthorizationHeader(),
123123
"X-Fern-Language": "JavaScript",
124124
"X-Fern-SDK-Name": "@vapi-ai/server-sdk",
125-
"X-Fern-SDK-Version": "0.6.6",
126-
"User-Agent": "@vapi-ai/server-sdk/0.6.6",
125+
"X-Fern-SDK-Version": "0.7.0",
126+
"User-Agent": "@vapi-ai/server-sdk/0.7.0",
127127
"X-Fern-Runtime": core.RUNTIME.type,
128128
"X-Fern-Runtime-Version": core.RUNTIME.version,
129129
...requestOptions?.headers,
@@ -191,8 +191,8 @@ export class Calls {
191191
Authorization: await this._getAuthorizationHeader(),
192192
"X-Fern-Language": "JavaScript",
193193
"X-Fern-SDK-Name": "@vapi-ai/server-sdk",
194-
"X-Fern-SDK-Version": "0.6.6",
195-
"User-Agent": "@vapi-ai/server-sdk/0.6.6",
194+
"X-Fern-SDK-Version": "0.7.0",
195+
"User-Agent": "@vapi-ai/server-sdk/0.7.0",
196196
"X-Fern-Runtime": core.RUNTIME.type,
197197
"X-Fern-Runtime-Version": core.RUNTIME.version,
198198
...requestOptions?.headers,
@@ -254,8 +254,8 @@ export class Calls {
254254
Authorization: await this._getAuthorizationHeader(),
255255
"X-Fern-Language": "JavaScript",
256256
"X-Fern-SDK-Name": "@vapi-ai/server-sdk",
257-
"X-Fern-SDK-Version": "0.6.6",
258-
"User-Agent": "@vapi-ai/server-sdk/0.6.6",
257+
"X-Fern-SDK-Version": "0.7.0",
258+
"User-Agent": "@vapi-ai/server-sdk/0.7.0",
259259
"X-Fern-Runtime": core.RUNTIME.type,
260260
"X-Fern-Runtime-Version": core.RUNTIME.version,
261261
...requestOptions?.headers,
@@ -319,8 +319,8 @@ export class Calls {
319319
Authorization: await this._getAuthorizationHeader(),
320320
"X-Fern-Language": "JavaScript",
321321
"X-Fern-SDK-Name": "@vapi-ai/server-sdk",
322-
"X-Fern-SDK-Version": "0.6.6",
323-
"User-Agent": "@vapi-ai/server-sdk/0.6.6",
322+
"X-Fern-SDK-Version": "0.7.0",
323+
"User-Agent": "@vapi-ai/server-sdk/0.7.0",
324324
"X-Fern-Runtime": core.RUNTIME.type,
325325
"X-Fern-Runtime-Version": core.RUNTIME.version,
326326
...requestOptions?.headers,
@@ -390,8 +390,8 @@ export class Calls {
390390
Authorization: await this._getAuthorizationHeader(),
391391
"X-Fern-Language": "JavaScript",
392392
"X-Fern-SDK-Name": "@vapi-ai/server-sdk",
393-
"X-Fern-SDK-Version": "0.6.6",
394-
"User-Agent": "@vapi-ai/server-sdk/0.6.6",
393+
"X-Fern-SDK-Version": "0.7.0",
394+
"User-Agent": "@vapi-ai/server-sdk/0.7.0",
395395
"X-Fern-Runtime": core.RUNTIME.type,
396396
"X-Fern-Runtime-Version": core.RUNTIME.version,
397397
...requestOptions?.headers,

src/api/resources/calls/client/requests/CreateCallDto.ts

Lines changed: 44 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -17,16 +17,56 @@ export interface CreateCallDto {
1717
schedulePlan?: Vapi.SchedulePlan;
1818
/** This is the transport of the call. */
1919
transport?: Record<string, unknown>;
20-
/** This is the assistant that will be used for the call. To use a transient assistant, use `assistant` instead. */
20+
/**
21+
* This is the assistant that will be used for the call. To use a transient assistant, use `assistant` instead.
22+
* Usage:
23+
* To start the call with Assistant as entrypoint, use assistant or assistantId
24+
* To start the call with Squad as entrypoint, use squad or squadId
25+
* To start the call with Workflow as entrypoint, use workflow or workflowId
26+
*/
2127
assistantId?: string;
22-
/** This is the assistant that will be used for the call. To use an existing assistant, use `assistantId` instead. */
28+
/**
29+
* This is the assistant that will be used for the call. To use an existing assistant, use `assistantId` instead.
30+
* Usage:
31+
* To start the call with Assistant as entrypoint, use assistant or assistantId
32+
* To start the call with Squad as entrypoint, use squad or squadId
33+
* To start the call with Workflow as entrypoint, use workflow or workflowId
34+
*/
2335
assistant?: Vapi.CreateAssistantDto;
2436
/** These are the overrides for the `assistant` or `assistantId`'s settings and template variables. */
2537
assistantOverrides?: Vapi.AssistantOverrides;
26-
/** This is the squad that will be used for the call. To use a transient squad, use `squad` instead. */
38+
/**
39+
* This is the squad that will be used for the call. To use a transient squad, use `squad` instead.
40+
* Usage:
41+
* To start the call with Assistant as entrypoint, use assistant or assistantId
42+
* To start the call with Squad as entrypoint, use squad or squadId
43+
* To start the call with Workflow as entrypoint, use workflow or workflowId
44+
*/
2745
squadId?: string;
28-
/** This is a squad that will be used for the call. To use an existing squad, use `squadId` instead. */
46+
/**
47+
* This is a squad that will be used for the call. To use an existing squad, use `squadId` instead.
48+
* Usage:
49+
* To start the call with Assistant as entrypoint, use assistant or assistantId
50+
* To start the call with Squad as entrypoint, use squad or squadId
51+
* To start the call with Workflow as entrypoint, use workflow or workflowId
52+
*/
2953
squad?: Vapi.CreateSquadDto;
54+
/**
55+
* This is the workflow that will be used for the call. To use a transient workflow, use `workflow` instead.
56+
* Usage:
57+
* To start the call with Assistant as entrypoint, use assistant or assistantId
58+
* To start the call with Squad as entrypoint, use squad or squadId
59+
* To start the call with Workflow as entrypoint, use workflow or workflowId
60+
*/
61+
workflowId?: string;
62+
/**
63+
* This is a workflow that will be used for the call. To use an existing workflow, use `workflowId` instead.
64+
* Usage:
65+
* To start the call with Assistant as entrypoint, use assistant or assistantId
66+
* To start the call with Squad as entrypoint, use squad or squadId
67+
* To start the call with Workflow as entrypoint, use workflow or workflowId
68+
*/
69+
workflow?: Vapi.CreateWorkflowDto;
3070
/**
3171
* This is the phone number that will be used for the call. To use a transient number, use `phoneNumber` instead.
3272
*

src/api/resources/files/client/Client.ts

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -54,8 +54,8 @@ export class Files {
5454
Authorization: await this._getAuthorizationHeader(),
5555
"X-Fern-Language": "JavaScript",
5656
"X-Fern-SDK-Name": "@vapi-ai/server-sdk",
57-
"X-Fern-SDK-Version": "0.6.6",
58-
"User-Agent": "@vapi-ai/server-sdk/0.6.6",
57+
"X-Fern-SDK-Version": "0.7.0",
58+
"User-Agent": "@vapi-ai/server-sdk/0.7.0",
5959
"X-Fern-Runtime": core.RUNTIME.type,
6060
"X-Fern-Runtime-Version": core.RUNTIME.version,
6161
...requestOptions?.headers,
@@ -127,8 +127,8 @@ export class Files {
127127
Authorization: await this._getAuthorizationHeader(),
128128
"X-Fern-Language": "JavaScript",
129129
"X-Fern-SDK-Name": "@vapi-ai/server-sdk",
130-
"X-Fern-SDK-Version": "0.6.6",
131-
"User-Agent": "@vapi-ai/server-sdk/0.6.6",
130+
"X-Fern-SDK-Version": "0.7.0",
131+
"User-Agent": "@vapi-ai/server-sdk/0.7.0",
132132
"X-Fern-Runtime": core.RUNTIME.type,
133133
"X-Fern-Runtime-Version": core.RUNTIME.version,
134134
..._maybeEncodedRequest.headers,
@@ -196,8 +196,8 @@ export class Files {
196196
Authorization: await this._getAuthorizationHeader(),
197197
"X-Fern-Language": "JavaScript",
198198
"X-Fern-SDK-Name": "@vapi-ai/server-sdk",
199-
"X-Fern-SDK-Version": "0.6.6",
200-
"User-Agent": "@vapi-ai/server-sdk/0.6.6",
199+
"X-Fern-SDK-Version": "0.7.0",
200+
"User-Agent": "@vapi-ai/server-sdk/0.7.0",
201201
"X-Fern-Runtime": core.RUNTIME.type,
202202
"X-Fern-Runtime-Version": core.RUNTIME.version,
203203
...requestOptions?.headers,
@@ -261,8 +261,8 @@ export class Files {
261261
Authorization: await this._getAuthorizationHeader(),
262262
"X-Fern-Language": "JavaScript",
263263
"X-Fern-SDK-Name": "@vapi-ai/server-sdk",
264-
"X-Fern-SDK-Version": "0.6.6",
265-
"User-Agent": "@vapi-ai/server-sdk/0.6.6",
264+
"X-Fern-SDK-Version": "0.7.0",
265+
"User-Agent": "@vapi-ai/server-sdk/0.7.0",
266266
"X-Fern-Runtime": core.RUNTIME.type,
267267
"X-Fern-Runtime-Version": core.RUNTIME.version,
268268
...requestOptions?.headers,
@@ -332,8 +332,8 @@ export class Files {
332332
Authorization: await this._getAuthorizationHeader(),
333333
"X-Fern-Language": "JavaScript",
334334
"X-Fern-SDK-Name": "@vapi-ai/server-sdk",
335-
"X-Fern-SDK-Version": "0.6.6",
336-
"User-Agent": "@vapi-ai/server-sdk/0.6.6",
335+
"X-Fern-SDK-Version": "0.7.0",
336+
"User-Agent": "@vapi-ai/server-sdk/0.7.0",
337337
"X-Fern-Runtime": core.RUNTIME.type,
338338
"X-Fern-Runtime-Version": core.RUNTIME.version,
339339
...requestOptions?.headers,

0 commit comments

Comments
 (0)