Skip to content

Commit 92c768d

Browse files
Merge pull request #18 from VapiAI/fern-bot/05-28-2025-1215AM
🌿 Fern Regeneration -- May 28, 2025
2 parents e885438 + 58a9181 commit 92c768d

File tree

119 files changed

+772
-745
lines changed

Some content is hidden

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

119 files changed

+772
-745
lines changed

src/api/types/AssistantMessage.ts

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
/**
2+
* This file was auto-generated by Fern from our API Definition.
3+
*/
4+
5+
import * as Vapi from "../index";
6+
7+
export interface AssistantMessage {
8+
/** This is the role of the message author */
9+
role: "assistant";
10+
/** This is the content of the assistant message */
11+
content?: string;
12+
/** This is the refusal message generated by the model */
13+
refusal?: string;
14+
/** This is the tool calls generated by the model */
15+
tool_calls?: Vapi.ToolCall[];
16+
/** This is an optional name for the participant */
17+
name?: string;
18+
}

src/api/types/BashTool.ts

Lines changed: 11 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,17 @@ export interface BashTool {
2424
type: "bash";
2525
/** The sub type of tool. */
2626
subType: "bash_20241022";
27+
/**
28+
* This is the server where a `tool-calls` webhook will be sent.
29+
*
30+
* Notes:
31+
* - Webhook is sent to this server when a tool call is made.
32+
* - Webhook contains the call, assistant, and phone number objects.
33+
* - Webhook contains the variables set on the assistant.
34+
* - Webhook is sent to the first available URL in this order: {{tool.server.url}}, {{assistant.server.url}}, {{phoneNumber.server.url}}, {{org.server.url}}.
35+
* - Webhook expects a response with tool call result.
36+
*/
37+
server?: Vapi.Server;
2738
/** This is the unique identifier for the tool. */
2839
id: string;
2940
/** This is the unique identifier for the organization that this tool belongs to. */
@@ -40,14 +51,6 @@ export interface BashTool {
4051
* An example of an advanced use case is if you want to customize the message that's spoken for `endCall` tool. You can specify a function where it returns an argument "reason". Then, in `messages` array, you can have many "request-complete" messages. One of these messages will be triggered if the `messages[].conditions` matches the "reason" argument.
4152
*/
4253
function?: Vapi.OpenAiFunction;
43-
/**
44-
* This is the server that will be hit when this tool is requested by the model.
45-
*
46-
* All requests will be sent with the call object among other things. You can find more details in the Server URL documentation.
47-
*
48-
* This overrides the serverUrl set on the org and the phoneNumber. Order of precedence: highest tool.server.url, then assistant.serverUrl, then phoneNumber.serverUrl, then org.serverUrl.
49-
*/
50-
server?: Vapi.Server;
5154
/** The name of the tool, fixed to 'bash' */
5255
name: "bash";
5356
}

src/api/types/BashToolWithToolCall.ts

Lines changed: 11 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,17 @@ export interface BashToolWithToolCall {
2525
type: "bash";
2626
/** The sub type of tool. */
2727
subType: "bash_20241022";
28+
/**
29+
* This is the server where a `tool-calls` webhook will be sent.
30+
*
31+
* Notes:
32+
* - Webhook is sent to this server when a tool call is made.
33+
* - Webhook contains the call, assistant, and phone number objects.
34+
* - Webhook contains the variables set on the assistant.
35+
* - Webhook is sent to the first available URL in this order: {{tool.server.url}}, {{assistant.server.url}}, {{phoneNumber.server.url}}, {{org.server.url}}.
36+
* - Webhook expects a response with tool call result.
37+
*/
38+
server?: Vapi.Server;
2839
toolCall: Vapi.ToolCall;
2940
/** The name of the tool, fixed to 'bash' */
3041
name: "bash";
@@ -36,12 +47,4 @@ export interface BashToolWithToolCall {
3647
* An example of an advanced use case is if you want to customize the message that's spoken for `endCall` tool. You can specify a function where it returns an argument "reason". Then, in `messages` array, you can have many "request-complete" messages. One of these messages will be triggered if the `messages[].conditions` matches the "reason" argument.
3748
*/
3849
function?: Vapi.OpenAiFunction;
39-
/**
40-
* This is the server that will be hit when this tool is requested by the model.
41-
*
42-
* All requests will be sent with the call object among other things. You can find more details in the Server URL documentation.
43-
*
44-
* This overrides the serverUrl set on the org and the phoneNumber. Order of precedence: highest tool.server.url, then assistant.serverUrl, then phoneNumber.serverUrl, then org.serverUrl.
45-
*/
46-
server?: Vapi.Server;
4750
}

src/api/types/Chat.ts

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
/**
2+
* This file was auto-generated by Fern from our API Definition.
3+
*/
4+
5+
import * as Vapi from "../index";
6+
7+
export interface Chat {
8+
/** This is the assistant that will be used for the chat. To use an existing assistant, use `assistantId` instead. */
9+
assistantId?: string;
10+
/** This is the assistant that will be used for the chat. To use an existing assistant, use `assistantId` instead. */
11+
assistant?: Vapi.CreateAssistantDto;
12+
/** This is the name of the chat. This is just for your own reference. */
13+
name?: string;
14+
/**
15+
* This is the ID of the session that will be used for the chat.
16+
* Mutually exclusive with previousChatId.
17+
*/
18+
sessionId?: string;
19+
/** Chat input as a string or an array of messages. When using message array, each message requires a role and content. */
20+
input?: Vapi.ChatInput;
21+
/**
22+
* This is a flag that determines whether the response should be streamed.
23+
* When true, the response will be sent as chunks of text.
24+
*/
25+
stream?: boolean;
26+
/**
27+
* This is the ID of the chat that will be used as context for the new chat.
28+
* The messages from the previous chat will be used as context.
29+
* Mutually exclusive with sessionId.
30+
*/
31+
previousChatId?: string;
32+
/** This is the unique identifier for the chat. */
33+
id: string;
34+
/** This is the unique identifier for the org that this chat belongs to. */
35+
orgId: string;
36+
/** Array of messages used as context for the chat */
37+
messages?: Vapi.ChatMessagesItem[];
38+
/** Output messages generated by the system in response to the input */
39+
output?: Vapi.ChatOutputItem[];
40+
/** This is the ISO 8601 date-time string of when the chat was created. */
41+
createdAt: string;
42+
/** This is the ISO 8601 date-time string of when the chat was last updated. */
43+
updatedAt: string;
44+
}

src/api/types/ChatCompletionMessageMetadata.ts

Lines changed: 0 additions & 11 deletions
This file was deleted.

src/api/types/ChatCompletionMessageWorkflows.ts

Lines changed: 0 additions & 11 deletions
This file was deleted.

src/api/types/ChatCompletionsDto.ts

Lines changed: 0 additions & 11 deletions
This file was deleted.

src/api/types/ChatInput.ts

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+
/**
8+
* Chat input as a string or an array of messages. When using message array, each message requires a role and content.
9+
*/
10+
export type ChatInput = string | Vapi.ChatInputItem[];

src/api/types/ChatInputItem.ts

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
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 ChatInputItem =
8+
| Vapi.SystemMessage
9+
| Vapi.UserMessage
10+
| Vapi.AssistantMessage
11+
| Vapi.ToolMessage
12+
| Vapi.DeveloperMessage;

src/api/types/ChatMessagesItem.ts

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
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 ChatMessagesItem =
8+
| Vapi.SystemMessage
9+
| Vapi.UserMessage
10+
| Vapi.AssistantMessage
11+
| Vapi.ToolMessage
12+
| Vapi.DeveloperMessage;

src/api/types/ChatOutputItem.ts

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
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 ChatOutputItem =
8+
| Vapi.SystemMessage
9+
| Vapi.UserMessage
10+
| Vapi.AssistantMessage
11+
| Vapi.ToolMessage
12+
| Vapi.DeveloperMessage;
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 interface ChatPaginatedResponse {
8+
results: Vapi.Chat[];
9+
metadata: Vapi.PaginationMeta;
10+
}

src/api/types/ChatServiceResponse.ts

Lines changed: 0 additions & 5 deletions
This file was deleted.

src/api/types/ComputerTool.ts

Lines changed: 11 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,17 @@ export interface ComputerTool {
2424
type: "computer";
2525
/** The sub type of tool. */
2626
subType: "computer_20241022";
27+
/**
28+
* This is the server where a `tool-calls` webhook will be sent.
29+
*
30+
* Notes:
31+
* - Webhook is sent to this server when a tool call is made.
32+
* - Webhook contains the call, assistant, and phone number objects.
33+
* - Webhook contains the variables set on the assistant.
34+
* - Webhook is sent to the first available URL in this order: {{tool.server.url}}, {{assistant.server.url}}, {{phoneNumber.server.url}}, {{org.server.url}}.
35+
* - Webhook expects a response with tool call result.
36+
*/
37+
server?: Vapi.Server;
2738
/** This is the unique identifier for the tool. */
2839
id: string;
2940
/** This is the unique identifier for the organization that this tool belongs to. */
@@ -40,14 +51,6 @@ export interface ComputerTool {
4051
* An example of an advanced use case is if you want to customize the message that's spoken for `endCall` tool. You can specify a function where it returns an argument "reason". Then, in `messages` array, you can have many "request-complete" messages. One of these messages will be triggered if the `messages[].conditions` matches the "reason" argument.
4152
*/
4253
function?: Vapi.OpenAiFunction;
43-
/**
44-
* This is the server that will be hit when this tool is requested by the model.
45-
*
46-
* All requests will be sent with the call object among other things. You can find more details in the Server URL documentation.
47-
*
48-
* This overrides the serverUrl set on the org and the phoneNumber. Order of precedence: highest tool.server.url, then assistant.serverUrl, then phoneNumber.serverUrl, then org.serverUrl.
49-
*/
50-
server?: Vapi.Server;
5154
/** The name of the tool, fixed to 'computer' */
5255
name: "computer";
5356
/** The display width in pixels */

src/api/types/ComputerToolWithToolCall.ts

Lines changed: 11 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,17 @@ export interface ComputerToolWithToolCall {
2525
type: "computer";
2626
/** The sub type of tool. */
2727
subType: "computer_20241022";
28+
/**
29+
* This is the server where a `tool-calls` webhook will be sent.
30+
*
31+
* Notes:
32+
* - Webhook is sent to this server when a tool call is made.
33+
* - Webhook contains the call, assistant, and phone number objects.
34+
* - Webhook contains the variables set on the assistant.
35+
* - Webhook is sent to the first available URL in this order: {{tool.server.url}}, {{assistant.server.url}}, {{phoneNumber.server.url}}, {{org.server.url}}.
36+
* - Webhook expects a response with tool call result.
37+
*/
38+
server?: Vapi.Server;
2839
toolCall: Vapi.ToolCall;
2940
/** The name of the tool, fixed to 'computer' */
3041
name: "computer";
@@ -42,12 +53,4 @@ export interface ComputerToolWithToolCall {
4253
* An example of an advanced use case is if you want to customize the message that's spoken for `endCall` tool. You can specify a function where it returns an argument "reason". Then, in `messages` array, you can have many "request-complete" messages. One of these messages will be triggered if the `messages[].conditions` matches the "reason" argument.
4354
*/
4455
function?: Vapi.OpenAiFunction;
45-
/**
46-
* This is the server that will be hit when this tool is requested by the model.
47-
*
48-
* All requests will be sent with the call object among other things. You can find more details in the Server URL documentation.
49-
*
50-
* This overrides the serverUrl set on the org and the phoneNumber. Order of precedence: highest tool.server.url, then assistant.serverUrl, then phoneNumber.serverUrl, then org.serverUrl.
51-
*/
52-
server?: Vapi.Server;
5356
}

src/api/types/CreateApiRequestToolDto.ts

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ export interface CreateApiRequestToolDto {
3737
/** This is where the request will be sent. */
3838
url: string;
3939
/** This is the body of the request. */
40-
body: Vapi.JsonSchema;
40+
body?: Vapi.JsonSchema;
4141
/** These are the headers to send in the request. */
4242
headers?: Vapi.JsonSchema;
4343
/**
@@ -54,12 +54,4 @@ export interface CreateApiRequestToolDto {
5454
* An example of an advanced use case is if you want to customize the message that's spoken for `endCall` tool. You can specify a function where it returns an argument "reason". Then, in `messages` array, you can have many "request-complete" messages. One of these messages will be triggered if the `messages[].conditions` matches the "reason" argument.
5555
*/
5656
function?: Vapi.OpenAiFunction;
57-
/**
58-
* This is the server that will be hit when this tool is requested by the model.
59-
*
60-
* All requests will be sent with the call object among other things. You can find more details in the Server URL documentation.
61-
*
62-
* This overrides the serverUrl set on the org and the phoneNumber. Order of precedence: highest tool.server.url, then assistant.serverUrl, then phoneNumber.serverUrl, then org.serverUrl.
63-
*/
64-
server?: Vapi.Server;
6557
}

src/api/types/CreateBashToolDto.ts

Lines changed: 11 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,17 @@ export interface CreateBashToolDto {
2424
type: "bash";
2525
/** The sub type of tool. */
2626
subType: "bash_20241022";
27+
/**
28+
* This is the server where a `tool-calls` webhook will be sent.
29+
*
30+
* Notes:
31+
* - Webhook is sent to this server when a tool call is made.
32+
* - Webhook contains the call, assistant, and phone number objects.
33+
* - Webhook contains the variables set on the assistant.
34+
* - Webhook is sent to the first available URL in this order: {{tool.server.url}}, {{assistant.server.url}}, {{phoneNumber.server.url}}, {{org.server.url}}.
35+
* - Webhook expects a response with tool call result.
36+
*/
37+
server?: Vapi.Server;
2738
/** The name of the tool, fixed to 'bash' */
2839
name: "bash";
2940
/**
@@ -34,12 +45,4 @@ export interface CreateBashToolDto {
3445
* An example of an advanced use case is if you want to customize the message that's spoken for `endCall` tool. You can specify a function where it returns an argument "reason". Then, in `messages` array, you can have many "request-complete" messages. One of these messages will be triggered if the `messages[].conditions` matches the "reason" argument.
3546
*/
3647
function?: Vapi.OpenAiFunction;
37-
/**
38-
* This is the server that will be hit when this tool is requested by the model.
39-
*
40-
* All requests will be sent with the call object among other things. You can find more details in the Server URL documentation.
41-
*
42-
* This overrides the serverUrl set on the org and the phoneNumber. Order of precedence: highest tool.server.url, then assistant.serverUrl, then phoneNumber.serverUrl, then org.serverUrl.
43-
*/
44-
server?: Vapi.Server;
4548
}

src/api/types/CreateChatDto.ts

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
/**
2+
* This file was auto-generated by Fern from our API Definition.
3+
*/
4+
5+
import * as Vapi from "../index";
6+
7+
export interface CreateChatDto {
8+
/** This is the assistant that will be used for the chat. To use an existing assistant, use `assistantId` instead. */
9+
assistantId?: string;
10+
/** This is the assistant that will be used for the chat. To use an existing assistant, use `assistantId` instead. */
11+
assistant?: Vapi.CreateAssistantDto;
12+
/** This is the name of the chat. This is just for your own reference. */
13+
name?: string;
14+
/**
15+
* This is the ID of the session that will be used for the chat.
16+
* Mutually exclusive with previousChatId.
17+
*/
18+
sessionId?: string;
19+
/** Chat input as a string or an array of messages. When using message array, each message requires a role and content. */
20+
input: Vapi.CreateChatDtoInput;
21+
/**
22+
* This is a flag that determines whether the response should be streamed.
23+
* When true, the response will be sent as chunks of text.
24+
*/
25+
stream?: boolean;
26+
/**
27+
* This is the ID of the chat that will be used as context for the new chat.
28+
* The messages from the previous chat will be used as context.
29+
* Mutually exclusive with sessionId.
30+
*/
31+
previousChatId?: string;
32+
}

src/api/types/CreateChatDtoInput.ts

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+
/**
8+
* Chat input as a string or an array of messages. When using message array, each message requires a role and content.
9+
*/
10+
export type CreateChatDtoInput = string | Vapi.CreateChatDtoInputItem[];

0 commit comments

Comments
 (0)