diff --git a/.fern/metadata.json b/.fern/metadata.json index 8ad6b8f..15d06e9 100644 --- a/.fern/metadata.json +++ b/.fern/metadata.json @@ -1,5 +1,5 @@ { - "cliVersion": "5.51.2", + "cliVersion": "5.80.4", "generatorName": "fernapi/fern-swift-sdk", "generatorVersion": "0.31.0", "generatorConfig": { @@ -7,6 +7,6 @@ "moduleName": "Vapi", "environmentEnumName": "VapiEnvironment" }, - "originGitCommit": "5a015aa01196915bea6110904c69d5804f457ff5", - "sdkVersion": "1.0.0" + "originGitCommit": "170bed6970e526a517e8ec4d249db90b7f6d95d4", + "sdkVersion": "1.0.1" } \ No newline at end of file diff --git a/.fern/replay.lock b/.fern/replay.lock new file mode 100644 index 0000000..701d191 --- /dev/null +++ b/.fern/replay.lock @@ -0,0 +1,16 @@ +# DO NOT EDIT MANUALLY - Managed by Fern Replay +version: "1.0" +generations: + - commit_sha: bc96c4695643e2ce65ba9bbc8f013ec90faf6884 + tree_hash: 0275948394219614d4d7f64cab0b932e7c2a767a + timestamp: 2026-07-28T00:28:03.852Z + cli_version: unknown + generator_versions: {} + - commit_sha: 999d474926103aa9fa79b85c0f760ac40acc5199 + tree_hash: 77335f2d5cb0badc49f15cd5f1c5b6eb5f0f8548 + timestamp: 2026-07-28T00:28:04.255Z + cli_version: unknown + generator_versions: + fernapi/fern-swift-sdk: 0.31.0 +current_generation: 999d474926103aa9fa79b85c0f760ac40acc5199 +patches: [] diff --git a/.fernignore b/.fernignore index 978b3fa..0e6333f 100644 --- a/.fernignore +++ b/.fernignore @@ -1,3 +1,6 @@ # Specify files that shouldn't be modified by Fern .github/workflows/sdk-release-pr-notification.yml changelog.md +.fern/replay.lock +.fern/replay.yml +.gitattributes diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000..74928d6 --- /dev/null +++ b/.gitattributes @@ -0,0 +1 @@ +.fern/replay.lock linguist-generated=true diff --git a/Sources/Requests/Requests+CreateFileDto.swift b/Sources/Requests/Requests+CreateFileDto.swift index d3bfadc..75afa51 100644 --- a/Sources/Requests/Requests+CreateFileDto.swift +++ b/Sources/Requests/Requests+CreateFileDto.swift @@ -1,6 +1,7 @@ import Foundation extension Requests { + /// A file-upload request containing the file to store and process in Vapi. public struct CreateFileDto { /// This is the File you want to upload for use with the Knowledge Base. public let file: FormFile diff --git a/Sources/Requests/Requests+InsightRunDto.swift b/Sources/Requests/Requests+InsightRunDto.swift index 01eb8db..d2996af 100644 --- a/Sources/Requests/Requests+InsightRunDto.swift +++ b/Sources/Requests/Requests+InsightRunDto.swift @@ -2,6 +2,7 @@ import Foundation extension Requests { public struct InsightRunDto: Codable, Hashable, Sendable { + /// Output-formatting instructions applied to the insight run. public let formatPlan: InsightRunFormatPlan? /// This is the optional time range override for the insight. /// If provided, overrides every field in the insight's timeRange. diff --git a/Sources/Requests/Requests+UpdateAssistantDto.swift b/Sources/Requests/Requests+UpdateAssistantDto.swift index b4d38e1..159a4ee 100644 --- a/Sources/Requests/Requests+UpdateAssistantDto.swift +++ b/Sources/Requests/Requests+UpdateAssistantDto.swift @@ -12,6 +12,7 @@ extension Requests { /// /// If unspecified, assistant will wait for user to speak and use the model to respond once they speak. public let firstMessage: String? + /// Set to `true` to allow the user to interrupt the assistant while it speaks the first message. Default is `false`. public let firstMessageInterruptionsEnabled: Bool? /// This is the mode for the first message. Default is 'assistant-speaks-first'. /// @@ -64,6 +65,7 @@ extension Requests { public let endCallMessage: String? /// This list contains phrases that, if spoken by the assistant, will trigger the call to be hung up. Case insensitive. public let endCallPhrases: [String]? + /// Compliance settings for the assistant, including HIPAA and PCI behavior, security filtering, and recording consent. public let compliancePlan: CompliancePlan? /// This is for metadata you want to store on the assistant. public let metadata: [String: JSONValue]? @@ -116,6 +118,7 @@ extension Requests { /// 2. phoneNumber.serverUrl /// 3. org.serverUrl public let server: Server? + /// Configuration for collecting and processing DTMF keypad input during calls. public let keypadInputPlan: KeypadInputPlan? /// Additional properties that are not explicitly defined in the schema public let additionalProperties: [String: JSONValue] diff --git a/Sources/Resources/Analytics/AnalyticsClient.swift b/Sources/Resources/Analytics/AnalyticsClient.swift index 9bd5b94..f4854d5 100644 --- a/Sources/Resources/Analytics/AnalyticsClient.swift +++ b/Sources/Resources/Analytics/AnalyticsClient.swift @@ -7,6 +7,9 @@ public final class AnalyticsClient: Sendable { self.httpClient = HTTPClient(config: config) } + /// Runs one or more metric queries against call or subscription data using the requested time range, groupings, and aggregate operations. + /// + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func get(request: Requests.AnalyticsQueryDto, requestOptions: RequestOptions? = nil) async throws -> [AnalyticsQueryResult] { return try await httpClient.performRequest( method: .post, diff --git a/Sources/Resources/Assistants/AssistantsClient.swift b/Sources/Resources/Assistants/AssistantsClient.swift index 3faa404..59f9634 100644 --- a/Sources/Resources/Assistants/AssistantsClient.swift +++ b/Sources/Resources/Assistants/AssistantsClient.swift @@ -7,6 +7,18 @@ public final class AssistantsClient: Sendable { self.httpClient = HTTPClient(config: config) } + /// Returns assistants for the authenticated organization. Filter results by creation or update timestamps and limit the number returned. + /// + /// - Parameter limit: This is the maximum number of items to return. Defaults to 100. + /// - Parameter createdAtGt: This will return items where the createdAt is greater than the specified value. + /// - Parameter createdAtLt: This will return items where the createdAt is less than the specified value. + /// - Parameter createdAtGe: This will return items where the createdAt is greater than or equal to the specified value. + /// - Parameter createdAtLe: This will return items where the createdAt is less than or equal to the specified value. + /// - Parameter updatedAtGt: This will return items where the updatedAt is greater than the specified value. + /// - Parameter updatedAtLt: This will return items where the updatedAt is less than the specified value. + /// - Parameter updatedAtGe: This will return items where the updatedAt is greater than or equal to the specified value. + /// - Parameter updatedAtLe: This will return items where the updatedAt is less than or equal to the specified value. + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func list(limit: Double? = nil, createdAtGt: Date? = nil, createdAtLt: Date? = nil, createdAtGe: Date? = nil, createdAtLe: Date? = nil, updatedAtGt: Date? = nil, updatedAtLt: Date? = nil, updatedAtGe: Date? = nil, updatedAtLe: Date? = nil, requestOptions: RequestOptions? = nil) async throws -> [Assistant] { return try await httpClient.performRequest( method: .get, @@ -27,6 +39,9 @@ public final class AssistantsClient: Sendable { ) } + /// Creates a reusable assistant configuration containing the model, voice, transcriber, tools, prompts, and call behavior. + /// + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func create(request: CreateAssistantDto, requestOptions: RequestOptions? = nil) async throws -> Assistant { return try await httpClient.performRequest( method: .post, @@ -37,6 +52,10 @@ public final class AssistantsClient: Sendable { ) } + /// Returns the assistant identified by its ID. + /// + /// - Parameter id: The unique identifier of the assistant. + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func get(id: String, requestOptions: RequestOptions? = nil) async throws -> Assistant { return try await httpClient.performRequest( method: .get, @@ -46,6 +65,10 @@ public final class AssistantsClient: Sendable { ) } + /// Deletes the assistant identified by its ID. + /// + /// - Parameter id: The unique identifier of the assistant. + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func delete(id: String, requestOptions: RequestOptions? = nil) async throws -> Assistant { return try await httpClient.performRequest( method: .delete, @@ -55,6 +78,10 @@ public final class AssistantsClient: Sendable { ) } + /// Updates the specified fields of the assistant identified by its ID. + /// + /// - Parameter id: The unique identifier of the assistant. + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func update(id: String, request: Requests.UpdateAssistantDto, requestOptions: RequestOptions? = nil) async throws -> Assistant { return try await httpClient.performRequest( method: .patch, diff --git a/Sources/Resources/Calls/CallsClient.swift b/Sources/Resources/Calls/CallsClient.swift index b19d048..7f676a3 100644 --- a/Sources/Resources/Calls/CallsClient.swift +++ b/Sources/Resources/Calls/CallsClient.swift @@ -7,6 +7,23 @@ public final class CallsClient: Sendable { self.httpClient = HTTPClient(config: config) } + /// Returns calls for the authenticated organization. Filter results by call ID, assistant ID, phone number ID, or creation and update timestamps. + /// + /// - Parameter id: This is the unique identifier for the call. + /// - Parameter assistantId: This will return calls with the specified assistantId. + /// - Parameter phoneNumberId: This is the phone number that will be used for the call. To use a transient number, use `phoneNumber` instead. + /// + /// Only relevant for `outboundPhoneCall` and `inboundPhoneCall` type. + /// - Parameter limit: This is the maximum number of items to return. Defaults to 100. + /// - Parameter createdAtGt: This will return items where the createdAt is greater than the specified value. + /// - Parameter createdAtLt: This will return items where the createdAt is less than the specified value. + /// - Parameter createdAtGe: This will return items where the createdAt is greater than or equal to the specified value. + /// - Parameter createdAtLe: This will return items where the createdAt is less than or equal to the specified value. + /// - Parameter updatedAtGt: This will return items where the updatedAt is greater than the specified value. + /// - Parameter updatedAtLt: This will return items where the updatedAt is less than the specified value. + /// - Parameter updatedAtGe: This will return items where the updatedAt is greater than or equal to the specified value. + /// - Parameter updatedAtLe: This will return items where the updatedAt is less than or equal to the specified value. + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func list(id: String? = nil, assistantId: String? = nil, phoneNumberId: String? = nil, limit: Double? = nil, createdAtGt: Date? = nil, createdAtLt: Date? = nil, createdAtGe: Date? = nil, createdAtLe: Date? = nil, updatedAtGt: Date? = nil, updatedAtLt: Date? = nil, updatedAtGe: Date? = nil, updatedAtLe: Date? = nil, requestOptions: RequestOptions? = nil) async throws -> [Call] { return try await httpClient.performRequest( method: .get, @@ -30,6 +47,9 @@ public final class CallsClient: Sendable { ) } + /// Creates a call using an assistant or squad. The request can reference saved resources or include transient configurations. + /// + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func create(request: Requests.CreateCallDto, requestOptions: RequestOptions? = nil) async throws -> CreateCallsResponse { return try await httpClient.performRequest( method: .post, @@ -40,6 +60,10 @@ public final class CallsClient: Sendable { ) } + /// Returns the call identified by its ID, including its status, configuration, and available call data. + /// + /// - Parameter id: The unique identifier of the call. + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func get(id: String, requestOptions: RequestOptions? = nil) async throws -> Call { return try await httpClient.performRequest( method: .get, @@ -49,6 +73,9 @@ public final class CallsClient: Sendable { ) } + /// Deletes the call identified by its ID. + /// + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func delete(id: String, request: Requests.DeleteCallDto, requestOptions: RequestOptions? = nil) async throws -> Call { return try await httpClient.performRequest( method: .delete, @@ -59,6 +86,10 @@ public final class CallsClient: Sendable { ) } + /// Updates the call identified by its ID. + /// + /// - Parameter id: The unique identifier of the call. + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func update(id: String, request: Requests.UpdateCallDto, requestOptions: RequestOptions? = nil) async throws -> Call { return try await httpClient.performRequest( method: .patch, diff --git a/Sources/Resources/Campaigns/CampaignsClient.swift b/Sources/Resources/Campaigns/CampaignsClient.swift index d627801..b00b430 100644 --- a/Sources/Resources/Campaigns/CampaignsClient.swift +++ b/Sources/Resources/Campaigns/CampaignsClient.swift @@ -7,6 +7,22 @@ public final class CampaignsClient: Sendable { self.httpClient = HTTPClient(config: config) } + /// Returns outbound calling campaigns for the authenticated organization. Filter results by campaign ID, status, or creation and update timestamps. + /// + /// - Parameter id: Filters campaigns by ID. + /// - Parameter status: Filters campaigns by status. + /// - Parameter page: This is the page number to return. Defaults to 1. + /// - Parameter sortOrder: This is the sort order for pagination. Defaults to 'DESC'. + /// - Parameter limit: This is the maximum number of items to return. Defaults to 100. + /// - Parameter createdAtGt: This will return items where the createdAt is greater than the specified value. + /// - Parameter createdAtLt: This will return items where the createdAt is less than the specified value. + /// - Parameter createdAtGe: This will return items where the createdAt is greater than or equal to the specified value. + /// - Parameter createdAtLe: This will return items where the createdAt is less than or equal to the specified value. + /// - Parameter updatedAtGt: This will return items where the updatedAt is greater than the specified value. + /// - Parameter updatedAtLt: This will return items where the updatedAt is less than the specified value. + /// - Parameter updatedAtGe: This will return items where the updatedAt is greater than or equal to the specified value. + /// - Parameter updatedAtLe: This will return items where the updatedAt is less than or equal to the specified value. + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func campaignControllerFindAll(id: String? = nil, status: CampaignControllerFindAllRequestStatus? = nil, page: Double? = nil, sortOrder: CampaignControllerFindAllRequestSortOrder? = nil, limit: Double? = nil, createdAtGt: Date? = nil, createdAtLt: Date? = nil, createdAtGe: Date? = nil, createdAtLe: Date? = nil, updatedAtGt: Date? = nil, updatedAtLt: Date? = nil, updatedAtGe: Date? = nil, updatedAtLe: Date? = nil, requestOptions: RequestOptions? = nil) async throws -> CampaignPaginatedResponse { return try await httpClient.performRequest( method: .get, @@ -31,6 +47,9 @@ public final class CampaignsClient: Sendable { ) } + /// Creates an outbound calling campaign that calls a set of customers. + /// + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func campaignControllerCreate(request: Requests.CreateCampaignDto, requestOptions: RequestOptions? = nil) async throws -> Campaign { return try await httpClient.performRequest( method: .post, @@ -41,6 +60,10 @@ public final class CampaignsClient: Sendable { ) } + /// Returns the outbound calling campaign identified by its ID. + /// + /// - Parameter id: The unique identifier of the campaign. + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func campaignControllerFindOne(id: String, requestOptions: RequestOptions? = nil) async throws -> Campaign { return try await httpClient.performRequest( method: .get, @@ -50,6 +73,10 @@ public final class CampaignsClient: Sendable { ) } + /// Deletes the outbound calling campaign identified by its ID. + /// + /// - Parameter id: The unique identifier of the campaign. + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func campaignControllerRemove(id: String, requestOptions: RequestOptions? = nil) async throws -> Campaign { return try await httpClient.performRequest( method: .delete, @@ -59,6 +86,10 @@ public final class CampaignsClient: Sendable { ) } + /// Updates the outbound calling campaign identified by its ID. Campaigns can be ended by updating their status to `ended`. + /// + /// - Parameter id: The unique identifier of the campaign. + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func campaignControllerUpdate(id: String, request: Requests.UpdateCampaignDto, requestOptions: RequestOptions? = nil) async throws -> Campaign { return try await httpClient.performRequest( method: .patch, diff --git a/Sources/Resources/Eval/EvalClient.swift b/Sources/Resources/Eval/EvalClient.swift index 8054608..3225dac 100644 --- a/Sources/Resources/Eval/EvalClient.swift +++ b/Sources/Resources/Eval/EvalClient.swift @@ -7,6 +7,21 @@ public final class EvalClient: Sendable { self.httpClient = HTTPClient(config: config) } + /// Returns eval definitions for the authenticated organization. Filter results by ID or creation and update timestamps. + /// + /// - Parameter id: Filters eval definitions by ID. + /// - Parameter page: This is the page number to return. Defaults to 1. + /// - Parameter sortOrder: This is the sort order for pagination. Defaults to 'DESC'. + /// - Parameter limit: This is the maximum number of items to return. Defaults to 100. + /// - Parameter createdAtGt: This will return items where the createdAt is greater than the specified value. + /// - Parameter createdAtLt: This will return items where the createdAt is less than the specified value. + /// - Parameter createdAtGe: This will return items where the createdAt is greater than or equal to the specified value. + /// - Parameter createdAtLe: This will return items where the createdAt is less than or equal to the specified value. + /// - Parameter updatedAtGt: This will return items where the updatedAt is greater than the specified value. + /// - Parameter updatedAtLt: This will return items where the updatedAt is less than the specified value. + /// - Parameter updatedAtGe: This will return items where the updatedAt is greater than or equal to the specified value. + /// - Parameter updatedAtLe: This will return items where the updatedAt is less than or equal to the specified value. + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func evalControllerGetPaginated(id: String? = nil, page: Double? = nil, sortOrder: EvalControllerGetPaginatedRequestSortOrder? = nil, limit: Double? = nil, createdAtGt: Date? = nil, createdAtLt: Date? = nil, createdAtGe: Date? = nil, createdAtLe: Date? = nil, updatedAtGt: Date? = nil, updatedAtLt: Date? = nil, updatedAtGe: Date? = nil, updatedAtLe: Date? = nil, requestOptions: RequestOptions? = nil) async throws -> EvalPaginatedResponse { return try await httpClient.performRequest( method: .get, @@ -30,6 +45,9 @@ public final class EvalClient: Sendable { ) } + /// Creates a reusable eval that defines a mock conversation and checkpoints for evaluating assistant responses and tool calls. + /// + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func evalControllerCreate(request: CreateEvalDto, requestOptions: RequestOptions? = nil) async throws -> Eval { return try await httpClient.performRequest( method: .post, @@ -40,6 +58,10 @@ public final class EvalClient: Sendable { ) } + /// Returns the eval definition identified by its ID. + /// + /// - Parameter id: The unique identifier of the eval definition. + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func evalControllerGet(id: String, requestOptions: RequestOptions? = nil) async throws -> Eval { return try await httpClient.performRequest( method: .get, @@ -49,6 +71,10 @@ public final class EvalClient: Sendable { ) } + /// Deletes the eval definition identified by its ID. + /// + /// - Parameter id: The unique identifier of the eval definition. + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func evalControllerRemove(id: String, requestOptions: RequestOptions? = nil) async throws -> Eval { return try await httpClient.performRequest( method: .delete, @@ -58,6 +84,10 @@ public final class EvalClient: Sendable { ) } + /// Updates the eval definition identified by its ID. + /// + /// - Parameter id: The unique identifier of the eval definition. + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func evalControllerUpdate(id: String, request: Requests.UpdateEvalDto, requestOptions: RequestOptions? = nil) async throws -> Eval { return try await httpClient.performRequest( method: .patch, @@ -68,6 +98,10 @@ public final class EvalClient: Sendable { ) } + /// Returns the eval run identified by its ID. + /// + /// - Parameter id: The unique identifier of the eval run. + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func evalControllerGetRun(id: String, requestOptions: RequestOptions? = nil) async throws -> EvalRun { return try await httpClient.performRequest( method: .get, @@ -77,6 +111,10 @@ public final class EvalClient: Sendable { ) } + /// Deletes the eval run identified by its ID. + /// + /// - Parameter id: The unique identifier of the eval run. + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func evalControllerRemoveRun(id: String, requestOptions: RequestOptions? = nil) async throws -> EvalRun { return try await httpClient.performRequest( method: .delete, @@ -86,6 +124,21 @@ public final class EvalClient: Sendable { ) } + /// Returns eval runs for the authenticated organization. Filter results by ID or creation and update timestamps. + /// + /// - Parameter id: Filters eval runs by ID. + /// - Parameter page: This is the page number to return. Defaults to 1. + /// - Parameter sortOrder: This is the sort order for pagination. Defaults to 'DESC'. + /// - Parameter limit: This is the maximum number of items to return. Defaults to 100. + /// - Parameter createdAtGt: This will return items where the createdAt is greater than the specified value. + /// - Parameter createdAtLt: This will return items where the createdAt is less than the specified value. + /// - Parameter createdAtGe: This will return items where the createdAt is greater than or equal to the specified value. + /// - Parameter createdAtLe: This will return items where the createdAt is less than or equal to the specified value. + /// - Parameter updatedAtGt: This will return items where the updatedAt is greater than the specified value. + /// - Parameter updatedAtLt: This will return items where the updatedAt is less than the specified value. + /// - Parameter updatedAtGe: This will return items where the updatedAt is greater than or equal to the specified value. + /// - Parameter updatedAtLe: This will return items where the updatedAt is less than or equal to the specified value. + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func evalControllerGetRunsPaginated(id: String? = nil, page: Double? = nil, sortOrder: EvalControllerGetRunsPaginatedRequestSortOrder? = nil, limit: Double? = nil, createdAtGt: Date? = nil, createdAtLt: Date? = nil, createdAtGe: Date? = nil, createdAtLe: Date? = nil, updatedAtGt: Date? = nil, updatedAtLt: Date? = nil, updatedAtGe: Date? = nil, updatedAtLe: Date? = nil, requestOptions: RequestOptions? = nil) async throws -> EvalRunPaginatedResponse { return try await httpClient.performRequest( method: .get, @@ -109,6 +162,9 @@ public final class EvalClient: Sendable { ) } + /// Runs a saved or transient eval against an assistant or squad and creates an eval-run record containing the results. + /// + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func evalControllerRun(request: Requests.CreateEvalRunDto, requestOptions: RequestOptions? = nil) async throws -> [String: JSONValue] { return try await httpClient.performRequest( method: .post, diff --git a/Sources/Resources/Files/FilesClient.swift b/Sources/Resources/Files/FilesClient.swift index bc08e82..b14ffcb 100644 --- a/Sources/Resources/Files/FilesClient.swift +++ b/Sources/Resources/Files/FilesClient.swift @@ -7,6 +7,9 @@ public final class FilesClient: Sendable { self.httpClient = HTTPClient(config: config) } + /// Returns files uploaded to the authenticated organization. + /// + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func list(requestOptions: RequestOptions? = nil) async throws -> [File] { return try await httpClient.performRequest( method: .get, @@ -16,6 +19,10 @@ public final class FilesClient: Sendable { ) } + /// Uploads a file for use with a Vapi knowledge base. + /// + /// - Parameter request: A file-upload request containing the file to store and process in Vapi. + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func create(request: Requests.CreateFileDto, requestOptions: RequestOptions? = nil) async throws -> File { return try await httpClient.performRequest( method: .post, @@ -27,6 +34,10 @@ public final class FilesClient: Sendable { ) } + /// Returns the uploaded file identified by its ID. + /// + /// - Parameter id: The unique identifier of the file. + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func get(id: String, requestOptions: RequestOptions? = nil) async throws -> File { return try await httpClient.performRequest( method: .get, @@ -36,6 +47,10 @@ public final class FilesClient: Sendable { ) } + /// Deletes the uploaded file identified by its ID. + /// + /// - Parameter id: The unique identifier of the file. + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func delete(id: String, requestOptions: RequestOptions? = nil) async throws -> File { return try await httpClient.performRequest( method: .delete, @@ -45,6 +60,10 @@ public final class FilesClient: Sendable { ) } + /// Updates the name of the uploaded file identified by its ID. + /// + /// - Parameter id: The unique identifier of the file. + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func update(id: String, request: Requests.UpdateFileDto, requestOptions: RequestOptions? = nil) async throws -> File { return try await httpClient.performRequest( method: .patch, diff --git a/Sources/Resources/Insight/InsightClient.swift b/Sources/Resources/Insight/InsightClient.swift index 2896b3f..5ff611f 100644 --- a/Sources/Resources/Insight/InsightClient.swift +++ b/Sources/Resources/Insight/InsightClient.swift @@ -7,6 +7,21 @@ public final class InsightClient: Sendable { self.httpClient = HTTPClient(config: config) } + /// Returns saved reporting insights for the authenticated organization. Filter results by ID or creation and update timestamps. + /// + /// - Parameter id: Filters reporting insights by ID. + /// - Parameter page: This is the page number to return. Defaults to 1. + /// - Parameter sortOrder: This is the sort order for pagination. Defaults to 'DESC'. + /// - Parameter limit: This is the maximum number of items to return. Defaults to 100. + /// - Parameter createdAtGt: This will return items where the createdAt is greater than the specified value. + /// - Parameter createdAtLt: This will return items where the createdAt is less than the specified value. + /// - Parameter createdAtGe: This will return items where the createdAt is greater than or equal to the specified value. + /// - Parameter createdAtLe: This will return items where the createdAt is less than or equal to the specified value. + /// - Parameter updatedAtGt: This will return items where the updatedAt is greater than the specified value. + /// - Parameter updatedAtLt: This will return items where the updatedAt is less than the specified value. + /// - Parameter updatedAtGe: This will return items where the updatedAt is greater than or equal to the specified value. + /// - Parameter updatedAtLe: This will return items where the updatedAt is less than or equal to the specified value. + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func insightControllerFindAll(id: String? = nil, page: Double? = nil, sortOrder: InsightControllerFindAllRequestSortOrder? = nil, limit: Double? = nil, createdAtGt: Date? = nil, createdAtLt: Date? = nil, createdAtGe: Date? = nil, createdAtLe: Date? = nil, updatedAtGt: Date? = nil, updatedAtLt: Date? = nil, updatedAtGe: Date? = nil, updatedAtLe: Date? = nil, requestOptions: RequestOptions? = nil) async throws -> InsightPaginatedResponse { return try await httpClient.performRequest( method: .get, @@ -30,6 +45,9 @@ public final class InsightClient: Sendable { ) } + /// Creates a saved reporting insight that queries call data and presents the results as a bar chart, pie chart, line chart, or text value. + /// + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func insightControllerCreate(request: InsightControllerCreateRequest, requestOptions: RequestOptions? = nil) async throws -> InsightControllerCreateResponse { return try await httpClient.performRequest( method: .post, @@ -40,6 +58,10 @@ public final class InsightClient: Sendable { ) } + /// Returns the reporting insight identified by its ID. + /// + /// - Parameter id: The unique identifier of the reporting insight. + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func insightControllerFindOne(id: String, requestOptions: RequestOptions? = nil) async throws -> InsightControllerFindOneResponse { return try await httpClient.performRequest( method: .get, @@ -49,6 +71,10 @@ public final class InsightClient: Sendable { ) } + /// Deletes the reporting insight identified by its ID. + /// + /// - Parameter id: The unique identifier of the reporting insight. + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func insightControllerRemove(id: String, requestOptions: RequestOptions? = nil) async throws -> InsightControllerRemoveResponse { return try await httpClient.performRequest( method: .delete, @@ -58,6 +84,10 @@ public final class InsightClient: Sendable { ) } + /// Updates the reporting insight identified by its ID. + /// + /// - Parameter id: The unique identifier of the reporting insight. + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func insightControllerUpdate(id: String, request: InsightControllerUpdateRequestBody, requestOptions: RequestOptions? = nil) async throws -> InsightControllerUpdateResponse { return try await httpClient.performRequest( method: .patch, @@ -68,6 +98,10 @@ public final class InsightClient: Sendable { ) } + /// Runs a saved reporting insight, optionally overriding its time range and response format. + /// + /// - Parameter id: The unique identifier of the reporting insight. + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func insightControllerRun(id: String, request: Requests.InsightRunDto, requestOptions: RequestOptions? = nil) async throws -> InsightRunResponse { return try await httpClient.performRequest( method: .post, @@ -78,6 +112,9 @@ public final class InsightClient: Sendable { ) } + /// Runs an insight definition without first saving it, returning a preview of the resulting chart or text value. + /// + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func insightControllerPreview(request: InsightControllerPreviewRequest, requestOptions: RequestOptions? = nil) async throws -> InsightRunResponse { return try await httpClient.performRequest( method: .post, diff --git a/Sources/Resources/ObservabilityScorecard/ObservabilityScorecardClient.swift b/Sources/Resources/ObservabilityScorecard/ObservabilityScorecardClient.swift index b6261b7..8fc9ce7 100644 --- a/Sources/Resources/ObservabilityScorecard/ObservabilityScorecardClient.swift +++ b/Sources/Resources/ObservabilityScorecard/ObservabilityScorecardClient.swift @@ -7,6 +7,10 @@ public final class ObservabilityScorecardClient: Sendable { self.httpClient = HTTPClient(config: config) } + /// Returns the scorecard identified by its ID. + /// + /// - Parameter id: The unique identifier of the scorecard. + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func scorecardControllerGet(id: String, requestOptions: RequestOptions? = nil) async throws -> Scorecard { return try await httpClient.performRequest( method: .get, @@ -16,6 +20,10 @@ public final class ObservabilityScorecardClient: Sendable { ) } + /// Deletes the scorecard identified by its ID. + /// + /// - Parameter id: The unique identifier of the scorecard. + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func scorecardControllerRemove(id: String, requestOptions: RequestOptions? = nil) async throws -> Scorecard { return try await httpClient.performRequest( method: .delete, @@ -25,6 +33,10 @@ public final class ObservabilityScorecardClient: Sendable { ) } + /// Updates the scorecard identified by its ID. + /// + /// - Parameter id: The unique identifier of the scorecard. + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func scorecardControllerUpdate(id: String, request: Requests.UpdateScorecardDto, requestOptions: RequestOptions? = nil) async throws -> Scorecard { return try await httpClient.performRequest( method: .patch, @@ -35,6 +47,21 @@ public final class ObservabilityScorecardClient: Sendable { ) } + /// Returns scorecards for the authenticated organization. Filter results by ID or creation and update timestamps. + /// + /// - Parameter id: Filters scorecards by ID. + /// - Parameter page: This is the page number to return. Defaults to 1. + /// - Parameter sortOrder: This is the sort order for pagination. Defaults to 'DESC'. + /// - Parameter limit: This is the maximum number of items to return. Defaults to 100. + /// - Parameter createdAtGt: This will return items where the createdAt is greater than the specified value. + /// - Parameter createdAtLt: This will return items where the createdAt is less than the specified value. + /// - Parameter createdAtGe: This will return items where the createdAt is greater than or equal to the specified value. + /// - Parameter createdAtLe: This will return items where the createdAt is less than or equal to the specified value. + /// - Parameter updatedAtGt: This will return items where the updatedAt is greater than the specified value. + /// - Parameter updatedAtLt: This will return items where the updatedAt is less than the specified value. + /// - Parameter updatedAtGe: This will return items where the updatedAt is greater than or equal to the specified value. + /// - Parameter updatedAtLe: This will return items where the updatedAt is less than or equal to the specified value. + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func scorecardControllerGetPaginated(id: String? = nil, page: Double? = nil, sortOrder: ScorecardControllerGetPaginatedRequestSortOrder? = nil, limit: Double? = nil, createdAtGt: Date? = nil, createdAtLt: Date? = nil, createdAtGe: Date? = nil, createdAtLe: Date? = nil, updatedAtGt: Date? = nil, updatedAtLt: Date? = nil, updatedAtGe: Date? = nil, updatedAtLe: Date? = nil, requestOptions: RequestOptions? = nil) async throws -> ScorecardPaginatedResponse { return try await httpClient.performRequest( method: .get, @@ -58,6 +85,9 @@ public final class ObservabilityScorecardClient: Sendable { ) } + /// Creates a scorecard containing metrics, scoring conditions, and optional links to assistants whose calls should be evaluated. + /// + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func scorecardControllerCreate(request: CreateScorecardDto, requestOptions: RequestOptions? = nil) async throws -> Scorecard { return try await httpClient.performRequest( method: .post, diff --git a/Sources/Resources/PhoneNumbers/PhoneNumbersClient.swift b/Sources/Resources/PhoneNumbers/PhoneNumbersClient.swift index e5ae7d1..2086a97 100644 --- a/Sources/Resources/PhoneNumbers/PhoneNumbersClient.swift +++ b/Sources/Resources/PhoneNumbers/PhoneNumbersClient.swift @@ -7,6 +7,18 @@ public final class PhoneNumbersClient: Sendable { self.httpClient = HTTPClient(config: config) } + /// Returns phone numbers for the authenticated organization. Filter results by creation or update timestamps and limit the number returned. + /// + /// - Parameter limit: This is the maximum number of items to return. Defaults to 100. + /// - Parameter createdAtGt: This will return items where the createdAt is greater than the specified value. + /// - Parameter createdAtLt: This will return items where the createdAt is less than the specified value. + /// - Parameter createdAtGe: This will return items where the createdAt is greater than or equal to the specified value. + /// - Parameter createdAtLe: This will return items where the createdAt is less than or equal to the specified value. + /// - Parameter updatedAtGt: This will return items where the updatedAt is greater than the specified value. + /// - Parameter updatedAtLt: This will return items where the updatedAt is less than the specified value. + /// - Parameter updatedAtGe: This will return items where the updatedAt is greater than or equal to the specified value. + /// - Parameter updatedAtLe: This will return items where the updatedAt is less than or equal to the specified value. + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func list(limit: Double? = nil, createdAtGt: Date? = nil, createdAtLt: Date? = nil, createdAtGe: Date? = nil, createdAtLe: Date? = nil, updatedAtGt: Date? = nil, updatedAtLt: Date? = nil, updatedAtGe: Date? = nil, updatedAtLe: Date? = nil, requestOptions: RequestOptions? = nil) async throws -> [ListPhoneNumbersResponseItem] { return try await httpClient.performRequest( method: .get, @@ -27,6 +39,9 @@ public final class PhoneNumbersClient: Sendable { ) } + /// Creates a Vapi phone number or imports a phone number from a supported provider, including Twilio, Vonage, Telnyx, or a bring-your-own provider. + /// + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func create(request: CreatePhoneNumbersRequest, requestOptions: RequestOptions? = nil) async throws -> CreatePhoneNumbersResponse { return try await httpClient.performRequest( method: .post, @@ -37,6 +52,21 @@ public final class PhoneNumbersClient: Sendable { ) } + /// Returns a paginated list of phone numbers for the authenticated organization. Search by name, number, or SIP URI using a partial, case-insensitive match, and filter by creation or update timestamps. + /// + /// - Parameter search: This will search phone numbers by name, number, or SIP URI (partial match, case-insensitive). + /// - Parameter page: This is the page number to return. Defaults to 1. + /// - Parameter sortOrder: This is the sort order for pagination. Defaults to 'DESC'. + /// - Parameter limit: This is the maximum number of items to return. Defaults to 100. + /// - Parameter createdAtGt: This will return items where the createdAt is greater than the specified value. + /// - Parameter createdAtLt: This will return items where the createdAt is less than the specified value. + /// - Parameter createdAtGe: This will return items where the createdAt is greater than or equal to the specified value. + /// - Parameter createdAtLe: This will return items where the createdAt is less than or equal to the specified value. + /// - Parameter updatedAtGt: This will return items where the updatedAt is greater than the specified value. + /// - Parameter updatedAtLt: This will return items where the updatedAt is less than the specified value. + /// - Parameter updatedAtGe: This will return items where the updatedAt is greater than or equal to the specified value. + /// - Parameter updatedAtLe: This will return items where the updatedAt is less than or equal to the specified value. + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func phoneNumberControllerFindAllPaginated(search: String? = nil, page: Double? = nil, sortOrder: PhoneNumberControllerFindAllPaginatedRequestSortOrder? = nil, limit: Double? = nil, createdAtGt: Date? = nil, createdAtLt: Date? = nil, createdAtGe: Date? = nil, createdAtLe: Date? = nil, updatedAtGt: Date? = nil, updatedAtLt: Date? = nil, updatedAtGe: Date? = nil, updatedAtLe: Date? = nil, requestOptions: RequestOptions? = nil) async throws -> PhoneNumberPaginatedResponse { return try await httpClient.performRequest( method: .get, @@ -60,6 +90,10 @@ public final class PhoneNumbersClient: Sendable { ) } + /// Returns the phone number resource identified by its ID. + /// + /// - Parameter id: The unique identifier of the phone number. + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func get(id: String, requestOptions: RequestOptions? = nil) async throws -> GetPhoneNumbersResponse { return try await httpClient.performRequest( method: .get, @@ -69,6 +103,10 @@ public final class PhoneNumbersClient: Sendable { ) } + /// Deletes the phone number resource identified by its ID. + /// + /// - Parameter id: The unique identifier of the phone number. + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func delete(id: String, requestOptions: RequestOptions? = nil) async throws -> DeletePhoneNumbersResponse { return try await httpClient.performRequest( method: .delete, @@ -78,6 +116,10 @@ public final class PhoneNumbersClient: Sendable { ) } + /// Updates the specified fields of the phone number resource identified by its ID. + /// + /// - Parameter id: The unique identifier of the phone number. + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func update(id: String, request: UpdatePhoneNumbersRequestBody, requestOptions: RequestOptions? = nil) async throws -> UpdatePhoneNumbersResponse { return try await httpClient.performRequest( method: .patch, diff --git a/Sources/Resources/ProviderResources/ProviderResourcesClient.swift b/Sources/Resources/ProviderResources/ProviderResourcesClient.swift index 0e5e150..5b505fb 100644 --- a/Sources/Resources/ProviderResources/ProviderResourcesClient.swift +++ b/Sources/Resources/ProviderResources/ProviderResourcesClient.swift @@ -7,6 +7,24 @@ public final class ProviderResourcesClient: Sendable { self.httpClient = HTTPClient(config: config) } + /// Returns a paginated list of provider resources for the authenticated organization. Filter pronunciation dictionaries by provider, resource ID, or creation and update timestamps. + /// + /// - Parameter provider: The provider (e.g., 11labs) + /// - Parameter resourceName: The resource name (e.g., pronunciation-dictionary) + /// - Parameter id: Filters provider resources by their resource ID. + /// - Parameter resourceId: Filters provider resources by their provider-specific resource ID. + /// - Parameter page: This is the page number to return. Defaults to 1. + /// - Parameter sortOrder: This is the sort order for pagination. Defaults to 'DESC'. + /// - Parameter limit: This is the maximum number of items to return. Defaults to 100. + /// - Parameter createdAtGt: This will return items where the createdAt is greater than the specified value. + /// - Parameter createdAtLt: This will return items where the createdAt is less than the specified value. + /// - Parameter createdAtGe: This will return items where the createdAt is greater than or equal to the specified value. + /// - Parameter createdAtLe: This will return items where the createdAt is less than or equal to the specified value. + /// - Parameter updatedAtGt: This will return items where the updatedAt is greater than the specified value. + /// - Parameter updatedAtLt: This will return items where the updatedAt is less than the specified value. + /// - Parameter updatedAtGe: This will return items where the updatedAt is greater than or equal to the specified value. + /// - Parameter updatedAtLe: This will return items where the updatedAt is less than or equal to the specified value. + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func providerResourceControllerGetProviderResourcesPaginated(provider: String, resourceName: String, id: String? = nil, resourceId: String? = nil, page: Double? = nil, sortOrder: ProviderResourceControllerGetProviderResourcesPaginatedRequestSortOrder? = nil, limit: Double? = nil, createdAtGt: Date? = nil, createdAtLt: Date? = nil, createdAtGe: Date? = nil, createdAtLe: Date? = nil, updatedAtGt: Date? = nil, updatedAtLt: Date? = nil, updatedAtGe: Date? = nil, updatedAtLe: Date? = nil, requestOptions: RequestOptions? = nil) async throws -> ProviderResourcePaginatedResponse { return try await httpClient.performRequest( method: .get, @@ -31,6 +49,11 @@ public final class ProviderResourcesClient: Sendable { ) } + /// Creates a pronunciation-dictionary resource for a supported provider, currently Cartesia or ElevenLabs. + /// + /// - Parameter provider: The provider (e.g., 11labs) + /// - Parameter resourceName: The resource name (e.g., pronunciation-dictionary) + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func providerResourceControllerCreateProviderResource(provider: String, resourceName: String, requestOptions: RequestOptions? = nil) async throws -> ProviderResource { return try await httpClient.performRequest( method: .post, @@ -40,6 +63,12 @@ public final class ProviderResourcesClient: Sendable { ) } + /// Returns the provider resource identified by its Vapi resource ID. + /// + /// - Parameter provider: The provider (e.g., 11labs) + /// - Parameter resourceName: The resource name (e.g., pronunciation-dictionary) + /// - Parameter id: The unique identifier of the provider resource. + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func providerResourceControllerGetProviderResource(provider: String, resourceName: String, id: String, requestOptions: RequestOptions? = nil) async throws -> ProviderResource { return try await httpClient.performRequest( method: .get, @@ -49,6 +78,12 @@ public final class ProviderResourcesClient: Sendable { ) } + /// Deletes the provider resource identified by its Vapi resource ID. + /// + /// - Parameter provider: The provider (e.g., 11labs) + /// - Parameter resourceName: The resource name (e.g., pronunciation-dictionary) + /// - Parameter id: The unique identifier of the provider resource. + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func providerResourceControllerDeleteProviderResource(provider: String, resourceName: String, id: String, requestOptions: RequestOptions? = nil) async throws -> ProviderResource { return try await httpClient.performRequest( method: .delete, @@ -58,6 +93,12 @@ public final class ProviderResourcesClient: Sendable { ) } + /// Updates the provider resource identified by its Vapi resource ID. + /// + /// - Parameter provider: The provider (e.g., 11labs) + /// - Parameter resourceName: The resource name (e.g., pronunciation-dictionary) + /// - Parameter id: The unique identifier of the provider resource. + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func providerResourceControllerUpdateProviderResource(provider: String, resourceName: String, id: String, requestOptions: RequestOptions? = nil) async throws -> ProviderResource { return try await httpClient.performRequest( method: .patch, diff --git a/Sources/Resources/Squads/SquadsClient.swift b/Sources/Resources/Squads/SquadsClient.swift index ef6e483..aa06ba0 100644 --- a/Sources/Resources/Squads/SquadsClient.swift +++ b/Sources/Resources/Squads/SquadsClient.swift @@ -7,6 +7,18 @@ public final class SquadsClient: Sendable { self.httpClient = HTTPClient(config: config) } + /// Returns squads for the authenticated organization. Filter results by creation or update timestamps and limit the number returned. + /// + /// - Parameter limit: This is the maximum number of items to return. Defaults to 100. + /// - Parameter createdAtGt: This will return items where the createdAt is greater than the specified value. + /// - Parameter createdAtLt: This will return items where the createdAt is less than the specified value. + /// - Parameter createdAtGe: This will return items where the createdAt is greater than or equal to the specified value. + /// - Parameter createdAtLe: This will return items where the createdAt is less than or equal to the specified value. + /// - Parameter updatedAtGt: This will return items where the updatedAt is greater than the specified value. + /// - Parameter updatedAtLt: This will return items where the updatedAt is less than the specified value. + /// - Parameter updatedAtGe: This will return items where the updatedAt is greater than or equal to the specified value. + /// - Parameter updatedAtLe: This will return items where the updatedAt is less than or equal to the specified value. + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func list(limit: Double? = nil, createdAtGt: Date? = nil, createdAtLt: Date? = nil, createdAtGe: Date? = nil, createdAtLe: Date? = nil, updatedAtGt: Date? = nil, updatedAtLt: Date? = nil, updatedAtGe: Date? = nil, updatedAtLe: Date? = nil, requestOptions: RequestOptions? = nil) async throws -> [Squad] { return try await httpClient.performRequest( method: .get, @@ -27,6 +39,9 @@ public final class SquadsClient: Sendable { ) } + /// Creates a squad that coordinates multiple assistants and their handoffs during a conversation. + /// + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func create(request: CreateSquadDto, requestOptions: RequestOptions? = nil) async throws -> Squad { return try await httpClient.performRequest( method: .post, @@ -37,6 +52,10 @@ public final class SquadsClient: Sendable { ) } + /// Returns the squad identified by its ID. + /// + /// - Parameter id: The unique identifier of the squad. + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func get(id: String, requestOptions: RequestOptions? = nil) async throws -> Squad { return try await httpClient.performRequest( method: .get, @@ -46,6 +65,10 @@ public final class SquadsClient: Sendable { ) } + /// Deletes the squad identified by its ID. + /// + /// - Parameter id: The unique identifier of the squad. + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func delete(id: String, requestOptions: RequestOptions? = nil) async throws -> Squad { return try await httpClient.performRequest( method: .delete, @@ -55,6 +78,10 @@ public final class SquadsClient: Sendable { ) } + /// Updates the specified fields of the squad identified by its ID. + /// + /// - Parameter id: The unique identifier of the squad. + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func update(id: String, request: Requests.UpdateSquadDto, requestOptions: RequestOptions? = nil) async throws -> Squad { return try await httpClient.performRequest( method: .patch, diff --git a/Sources/Resources/StructuredOutputs/StructuredOutputsClient.swift b/Sources/Resources/StructuredOutputs/StructuredOutputsClient.swift index 5827f4b..d760ba7 100644 --- a/Sources/Resources/StructuredOutputs/StructuredOutputsClient.swift +++ b/Sources/Resources/StructuredOutputs/StructuredOutputsClient.swift @@ -7,6 +7,22 @@ public final class StructuredOutputsClient: Sendable { self.httpClient = HTTPClient(config: config) } + /// Returns structured-output definitions for the authenticated organization. Filter results by ID, name, or creation and update timestamps. + /// + /// - Parameter id: This will return structured outputs where the id matches the specified value. + /// - Parameter name: This will return structured outputs where the name matches the specified value. + /// - Parameter page: This is the page number to return. Defaults to 1. + /// - Parameter sortOrder: This is the sort order for pagination. Defaults to 'DESC'. + /// - Parameter limit: This is the maximum number of items to return. Defaults to 100. + /// - Parameter createdAtGt: This will return items where the createdAt is greater than the specified value. + /// - Parameter createdAtLt: This will return items where the createdAt is less than the specified value. + /// - Parameter createdAtGe: This will return items where the createdAt is greater than or equal to the specified value. + /// - Parameter createdAtLe: This will return items where the createdAt is less than or equal to the specified value. + /// - Parameter updatedAtGt: This will return items where the updatedAt is greater than the specified value. + /// - Parameter updatedAtLt: This will return items where the updatedAt is less than the specified value. + /// - Parameter updatedAtGe: This will return items where the updatedAt is greater than or equal to the specified value. + /// - Parameter updatedAtLe: This will return items where the updatedAt is less than or equal to the specified value. + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func structuredOutputControllerFindAll(id: String? = nil, name: String? = nil, page: Double? = nil, sortOrder: StructuredOutputControllerFindAllRequestSortOrder? = nil, limit: Double? = nil, createdAtGt: Date? = nil, createdAtLt: Date? = nil, createdAtGe: Date? = nil, createdAtLe: Date? = nil, updatedAtGt: Date? = nil, updatedAtLt: Date? = nil, updatedAtGe: Date? = nil, updatedAtLe: Date? = nil, requestOptions: RequestOptions? = nil) async throws -> StructuredOutputPaginatedResponse { return try await httpClient.performRequest( method: .get, @@ -31,6 +47,9 @@ public final class StructuredOutputsClient: Sendable { ) } + /// Creates a reusable definition for extracting validated data from conversations using an AI model or regular expression. + /// + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func structuredOutputControllerCreate(request: CreateStructuredOutputDto, requestOptions: RequestOptions? = nil) async throws -> StructuredOutput { return try await httpClient.performRequest( method: .post, @@ -41,6 +60,10 @@ public final class StructuredOutputsClient: Sendable { ) } + /// Returns the structured-output definition identified by its ID. + /// + /// - Parameter id: The unique identifier of the structured output. + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func structuredOutputControllerFindOne(id: String, requestOptions: RequestOptions? = nil) async throws -> StructuredOutput { return try await httpClient.performRequest( method: .get, @@ -50,6 +73,10 @@ public final class StructuredOutputsClient: Sendable { ) } + /// Deletes the structured-output definition identified by its ID. + /// + /// - Parameter id: The unique identifier of the structured output. + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func structuredOutputControllerRemove(id: String, requestOptions: RequestOptions? = nil) async throws -> StructuredOutput { return try await httpClient.performRequest( method: .delete, @@ -59,6 +86,11 @@ public final class StructuredOutputsClient: Sendable { ) } + /// Updates the structured-output definition identified by its ID. + /// + /// - Parameter id: The unique identifier of the structured output. + /// - Parameter schemaOverride: Set to the string `true` to allow changing the schema's top-level type. Other values do not enable schema type changes. + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func structuredOutputControllerUpdate(id: String, schemaOverride: String, request: Requests.UpdateStructuredOutputDto, requestOptions: RequestOptions? = nil) async throws -> StructuredOutput { return try await httpClient.performRequest( method: .patch, @@ -72,6 +104,9 @@ public final class StructuredOutputsClient: Sendable { ) } + /// Runs a saved or transient structured-output definition against one or more calls, optionally returning a preview without updating call artifacts. + /// + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func structuredOutputControllerRun(request: Requests.StructuredOutputRunDto, requestOptions: RequestOptions? = nil) async throws -> StructuredOutput { return try await httpClient.performRequest( method: .post, diff --git a/Sources/Resources/Tools/ToolsClient.swift b/Sources/Resources/Tools/ToolsClient.swift index 9dbb028..4a09533 100644 --- a/Sources/Resources/Tools/ToolsClient.swift +++ b/Sources/Resources/Tools/ToolsClient.swift @@ -7,6 +7,18 @@ public final class ToolsClient: Sendable { self.httpClient = HTTPClient(config: config) } + /// Returns reusable tools for the authenticated organization. Filter results by creation or update timestamps and limit the number returned. + /// + /// - Parameter limit: This is the maximum number of items to return. Defaults to 100. + /// - Parameter createdAtGt: This will return items where the createdAt is greater than the specified value. + /// - Parameter createdAtLt: This will return items where the createdAt is less than the specified value. + /// - Parameter createdAtGe: This will return items where the createdAt is greater than or equal to the specified value. + /// - Parameter createdAtLe: This will return items where the createdAt is less than or equal to the specified value. + /// - Parameter updatedAtGt: This will return items where the updatedAt is greater than the specified value. + /// - Parameter updatedAtLt: This will return items where the updatedAt is less than the specified value. + /// - Parameter updatedAtGe: This will return items where the updatedAt is greater than or equal to the specified value. + /// - Parameter updatedAtLe: This will return items where the updatedAt is less than or equal to the specified value. + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func list(limit: Double? = nil, createdAtGt: Date? = nil, createdAtLt: Date? = nil, createdAtGe: Date? = nil, createdAtLe: Date? = nil, updatedAtGt: Date? = nil, updatedAtLt: Date? = nil, updatedAtGe: Date? = nil, updatedAtLe: Date? = nil, requestOptions: RequestOptions? = nil) async throws -> [ListToolsResponseItem] { return try await httpClient.performRequest( method: .get, @@ -27,6 +39,9 @@ public final class ToolsClient: Sendable { ) } + /// Creates a reusable tool that assistants can invoke during conversations. + /// + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func create(request: CreateToolsRequest, requestOptions: RequestOptions? = nil) async throws -> CreateToolsResponse { return try await httpClient.performRequest( method: .post, @@ -37,6 +52,10 @@ public final class ToolsClient: Sendable { ) } + /// Returns the tool identified by its ID. + /// + /// - Parameter id: The unique identifier of the tool. + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func get(id: String, requestOptions: RequestOptions? = nil) async throws -> GetToolsResponse { return try await httpClient.performRequest( method: .get, @@ -46,6 +65,10 @@ public final class ToolsClient: Sendable { ) } + /// Deletes the tool identified by its ID. + /// + /// - Parameter id: The unique identifier of the tool. + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func delete(id: String, requestOptions: RequestOptions? = nil) async throws -> DeleteToolsResponse { return try await httpClient.performRequest( method: .delete, @@ -55,6 +78,10 @@ public final class ToolsClient: Sendable { ) } + /// Updates the specified fields of the tool identified by its ID. + /// + /// - Parameter id: The unique identifier of the tool. + /// - Parameter requestOptions: Additional options for configuring the request, such as custom headers or timeout settings. public func update(id: String, request: UpdateToolsRequestBody, requestOptions: RequestOptions? = nil) async throws -> UpdateToolsResponse { return try await httpClient.performRequest( method: .patch, diff --git a/Sources/Schemas/AiEdgeCondition.swift b/Sources/Schemas/AiEdgeCondition.swift index d0f64fc..1b8df4e 100644 --- a/Sources/Schemas/AiEdgeCondition.swift +++ b/Sources/Schemas/AiEdgeCondition.swift @@ -1,6 +1,8 @@ import Foundation +/// An AI-evaluated boolean condition that determines whether a workflow follows an edge. public struct AiEdgeCondition: Codable, Hashable, Sendable { + /// Selects an AI-evaluated workflow edge condition. public let type: AiEdgeConditionType /// This is the prompt for the AI edge condition. It should evaluate to a boolean. public let prompt: String diff --git a/Sources/Schemas/AiEdgeConditionType.swift b/Sources/Schemas/AiEdgeConditionType.swift index 71c5c59..3a3cf31 100644 --- a/Sources/Schemas/AiEdgeConditionType.swift +++ b/Sources/Schemas/AiEdgeConditionType.swift @@ -1,5 +1,6 @@ import Foundation +/// Selects an AI-evaluated workflow edge condition. public enum AiEdgeConditionType: String, Codable, Hashable, CaseIterable, Sendable { case ai } \ No newline at end of file diff --git a/Sources/Schemas/Analysis.swift b/Sources/Schemas/Analysis.swift index 576c7a9..3fed136 100644 --- a/Sources/Schemas/Analysis.swift +++ b/Sources/Schemas/Analysis.swift @@ -1,5 +1,6 @@ import Foundation +/// Post-call analysis results, including summary, structured data, and success evaluation outputs. public struct Analysis: Codable, Hashable, Sendable { /// This is the summary of the call. Customize by setting `assistant.analysisPlan.summaryPrompt`. public let summary: String? diff --git a/Sources/Schemas/AnalysisCost.swift b/Sources/Schemas/AnalysisCost.swift index 25ae2fb..fbe1631 100644 --- a/Sources/Schemas/AnalysisCost.swift +++ b/Sources/Schemas/AnalysisCost.swift @@ -1,5 +1,6 @@ import Foundation +/// Cost for an individual analysis request, including analysis type, model, token usage, and amount. public struct AnalysisCost: Codable, Hashable, Sendable { /// This is the type of analysis performed. public let analysisType: AnalysisCostAnalysisType diff --git a/Sources/Schemas/AnalysisCostBreakdown.swift b/Sources/Schemas/AnalysisCostBreakdown.swift index b7ed26a..db037f6 100644 --- a/Sources/Schemas/AnalysisCostBreakdown.swift +++ b/Sources/Schemas/AnalysisCostBreakdown.swift @@ -1,5 +1,6 @@ import Foundation +/// Analysis costs and token usage grouped by summary, structured data, success evaluation, and structured-output generation. public struct AnalysisCostBreakdown: Codable, Hashable, Sendable { /// This is the cost to summarize the call. public let summary: Double? diff --git a/Sources/Schemas/AnalysisPlan.swift b/Sources/Schemas/AnalysisPlan.swift index 0ec0ce2..86e01a1 100644 --- a/Sources/Schemas/AnalysisPlan.swift +++ b/Sources/Schemas/AnalysisPlan.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for post-call analysis of summaries, structured-data extraction, success evaluation, and outcomes. public struct AnalysisPlan: Codable, Hashable, Sendable { /// The minimum number of messages required to run the analysis plan. /// If the number of messages is less than this, analysis will be skipped. diff --git a/Sources/Schemas/AnalyticsOperation.swift b/Sources/Schemas/AnalyticsOperation.swift index b7f8c5c..c16e01d 100644 --- a/Sources/Schemas/AnalyticsOperation.swift +++ b/Sources/Schemas/AnalyticsOperation.swift @@ -1,5 +1,6 @@ import Foundation +/// An aggregation or history operation applied to an analytics column, with an optional response alias. public struct AnalyticsOperation: Codable, Hashable, Sendable { /// This is the aggregation operation you want to perform. public let operation: AnalyticsOperationOperation diff --git a/Sources/Schemas/AnalyticsQuery.swift b/Sources/Schemas/AnalyticsQuery.swift index 6470ce1..a610f86 100644 --- a/Sources/Schemas/AnalyticsQuery.swift +++ b/Sources/Schemas/AnalyticsQuery.swift @@ -1,5 +1,6 @@ import Foundation +/// A named analytics query against call or subscription data, including grouping, time range, and aggregation operations. public struct AnalyticsQuery: Codable, Hashable, Sendable { /// This is the table you want to query. public let table: AnalyticsQueryTable diff --git a/Sources/Schemas/AnalyticsQueryResult.swift b/Sources/Schemas/AnalyticsQueryResult.swift index 56c4243..e9453a6 100644 --- a/Sources/Schemas/AnalyticsQueryResult.swift +++ b/Sources/Schemas/AnalyticsQueryResult.swift @@ -1,5 +1,6 @@ import Foundation +/// The result of a named analytics query, including the evaluated time range and returned metric data. public struct AnalyticsQueryResult: Codable, Hashable, Sendable { /// This is the unique key for the query. public let name: String diff --git a/Sources/Schemas/AnthropicBedrockModel.swift b/Sources/Schemas/AnthropicBedrockModel.swift index e625a9f..b46af98 100644 --- a/Sources/Schemas/AnthropicBedrockModel.swift +++ b/Sources/Schemas/AnthropicBedrockModel.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for generating assistant responses with Anthropic models through Amazon Bedrock, including model, prompts, tools, knowledge-base access, reasoning, and generation settings. public struct AnthropicBedrockModel: Codable, Hashable, Sendable { /// This is the starting state for the conversation. public let messages: [OpenAiMessage]? diff --git a/Sources/Schemas/AnthropicModel.swift b/Sources/Schemas/AnthropicModel.swift index 414e336..c1c0125 100644 --- a/Sources/Schemas/AnthropicModel.swift +++ b/Sources/Schemas/AnthropicModel.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for generating assistant responses with Anthropic, including model, prompts, tools, knowledge-base access, reasoning, and generation settings. public struct AnthropicModel: Codable, Hashable, Sendable { /// This is the starting state for the conversation. public let messages: [OpenAiMessage]? diff --git a/Sources/Schemas/AnthropicThinkingConfig.swift b/Sources/Schemas/AnthropicThinkingConfig.swift index 61e1de4..ceb0800 100644 --- a/Sources/Schemas/AnthropicThinkingConfig.swift +++ b/Sources/Schemas/AnthropicThinkingConfig.swift @@ -1,6 +1,8 @@ import Foundation +/// Enables Anthropic extended thinking with a maximum thinking-token budget. public struct AnthropicThinkingConfig: Codable, Hashable, Sendable { + /// Enables Anthropic extended thinking. public let type: AnthropicThinkingConfigType /// The maximum number of tokens to allocate for thinking. /// Must be between 1024 and 100000 tokens. diff --git a/Sources/Schemas/AnthropicThinkingConfigType.swift b/Sources/Schemas/AnthropicThinkingConfigType.swift index 4738bf9..f6ea877 100644 --- a/Sources/Schemas/AnthropicThinkingConfigType.swift +++ b/Sources/Schemas/AnthropicThinkingConfigType.swift @@ -1,5 +1,6 @@ import Foundation +/// Enables Anthropic extended thinking. public enum AnthropicThinkingConfigType: String, Codable, Hashable, CaseIterable, Sendable { case enabled } \ No newline at end of file diff --git a/Sources/Schemas/AnyscaleModel.swift b/Sources/Schemas/AnyscaleModel.swift index e9a9950..2414135 100644 --- a/Sources/Schemas/AnyscaleModel.swift +++ b/Sources/Schemas/AnyscaleModel.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for generating assistant responses with Anyscale, including model, prompts, tools, knowledge-base access, and generation settings. public struct AnyscaleModel: Codable, Hashable, Sendable { /// This is the starting state for the conversation. public let messages: [OpenAiMessage]? diff --git a/Sources/Schemas/ApiRequestTool.swift b/Sources/Schemas/ApiRequestTool.swift index cbd35b8..aa960a4 100644 --- a/Sources/Schemas/ApiRequestTool.swift +++ b/Sources/Schemas/ApiRequestTool.swift @@ -1,10 +1,12 @@ import Foundation +/// A reusable tool that sends HTTP requests to a configured API and can authenticate, retry failures, and extract variables from responses. public struct ApiRequestTool: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// /// For some tools, this is auto-filled based on special fields like `tool.destinations`. For others like the function tool, these can be custom configured. public let messages: [ApiRequestToolMessagesItem]? + /// The HTTP method used for the API request. public let method: ApiRequestToolMethod /// This is the timeout in seconds for the request. Defaults to 20 seconds. /// diff --git a/Sources/Schemas/ApiRequestToolMethod.swift b/Sources/Schemas/ApiRequestToolMethod.swift index 3d16bf1..57d0bd8 100644 --- a/Sources/Schemas/ApiRequestToolMethod.swift +++ b/Sources/Schemas/ApiRequestToolMethod.swift @@ -1,5 +1,6 @@ import Foundation +/// The HTTP method used for the API request. public enum ApiRequestToolMethod: String, Codable, Hashable, CaseIterable, Sendable { case post = "POST" case get = "GET" diff --git a/Sources/Schemas/Artifact.swift b/Sources/Schemas/Artifact.swift index 035161d..8710b26 100644 --- a/Sources/Schemas/Artifact.swift +++ b/Sources/Schemas/Artifact.swift @@ -1,5 +1,6 @@ import Foundation +/// Artifacts generated during a call, including messages, recordings, transcript, logs, packet capture, workflow-node data, variables, performance metrics, structured outputs, scorecards, and transfers. public struct Artifact: Codable, Hashable, Sendable { /// These are the messages that were spoken during the call. public let messages: [ArtifactMessagesItem]? diff --git a/Sources/Schemas/ArtifactPlan.swift b/Sources/Schemas/ArtifactPlan.swift index d9532c1..fda9ab5 100644 --- a/Sources/Schemas/ArtifactPlan.swift +++ b/Sources/Schemas/ArtifactPlan.swift @@ -1,5 +1,6 @@ import Foundation +/// Controls artifacts generated and stored for calls, including recordings, packet captures, logs, transcripts, structured outputs, scorecards, and custom storage paths. public struct ArtifactPlan: Codable, Hashable, Sendable { /// This determines whether assistant's calls are recorded. Defaults to true. /// diff --git a/Sources/Schemas/AssemblyAiTranscriber.swift b/Sources/Schemas/AssemblyAiTranscriber.swift index d01714c..c4f93f0 100644 --- a/Sources/Schemas/AssemblyAiTranscriber.swift +++ b/Sources/Schemas/AssemblyAiTranscriber.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for transcribing speech during assistant conversations with AssemblyAI, including language, streaming model, endpointing, vocabulary, and fallback settings. public struct AssemblyAiTranscriber: Codable, Hashable, Sendable { /// This is the language that will be set for the transcription. public let language: AssemblyAiTranscriberLanguage? diff --git a/Sources/Schemas/Assistant.swift b/Sources/Schemas/Assistant.swift index ef30b53..44a212d 100644 --- a/Sources/Schemas/Assistant.swift +++ b/Sources/Schemas/Assistant.swift @@ -1,5 +1,6 @@ import Foundation +/// A saved assistant configuration returned by the Vapi API. It defines how the assistant listens, reasons, speaks, handles conversations, sends events, and produces artifacts and analysis. public struct Assistant: Codable, Hashable, Sendable { /// These are the options for the assistant's transcriber. public let transcriber: AssistantTranscriber? @@ -11,6 +12,7 @@ public struct Assistant: Codable, Hashable, Sendable { /// /// If unspecified, assistant will wait for user to speak and use the model to respond once they speak. public let firstMessage: String? + /// Set to `true` to allow the user to interrupt the assistant while it speaks the first message. Default is `false`. public let firstMessageInterruptionsEnabled: Bool? /// This is the mode for the first message. Default is 'assistant-speaks-first'. /// @@ -63,6 +65,7 @@ public struct Assistant: Codable, Hashable, Sendable { public let endCallMessage: String? /// This list contains phrases that, if spoken by the assistant, will trigger the call to be hung up. Case insensitive. public let endCallPhrases: [String]? + /// Compliance settings for the assistant, including HIPAA and PCI behavior, security filtering, and recording consent. public let compliancePlan: CompliancePlan? /// This is for metadata you want to store on the assistant. public let metadata: [String: JSONValue]? @@ -115,6 +118,7 @@ public struct Assistant: Codable, Hashable, Sendable { /// 2. phoneNumber.serverUrl /// 3. org.serverUrl public let server: Server? + /// Configuration for collecting and processing DTMF keypad input during calls. public let keypadInputPlan: KeypadInputPlan? /// This is the unique identifier for the assistant. public let id: String diff --git a/Sources/Schemas/AssistantActivation.swift b/Sources/Schemas/AssistantActivation.swift index 985cb95..bc3418e 100644 --- a/Sources/Schemas/AssistantActivation.swift +++ b/Sources/Schemas/AssistantActivation.swift @@ -1,5 +1,6 @@ import Foundation +/// Identifies an assistant that became active during a call. public struct AssistantActivation: Codable, Hashable, Sendable { /// This is the name of the assistant that was active during the call. public let assistantName: String diff --git a/Sources/Schemas/AssistantCustomEndpointingRule.swift b/Sources/Schemas/AssistantCustomEndpointingRule.swift index 96729d1..fd2fa24 100644 --- a/Sources/Schemas/AssistantCustomEndpointingRule.swift +++ b/Sources/Schemas/AssistantCustomEndpointingRule.swift @@ -1,5 +1,6 @@ import Foundation +/// A custom endpointing rule that matches the assistant's last message and applies a configured timeout. public struct AssistantCustomEndpointingRule: Codable, Hashable, Sendable { /// This is the regex pattern to match. /// diff --git a/Sources/Schemas/AssistantMessage.swift b/Sources/Schemas/AssistantMessage.swift index 1592a89..48dc4c1 100644 --- a/Sources/Schemas/AssistantMessage.swift +++ b/Sources/Schemas/AssistantMessage.swift @@ -1,5 +1,6 @@ import Foundation +/// An assistant-authored message, including content, refusal text, tool calls, participant name, and metadata. public struct AssistantMessage: Codable, Hashable, Sendable { /// This is the role of the message author public let role: AssistantMessageRole diff --git a/Sources/Schemas/AssistantMessageEvaluationContinuePlan.swift b/Sources/Schemas/AssistantMessageEvaluationContinuePlan.swift index be93bab..2fe5741 100644 --- a/Sources/Schemas/AssistantMessageEvaluationContinuePlan.swift +++ b/Sources/Schemas/AssistantMessageEvaluationContinuePlan.swift @@ -1,5 +1,6 @@ import Foundation +/// Controls how an evaluation proceeds after judging an assistant message, including failure handling and optional message overrides. public struct AssistantMessageEvaluationContinuePlan: Codable, Hashable, Sendable { /// This is whether the evaluation should exit if the assistant message evaluates to false. /// By default, it is false and the evaluation will continue. diff --git a/Sources/Schemas/AssistantMessageJudgePlanAi.swift b/Sources/Schemas/AssistantMessageJudgePlanAi.swift index 33d35f0..7eeace5 100644 --- a/Sources/Schemas/AssistantMessageJudgePlanAi.swift +++ b/Sources/Schemas/AssistantMessageJudgePlanAi.swift @@ -1,5 +1,6 @@ import Foundation +/// Evaluates an assistant message with an LLM judge and a configured evaluation model. public struct AssistantMessageJudgePlanAi: Codable, Hashable, Sendable { /// This is the model to use for the LLM-as-a-judge. /// If not provided, will default to the assistant's model. diff --git a/Sources/Schemas/AssistantMessageJudgePlanExact.swift b/Sources/Schemas/AssistantMessageJudgePlanExact.swift index d1c6d6f..5889e54 100644 --- a/Sources/Schemas/AssistantMessageJudgePlanExact.swift +++ b/Sources/Schemas/AssistantMessageJudgePlanExact.swift @@ -1,5 +1,6 @@ import Foundation +/// Evaluates an assistant message using case-insensitive exact content matching and expected tool calls. public struct AssistantMessageJudgePlanExact: Codable, Hashable, Sendable { /// This is what that will be used to evaluate the model's message content. /// If you provide a string, the assistant message content will be evaluated against it as an exact match, case-insensitive. diff --git a/Sources/Schemas/AssistantMessageJudgePlanRegex.swift b/Sources/Schemas/AssistantMessageJudgePlanRegex.swift index bdb5e60..fd54cb2 100644 --- a/Sources/Schemas/AssistantMessageJudgePlanRegex.swift +++ b/Sources/Schemas/AssistantMessageJudgePlanRegex.swift @@ -1,5 +1,6 @@ import Foundation +/// Evaluates assistant-message content and tool-call arguments using regular-expression patterns. public struct AssistantMessageJudgePlanRegex: Codable, Hashable, Sendable { /// This is what that will be used to evaluate the model's message content. /// The content will be evaluated against the regex pattern provided in the Judge Plan content field. diff --git a/Sources/Schemas/AssistantOverrides.swift b/Sources/Schemas/AssistantOverrides.swift index 3ff03dc..510b3ef 100644 --- a/Sources/Schemas/AssistantOverrides.swift +++ b/Sources/Schemas/AssistantOverrides.swift @@ -1,5 +1,6 @@ import Foundation +/// Per-call or handoff overrides for an assistant's providers, messages, tools, credentials, call behavior, and server configuration. public struct AssistantOverrides: Codable, Hashable, Sendable { /// These are the options for the assistant's transcriber. public let transcriber: AssistantOverridesTranscriber? @@ -11,6 +12,7 @@ public struct AssistantOverrides: Codable, Hashable, Sendable { /// /// If unspecified, assistant will wait for user to speak and use the model to respond once they speak. public let firstMessage: String? + /// Set to `true` to allow the user to interrupt the assistant while it speaks the first message. Default is `false`. public let firstMessageInterruptionsEnabled: Bool? /// This is the mode for the first message. Default is 'assistant-speaks-first'. /// @@ -49,6 +51,7 @@ public struct AssistantOverrides: Codable, Hashable, Sendable { public let credentials: [AssistantOverridesCredentialsItem]? /// This is a set of actions that will be performed on certain events. public let hooks: [AssistantOverridesHooksItem]? + /// Tools to append to the assistant's existing tool configuration. public let toolsAppend: [AssistantOverridesToolsAppendItem]? /// These are values that will be used to replace the template variables in the assistant messages and other text-based fields. /// This uses LiquidJS syntax. https://liquidjs.com/tutorials/intro-to-liquid.html @@ -72,6 +75,7 @@ public struct AssistantOverrides: Codable, Hashable, Sendable { public let endCallMessage: String? /// This list contains phrases that, if spoken by the assistant, will trigger the call to be hung up. Case insensitive. public let endCallPhrases: [String]? + /// Compliance settings to apply, including HIPAA and PCI behavior, security filtering, and recording consent. public let compliancePlan: CompliancePlan? /// This is for metadata you want to store on the assistant. public let metadata: [String: JSONValue]? @@ -124,6 +128,7 @@ public struct AssistantOverrides: Codable, Hashable, Sendable { /// 2. phoneNumber.serverUrl /// 3. org.serverUrl public let server: Server? + /// Configuration for collecting and processing DTMF keypad input. public let keypadInputPlan: KeypadInputPlan? /// Additional properties that are not explicitly defined in the schema public let additionalProperties: [String: JSONValue] diff --git a/Sources/Schemas/AwsStsAuthenticationPlan.swift b/Sources/Schemas/AwsStsAuthenticationPlan.swift index 3c8ff4d..c2e6c98 100644 --- a/Sources/Schemas/AwsStsAuthenticationPlan.swift +++ b/Sources/Schemas/AwsStsAuthenticationPlan.swift @@ -1,5 +1,6 @@ import Foundation +/// AWS Security Token Service role-assumption configuration used to authenticate requests. public struct AwsStsAuthenticationPlan: Codable, Hashable, Sendable { /// This is the role ARN for the AWS credential public let roleArn: String diff --git a/Sources/Schemas/AwsiamCredentialsAuthenticationPlan.swift b/Sources/Schemas/AwsiamCredentialsAuthenticationPlan.swift index 78b167b..4eeee39 100644 --- a/Sources/Schemas/AwsiamCredentialsAuthenticationPlan.swift +++ b/Sources/Schemas/AwsiamCredentialsAuthenticationPlan.swift @@ -1,5 +1,6 @@ import Foundation +/// Direct AWS IAM credentials used to authenticate requests. public struct AwsiamCredentialsAuthenticationPlan: Codable, Hashable, Sendable { /// AWS Access Key ID. This is not returned in the API. public let awsAccessKeyId: String diff --git a/Sources/Schemas/AzureBlobStorageBucketPlan.swift b/Sources/Schemas/AzureBlobStorageBucketPlan.swift index 51cb3ab..3f35171 100644 --- a/Sources/Schemas/AzureBlobStorageBucketPlan.swift +++ b/Sources/Schemas/AzureBlobStorageBucketPlan.swift @@ -1,5 +1,6 @@ import Foundation +/// Azure Blob Storage container configuration for call artifacts, including its connection string, container name, and storage path. public struct AzureBlobStorageBucketPlan: Codable, Hashable, Sendable { /// This is the blob storage connection string for the Azure resource. public let connectionString: String diff --git a/Sources/Schemas/AzureSpeechTranscriber.swift b/Sources/Schemas/AzureSpeechTranscriber.swift index 3e21e08..5f80ab6 100644 --- a/Sources/Schemas/AzureSpeechTranscriber.swift +++ b/Sources/Schemas/AzureSpeechTranscriber.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for transcribing speech during assistant conversations with Azure Speech, including language, segmentation, and fallback settings. public struct AzureSpeechTranscriber: Codable, Hashable, Sendable { /// This is the language that will be set for the transcription. The list of languages Azure supports can be found here: https://learn.microsoft.com/en-us/azure/ai-services/speech-service/language-support?tabs=stt public let language: AzureSpeechTranscriberLanguage? diff --git a/Sources/Schemas/AzureVoice.swift b/Sources/Schemas/AzureVoice.swift index c1ac304..c6004a9 100644 --- a/Sources/Schemas/AzureVoice.swift +++ b/Sources/Schemas/AzureVoice.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for synthesizing assistant speech with Azure, including voice selection, speed, chunking, caching, and fallback settings. public struct AzureVoice: Codable, Hashable, Sendable { /// This is the flag to toggle voice caching for the assistant. public let cachingEnabled: Bool? diff --git a/Sources/Schemas/BackgroundSpeechDenoisingPlan.swift b/Sources/Schemas/BackgroundSpeechDenoisingPlan.swift index e2ff972..173250f 100644 --- a/Sources/Schemas/BackgroundSpeechDenoisingPlan.swift +++ b/Sources/Schemas/BackgroundSpeechDenoisingPlan.swift @@ -1,5 +1,6 @@ import Foundation +/// Controls smart and Fourier denoising applied to customer audio before transcription. public struct BackgroundSpeechDenoisingPlan: Codable, Hashable, Sendable { /// Whether smart denoising using Krisp is enabled. public let smartDenoisingPlan: SmartDenoisingPlan? diff --git a/Sources/Schemas/BackoffPlan.swift b/Sources/Schemas/BackoffPlan.swift index 3a18444..75d7fdd 100644 --- a/Sources/Schemas/BackoffPlan.swift +++ b/Sources/Schemas/BackoffPlan.swift @@ -1,5 +1,6 @@ import Foundation +/// Controls retry behavior for failed server requests, including strategy, maximum retries, base delay, and status codes excluded from retries. public struct BackoffPlan: Codable, Hashable, Sendable { /// This is the type of backoff plan to use. Defaults to fixed. /// @@ -9,10 +10,9 @@ public struct BackoffPlan: Codable, Hashable, Sendable { /// /// @default 0 public let maxRetries: Double - /// This is the base delay in seconds. For linear backoff, this is the delay between each retry. For exponential backoff, this is the initial delay. + /// Base delay in seconds. For fixed backoff, this is the delay between retries. For exponential backoff, this is the initial delay. public let baseDelaySeconds: Double - /// This is the excluded status codes. If the response status code is in this list, the request will not be retried. - /// By default, the request will be retried for any non-2xx status code. + /// HTTP status codes that should not trigger a retry. By default, any non-2xx status code not listed here can be retried. public let excludedStatusCodes: [[String: JSONValue]]? /// Additional properties that are not explicitly defined in the schema public let additionalProperties: [String: JSONValue] diff --git a/Sources/Schemas/BarInsight.swift b/Sources/Schemas/BarInsight.swift index 80826bb..14d86ea 100644 --- a/Sources/Schemas/BarInsight.swift +++ b/Sources/Schemas/BarInsight.swift @@ -1,5 +1,6 @@ import Foundation +/// A saved bar-chart insight containing its call-data queries, formulas, grouping, stepped time range, metadata, and lifecycle information. public struct BarInsight: Codable, Hashable, Sendable { /// This is the name of the Insight. public let name: String? @@ -21,6 +22,7 @@ public struct BarInsight: Codable, Hashable, Sendable { public let formulas: [InsightFormula]? /// This is the metadata for the insight. public let metadata: BarInsightMetadata? + /// The time range and interval used to aggregate the bar-chart data. public let timeRange: InsightTimeRangeWithStep? /// This is the group by column for the insight when table is `call`. /// These are the columns to group the results by. diff --git a/Sources/Schemas/BarInsightMetadata.swift b/Sources/Schemas/BarInsightMetadata.swift index d98b620..ebe43c2 100644 --- a/Sources/Schemas/BarInsightMetadata.swift +++ b/Sources/Schemas/BarInsightMetadata.swift @@ -1,10 +1,16 @@ import Foundation +/// Display settings for a bar insight, including chart name, axis labels, and optional y-axis bounds. public struct BarInsightMetadata: Codable, Hashable, Sendable { + /// Label displayed on the chart's x-axis. public let xAxisLabel: String? + /// Label displayed on the chart's y-axis. public let yAxisLabel: String? + /// Minimum value displayed on the chart's y-axis. public let yAxisMin: Double? + /// Maximum value displayed on the chart's y-axis. public let yAxisMax: Double? + /// Display name for the insight chart. public let name: String? /// Additional properties that are not explicitly defined in the schema public let additionalProperties: [String: JSONValue] diff --git a/Sources/Schemas/BashTool.swift b/Sources/Schemas/BashTool.swift index b43fac6..f4905f4 100644 --- a/Sources/Schemas/BashTool.swift +++ b/Sources/Schemas/BashTool.swift @@ -1,5 +1,6 @@ import Foundation +/// A reusable tool that executes shell commands in a configured environment. public struct BashTool: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/BearerAuthenticationPlan.swift b/Sources/Schemas/BearerAuthenticationPlan.swift index 01b48e5..ddb6b9a 100644 --- a/Sources/Schemas/BearerAuthenticationPlan.swift +++ b/Sources/Schemas/BearerAuthenticationPlan.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for authenticating outbound requests with a bearer token, including header name and optional `Bearer` prefix. public struct BearerAuthenticationPlan: Codable, Hashable, Sendable { /// This is the bearer token value. public let token: String diff --git a/Sources/Schemas/BotMessage.swift b/Sources/Schemas/BotMessage.swift index eac3312..2f0cf05 100644 --- a/Sources/Schemas/BotMessage.swift +++ b/Sources/Schemas/BotMessage.swift @@ -1,5 +1,6 @@ import Foundation +/// An assistant-authored entry in the call message history, including content, timing, source, and duration. public struct BotMessage: Codable, Hashable, Sendable { /// The role of the bot in the conversation. public let role: String diff --git a/Sources/Schemas/BothCustomEndpointingRule.swift b/Sources/Schemas/BothCustomEndpointingRule.swift index e9d992a..01520f4 100644 --- a/Sources/Schemas/BothCustomEndpointingRule.swift +++ b/Sources/Schemas/BothCustomEndpointingRule.swift @@ -1,5 +1,6 @@ import Foundation +/// A custom endpointing rule that matches both the assistant's last message and the customer's current speech before applying a configured timeout. public struct BothCustomEndpointingRule: Codable, Hashable, Sendable { /// This is the regex pattern to match the assistant's message. /// @@ -14,6 +15,7 @@ public struct BothCustomEndpointingRule: Codable, Hashable, Sendable { /// /// @default [] public let assistantRegexOptions: [RegexOption]? + /// The regular expression pattern matched against the customer's speech. public let customerRegex: String /// These are the options for the customer's message regex match. Defaults to all disabled. /// diff --git a/Sources/Schemas/BucketPlan.swift b/Sources/Schemas/BucketPlan.swift index a3f6214..5be74d4 100644 --- a/Sources/Schemas/BucketPlan.swift +++ b/Sources/Schemas/BucketPlan.swift @@ -1,5 +1,6 @@ import Foundation +/// Google Cloud Storage bucket configuration for call artifacts, including bucket name, region, path, and optional HMAC credentials. public struct BucketPlan: Codable, Hashable, Sendable { /// This is the name of the bucket. public let name: String diff --git a/Sources/Schemas/ByoPhoneNumber.swift b/Sources/Schemas/ByoPhoneNumber.swift index 3026f46..3182f93 100644 --- a/Sources/Schemas/ByoPhoneNumber.swift +++ b/Sources/Schemas/ByoPhoneNumber.swift @@ -1,5 +1,6 @@ import Foundation +/// A phone number connected to Vapi through a bring-your-own telephony provider, including its credential, routing, hooks, server settings, and lifecycle metadata. public struct ByoPhoneNumber: Codable, Hashable, Sendable { /// This is the fallback destination an inbound call will be transferred to if: /// 1. `assistantId` is not set diff --git a/Sources/Schemas/Call.swift b/Sources/Schemas/Call.swift index 32cae0c..9af89b7 100644 --- a/Sources/Schemas/Call.swift +++ b/Sources/Schemas/Call.swift @@ -1,10 +1,12 @@ import Foundation +/// A call record returned by Vapi. It contains the configuration and resources used for the call, its lifecycle status and timestamps, conversation messages, artifacts, analysis, and costs. public struct Call: Codable, Hashable, Sendable { /// This is the type of call. public let type: CallType? /// These are the costs of individual components of the call in USD. public let costs: [CallCostsItem]? + /// Messages exchanged during the call, including user, assistant, system, tool-call, and tool-result messages. public let messages: [CallMessagesItem]? /// This is the provider of the call. /// diff --git a/Sources/Schemas/CallBatchError.swift b/Sources/Schemas/CallBatchError.swift index cda37cf..4769038 100644 --- a/Sources/Schemas/CallBatchError.swift +++ b/Sources/Schemas/CallBatchError.swift @@ -1,7 +1,10 @@ import Foundation +/// Error returned for one customer entry in a batch call request. public struct CallBatchError: Codable, Hashable, Sendable { + /// Customer configuration associated with the failed call. public let customer: CreateCustomerDto + /// Error message explaining why the call could not be created. public let error: String /// Additional properties that are not explicitly defined in the schema public let additionalProperties: [String: JSONValue] diff --git a/Sources/Schemas/CallBatchResponse.swift b/Sources/Schemas/CallBatchResponse.swift index bc58f29..1df33f2 100644 --- a/Sources/Schemas/CallBatchResponse.swift +++ b/Sources/Schemas/CallBatchResponse.swift @@ -1,5 +1,6 @@ import Foundation +/// The result of a batch call creation request, containing successfully created calls, per-call failures, and subscription limits recorded at the end of the batch. public struct CallBatchResponse: Codable, Hashable, Sendable { /// Subscription limits at the end of this batch public let subscriptionLimits: SubscriptionLimits? diff --git a/Sources/Schemas/CallHookAssistantSpeechInterrupted.swift b/Sources/Schemas/CallHookAssistantSpeechInterrupted.swift index f15d353..c961ebe 100644 --- a/Sources/Schemas/CallHookAssistantSpeechInterrupted.swift +++ b/Sources/Schemas/CallHookAssistantSpeechInterrupted.swift @@ -1,5 +1,6 @@ import Foundation +/// Runs configured actions when the customer's speech interrupts the assistant. public struct CallHookAssistantSpeechInterrupted: Codable, Hashable, Sendable { /// This is the event that triggers this hook public let on: CallHookAssistantSpeechInterruptedOn diff --git a/Sources/Schemas/CallHookCallEnding.swift b/Sources/Schemas/CallHookCallEnding.swift index 106c541..4e177c1 100644 --- a/Sources/Schemas/CallHookCallEnding.swift +++ b/Sources/Schemas/CallHookCallEnding.swift @@ -1,5 +1,6 @@ import Foundation +/// Runs configured actions when a call is ending, optionally only when its filters match. public struct CallHookCallEnding: Codable, Hashable, Sendable { /// This is the event that triggers this hook public let on: CallHookCallEndingOn diff --git a/Sources/Schemas/CallHookCustomerSpeechInterrupted.swift b/Sources/Schemas/CallHookCustomerSpeechInterrupted.swift index 8379f07..ca61972 100644 --- a/Sources/Schemas/CallHookCustomerSpeechInterrupted.swift +++ b/Sources/Schemas/CallHookCustomerSpeechInterrupted.swift @@ -1,5 +1,6 @@ import Foundation +/// Runs configured actions when the assistant interrupts the customer's speech. public struct CallHookCustomerSpeechInterrupted: Codable, Hashable, Sendable { /// This is the event that triggers this hook public let on: CallHookCustomerSpeechInterruptedOn diff --git a/Sources/Schemas/CallHookCustomerSpeechTimeout.swift b/Sources/Schemas/CallHookCustomerSpeechTimeout.swift index 48bffbe..3184e43 100644 --- a/Sources/Schemas/CallHookCustomerSpeechTimeout.swift +++ b/Sources/Schemas/CallHookCustomerSpeechTimeout.swift @@ -1,11 +1,12 @@ import Foundation +/// Runs configured actions when the customer does not speak before the configured timeout, with support for trigger limits and named instances. public struct CallHookCustomerSpeechTimeout: Codable, Hashable, Sendable { /// Must be either "customer.speech.timeout" or match the pattern "customer.speech.timeout[property=value]" public let on: String /// This is the set of actions to perform when the hook triggers public let `do`: [CallHookCustomerSpeechTimeoutDoItem] - /// This is the set of filters that must match for the hook to trigger + /// Controls the speech timeout, maximum trigger count, and counter reset behavior for this hook. public let options: CustomerSpeechTimeoutOptions? /// This is the name of the hook, it can be set by the user to identify the hook. /// If no name is provided, the hook will be auto generated as UUID. diff --git a/Sources/Schemas/CallHookFilter.swift b/Sources/Schemas/CallHookFilter.swift index 4f54460..d01b1fd 100644 --- a/Sources/Schemas/CallHookFilter.swift +++ b/Sources/Schemas/CallHookFilter.swift @@ -1,5 +1,6 @@ import Foundation +/// Matches a call field against one or more allowed values to determine whether a hook runs. public struct CallHookFilter: Codable, Hashable, Sendable { /// This is the type of filter - currently only "oneOf" is supported public let type: CallHookFilterType diff --git a/Sources/Schemas/CallHookModelResponseTimeout.swift b/Sources/Schemas/CallHookModelResponseTimeout.swift index 4065077..689b43f 100644 --- a/Sources/Schemas/CallHookModelResponseTimeout.swift +++ b/Sources/Schemas/CallHookModelResponseTimeout.swift @@ -1,5 +1,6 @@ import Foundation +/// Runs configured actions when the language model does not respond before its timeout. public struct CallHookModelResponseTimeout: Codable, Hashable, Sendable { /// This is the event that triggers this hook public let on: CallHookModelResponseTimeoutOn diff --git a/Sources/Schemas/Campaign.swift b/Sources/Schemas/Campaign.swift index 8df5032..6c13ba0 100644 --- a/Sources/Schemas/Campaign.swift +++ b/Sources/Schemas/Campaign.swift @@ -1,5 +1,6 @@ import Foundation +/// A saved outbound calling campaign, including its calling configuration, schedule, status, customers, calls, and call-progress counters. public struct Campaign: Codable, Hashable, Sendable { /// This is the status of the campaign. public let status: CampaignStatus diff --git a/Sources/Schemas/CampaignPaginatedResponse.swift b/Sources/Schemas/CampaignPaginatedResponse.swift index d34eae1..d7a39d4 100644 --- a/Sources/Schemas/CampaignPaginatedResponse.swift +++ b/Sources/Schemas/CampaignPaginatedResponse.swift @@ -1,7 +1,10 @@ import Foundation +/// A paginated collection of outbound calling campaigns and metadata describing the result set. public struct CampaignPaginatedResponse: Codable, Hashable, Sendable { + /// The campaigns returned for the current page. public let results: [Campaign] + /// Pagination metadata for the campaign result set. public let metadata: PaginationMeta /// Additional properties that are not explicitly defined in the schema public let additionalProperties: [String: JSONValue] diff --git a/Sources/Schemas/CartesiaExperimentalControls.swift b/Sources/Schemas/CartesiaExperimentalControls.swift index c3e63da..4eac021 100644 --- a/Sources/Schemas/CartesiaExperimentalControls.swift +++ b/Sources/Schemas/CartesiaExperimentalControls.swift @@ -1,7 +1,10 @@ import Foundation +/// Cartesia voice controls for speed and emotion. public struct CartesiaExperimentalControls: Codable, Hashable, Sendable { + /// Speaking-speed control expressed as a preset or a value from -1 to 1. public let speed: CartesiaSpeedControl? + /// Emotion and intensity applied to the Cartesia voice. public let emotion: CartesiaExperimentalControlsEmotion? /// Additional properties that are not explicitly defined in the schema public let additionalProperties: [String: JSONValue] diff --git a/Sources/Schemas/CartesiaExperimentalControlsEmotion.swift b/Sources/Schemas/CartesiaExperimentalControlsEmotion.swift index 45f4b30..a671b7f 100644 --- a/Sources/Schemas/CartesiaExperimentalControlsEmotion.swift +++ b/Sources/Schemas/CartesiaExperimentalControlsEmotion.swift @@ -1,5 +1,6 @@ import Foundation +/// Emotion and intensity applied to the Cartesia voice. public enum CartesiaExperimentalControlsEmotion: String, Codable, Hashable, CaseIterable, Sendable { case angerLowest = "anger:lowest" case angerLow = "anger:low" diff --git a/Sources/Schemas/CartesiaGenerationConfig.swift b/Sources/Schemas/CartesiaGenerationConfig.swift index 65da02d..369c5d8 100644 --- a/Sources/Schemas/CartesiaGenerationConfig.swift +++ b/Sources/Schemas/CartesiaGenerationConfig.swift @@ -1,5 +1,6 @@ import Foundation +/// Generation controls for Cartesia Sonic 3 voices, including speed, volume, and accent localization. public struct CartesiaGenerationConfig: Codable, Hashable, Sendable { /// Fine-grained speed control for sonic-3. Only available for sonic-3 model. public let speed: Double? diff --git a/Sources/Schemas/CartesiaGenerationConfigExperimental.swift b/Sources/Schemas/CartesiaGenerationConfigExperimental.swift index b3450ff..7580c4e 100644 --- a/Sources/Schemas/CartesiaGenerationConfigExperimental.swift +++ b/Sources/Schemas/CartesiaGenerationConfigExperimental.swift @@ -1,5 +1,6 @@ import Foundation +/// Cartesia Sonic 3 generation controls, including accent localization. public struct CartesiaGenerationConfigExperimental: Codable, Hashable, Sendable { /// Toggle accent localization for sonic-3: 0 (disabled, default) or 1 (enabled). When enabled, the voice adapts to match the transcript language accent while preserving vocal characteristics. public let accentLocalization: Int? diff --git a/Sources/Schemas/CartesiaSpeedControl.swift b/Sources/Schemas/CartesiaSpeedControl.swift index 0f76952..122000c 100644 --- a/Sources/Schemas/CartesiaSpeedControl.swift +++ b/Sources/Schemas/CartesiaSpeedControl.swift @@ -1,5 +1,6 @@ import Foundation +/// Speaking-speed control expressed as a preset or a value from -1 to 1. public enum CartesiaSpeedControl: Codable, Hashable, Sendable { case cartesiaSpeedControlZero(CartesiaSpeedControlZero) case double(Double) diff --git a/Sources/Schemas/CartesiaTranscriber.swift b/Sources/Schemas/CartesiaTranscriber.swift index d6a148e..b176d09 100644 --- a/Sources/Schemas/CartesiaTranscriber.swift +++ b/Sources/Schemas/CartesiaTranscriber.swift @@ -1,7 +1,10 @@ import Foundation +/// Configuration for transcribing speech during assistant conversations with Cartesia, including model, language, and fallback settings. public struct CartesiaTranscriber: Codable, Hashable, Sendable { + /// The Cartesia speech-to-text model used for transcription. public let model: CartesiaTranscriberModel? + /// The language code used for transcription. public let language: CartesiaTranscriberLanguage? /// This is the plan for transcriber provider fallbacks in the event that the primary transcriber provider fails. public let fallbackPlan: FallbackTranscriberPlan? diff --git a/Sources/Schemas/CartesiaTranscriberLanguage.swift b/Sources/Schemas/CartesiaTranscriberLanguage.swift index 5dabf21..c52a272 100644 --- a/Sources/Schemas/CartesiaTranscriberLanguage.swift +++ b/Sources/Schemas/CartesiaTranscriberLanguage.swift @@ -1,5 +1,6 @@ import Foundation +/// The language code used for transcription. public enum CartesiaTranscriberLanguage: String, Codable, Hashable, CaseIterable, Sendable { case aa case ab diff --git a/Sources/Schemas/CartesiaTranscriberModel.swift b/Sources/Schemas/CartesiaTranscriberModel.swift index 301c8fc..d50231f 100644 --- a/Sources/Schemas/CartesiaTranscriberModel.swift +++ b/Sources/Schemas/CartesiaTranscriberModel.swift @@ -1,5 +1,6 @@ import Foundation +/// The Cartesia speech-to-text model used for transcription. public enum CartesiaTranscriberModel: String, Codable, Hashable, CaseIterable, Sendable { case inkWhisper = "ink-whisper" } \ No newline at end of file diff --git a/Sources/Schemas/CartesiaVoice.swift b/Sources/Schemas/CartesiaVoice.swift index 789aa69..fcc6e0b 100644 --- a/Sources/Schemas/CartesiaVoice.swift +++ b/Sources/Schemas/CartesiaVoice.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for synthesizing assistant speech with Cartesia, including voice and model selection, language, generation controls, pronunciation dictionaries, chunking, caching, and fallback settings. public struct CartesiaVoice: Codable, Hashable, Sendable { /// This is the flag to toggle voice caching for the assistant. public let cachingEnabled: Bool? diff --git a/Sources/Schemas/CerebrasModel.swift b/Sources/Schemas/CerebrasModel.swift index 002b558..d3ee435 100644 --- a/Sources/Schemas/CerebrasModel.swift +++ b/Sources/Schemas/CerebrasModel.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for generating assistant responses with Cerebras, including model, prompts, tools, knowledge-base access, and generation settings. public struct CerebrasModel: Codable, Hashable, Sendable { /// This is the starting state for the conversation. public let messages: [OpenAiMessage]? diff --git a/Sources/Schemas/ChatEvalAssistantMessageEvaluation.swift b/Sources/Schemas/ChatEvalAssistantMessageEvaluation.swift index 1a3b422..13a4bfd 100644 --- a/Sources/Schemas/ChatEvalAssistantMessageEvaluation.swift +++ b/Sources/Schemas/ChatEvalAssistantMessageEvaluation.swift @@ -1,5 +1,6 @@ import Foundation +/// An expected assistant turn in an evaluation, including the judge plan and how the evaluation should continue afterward. public struct ChatEvalAssistantMessageEvaluation: Codable, Hashable, Sendable { /// This is the role of the message author. /// For an assistant message evaluation, the role is always 'assistant' diff --git a/Sources/Schemas/ChatEvalAssistantMessageMock.swift b/Sources/Schemas/ChatEvalAssistantMessageMock.swift index cd7aab2..7fe09bd 100644 --- a/Sources/Schemas/ChatEvalAssistantMessageMock.swift +++ b/Sources/Schemas/ChatEvalAssistantMessageMock.swift @@ -1,5 +1,6 @@ import Foundation +/// A simulated assistant turn in an evaluation conversation, with optional message content and tool calls. public struct ChatEvalAssistantMessageMock: Codable, Hashable, Sendable { /// This is the role of the message author. /// For a mock assistant message, the role is always 'assistant' diff --git a/Sources/Schemas/ChatEvalAssistantMessageMockToolCall.swift b/Sources/Schemas/ChatEvalAssistantMessageMockToolCall.swift index cbcc2f8..cd365b4 100644 --- a/Sources/Schemas/ChatEvalAssistantMessageMockToolCall.swift +++ b/Sources/Schemas/ChatEvalAssistantMessageMockToolCall.swift @@ -1,5 +1,6 @@ import Foundation +/// A simulated assistant tool call with the tool name and optional arguments. public struct ChatEvalAssistantMessageMockToolCall: Codable, Hashable, Sendable { /// This is the name of the tool that will be called. /// It should be one of the tools created in the organization. diff --git a/Sources/Schemas/ChatEvalSystemMessageMock.swift b/Sources/Schemas/ChatEvalSystemMessageMock.swift index 5e4269a..159034b 100644 --- a/Sources/Schemas/ChatEvalSystemMessageMock.swift +++ b/Sources/Schemas/ChatEvalSystemMessageMock.swift @@ -1,5 +1,6 @@ import Foundation +/// A simulated system message in an evaluation conversation. public struct ChatEvalSystemMessageMock: Codable, Hashable, Sendable { /// This is the role of the message author. /// For a mock system message, the role is always 'system' diff --git a/Sources/Schemas/ChatEvalToolResponseMessageEvaluation.swift b/Sources/Schemas/ChatEvalToolResponseMessageEvaluation.swift index 1af9302..b57990e 100644 --- a/Sources/Schemas/ChatEvalToolResponseMessageEvaluation.swift +++ b/Sources/Schemas/ChatEvalToolResponseMessageEvaluation.swift @@ -1,5 +1,6 @@ import Foundation +/// An expected tool-response turn evaluated by a configured LLM judge. public struct ChatEvalToolResponseMessageEvaluation: Codable, Hashable, Sendable { /// This is the role of the message author. /// For a tool response message evaluation, the role is always 'tool' diff --git a/Sources/Schemas/ChatEvalToolResponseMessageMock.swift b/Sources/Schemas/ChatEvalToolResponseMessageMock.swift index 8f9c4ef..bfaf7da 100644 --- a/Sources/Schemas/ChatEvalToolResponseMessageMock.swift +++ b/Sources/Schemas/ChatEvalToolResponseMessageMock.swift @@ -1,5 +1,6 @@ import Foundation +/// A simulated tool response in an evaluation conversation. public struct ChatEvalToolResponseMessageMock: Codable, Hashable, Sendable { /// This is the role of the message author. /// For a mock tool response message, the role is always 'tool' diff --git a/Sources/Schemas/ChatEvalUserMessageMock.swift b/Sources/Schemas/ChatEvalUserMessageMock.swift index 578f1be..7b68255 100644 --- a/Sources/Schemas/ChatEvalUserMessageMock.swift +++ b/Sources/Schemas/ChatEvalUserMessageMock.swift @@ -1,5 +1,6 @@ import Foundation +/// A simulated user message in an evaluation conversation. public struct ChatEvalUserMessageMock: Codable, Hashable, Sendable { /// This is the role of the message author. /// For a mock user message, the role is always 'user' diff --git a/Sources/Schemas/ChunkPlan.swift b/Sources/Schemas/ChunkPlan.swift index bd6e060..acd54c4 100644 --- a/Sources/Schemas/ChunkPlan.swift +++ b/Sources/Schemas/ChunkPlan.swift @@ -1,5 +1,6 @@ import Foundation +/// Controls how model output is split into chunks before voice synthesis, including minimum length, punctuation boundaries, and formatting. public struct ChunkPlan: Codable, Hashable, Sendable { /// This determines whether the model output is chunked before being sent to the voice provider. Default `true`. /// diff --git a/Sources/Schemas/CloudflareR2BucketPlan.swift b/Sources/Schemas/CloudflareR2BucketPlan.swift index 9918881..565c029 100644 --- a/Sources/Schemas/CloudflareR2BucketPlan.swift +++ b/Sources/Schemas/CloudflareR2BucketPlan.swift @@ -1,5 +1,6 @@ import Foundation +/// Cloudflare R2 bucket configuration for call-artifact storage, including access keys, base URL, bucket name, and path. public struct CloudflareR2BucketPlan: Codable, Hashable, Sendable { /// Cloudflare R2 Access key ID. public let accessKeyId: String? diff --git a/Sources/Schemas/CodeTool.swift b/Sources/Schemas/CodeTool.swift index be2e4b4..76a39b6 100644 --- a/Sources/Schemas/CodeTool.swift +++ b/Sources/Schemas/CodeTool.swift @@ -1,5 +1,6 @@ import Foundation +/// A reusable tool that executes TypeScript code with configured credentials, environment variables, and timeout. public struct CodeTool: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/CodeToolEnvironmentVariable.swift b/Sources/Schemas/CodeToolEnvironmentVariable.swift index ecbc75a..5c71076 100644 --- a/Sources/Schemas/CodeToolEnvironmentVariable.swift +++ b/Sources/Schemas/CodeToolEnvironmentVariable.swift @@ -1,5 +1,6 @@ import Foundation +/// An environment variable supplied to code-tool execution, with support for Liquid templates in its value. public struct CodeToolEnvironmentVariable: Codable, Hashable, Sendable { /// Name of the environment variable public let name: String diff --git a/Sources/Schemas/Compliance.swift b/Sources/Schemas/Compliance.swift index 1855e2a..b72db6e 100644 --- a/Sources/Schemas/Compliance.swift +++ b/Sources/Schemas/Compliance.swift @@ -1,5 +1,6 @@ import Foundation +/// Compliance information captured for a call, including recording consent. public struct Compliance: Codable, Hashable, Sendable { /// This is the recording consent of the call. Configure in `assistant.compliancePlan.recordingConsentPlan`. public let recordingConsent: RecordingConsent? diff --git a/Sources/Schemas/ComplianceOverride.swift b/Sources/Schemas/ComplianceOverride.swift index c3b9b14..8761b1d 100644 --- a/Sources/Schemas/ComplianceOverride.swift +++ b/Sources/Schemas/ComplianceOverride.swift @@ -1,5 +1,6 @@ import Foundation +/// Overrides storage behavior for an output when HIPAA compliance is enabled. public struct ComplianceOverride: Codable, Hashable, Sendable { /// Force storage for this output under HIPAA. Only enable if output contains no sensitive data. public let forceStoreOnHipaaEnabled: Bool? diff --git a/Sources/Schemas/CompliancePlan.swift b/Sources/Schemas/CompliancePlan.swift index 3494e9f..b8fb219 100644 --- a/Sources/Schemas/CompliancePlan.swift +++ b/Sources/Schemas/CompliancePlan.swift @@ -1,5 +1,6 @@ import Foundation +/// Controls HIPAA and PCI requirements, transcript security filtering, and recording-consent handling for assistant calls. public struct CompliancePlan: Codable, Hashable, Sendable { /// When this is enabled, logs, recordings, and transcriptions will be stored in HIPAA-compliant storage. Defaults to false. Only HIPAA-compliant providers will be available for LLM, Voice, and Transcriber respectively. This setting is only honored if the organization is on an Enterprise subscription or has purchased the HIPAA add-on. public let hipaaEnabled: Bool? @@ -8,6 +9,7 @@ public struct CompliancePlan: Codable, Hashable, Sendable { public let pciEnabled: Bool? /// This is the security filter plan for the assistant. It allows filtering of transcripts for security threats before sending to LLM. public let securityFilterPlan: SecurityFilterPlan? + /// Controls how recording consent is requested before the assistant joins the call. public let recordingConsentPlan: CompliancePlanRecordingConsentPlan? /// Additional properties that are not explicitly defined in the schema public let additionalProperties: [String: JSONValue] diff --git a/Sources/Schemas/CompliancePlanRecordingConsentPlan.swift b/Sources/Schemas/CompliancePlanRecordingConsentPlan.swift index 7fc2a6b..f85cd95 100644 --- a/Sources/Schemas/CompliancePlanRecordingConsentPlan.swift +++ b/Sources/Schemas/CompliancePlanRecordingConsentPlan.swift @@ -1,5 +1,6 @@ import Foundation +/// Controls how recording consent is requested before the assistant joins the call. public enum CompliancePlanRecordingConsentPlan: Codable, Hashable, Sendable { case stayOnLine(RecordingConsentPlanStayOnLine) case verbal(RecordingConsentPlanVerbal) diff --git a/Sources/Schemas/ComputerTool.swift b/Sources/Schemas/ComputerTool.swift index f95842c..06ba20a 100644 --- a/Sources/Schemas/ComputerTool.swift +++ b/Sources/Schemas/ComputerTool.swift @@ -1,5 +1,6 @@ import Foundation +/// A reusable tool that lets the model interact with a computer display through screen, pointer, and keyboard actions. public struct ComputerTool: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/Condition.swift b/Sources/Schemas/Condition.swift index d1454ea..31b1b60 100644 --- a/Sources/Schemas/Condition.swift +++ b/Sources/Schemas/Condition.swift @@ -1,5 +1,6 @@ import Foundation +/// Compares a named parameter with a value using the selected comparison operator. public struct Condition: Codable, Hashable, Sendable { /// This is the operator you want to use to compare the parameter and value. public let `operator`: ConditionOperator diff --git a/Sources/Schemas/ContextEngineeringPlanAll.swift b/Sources/Schemas/ContextEngineeringPlanAll.swift index 41e4457..899f2de 100644 --- a/Sources/Schemas/ContextEngineeringPlanAll.swift +++ b/Sources/Schemas/ContextEngineeringPlanAll.swift @@ -1,5 +1,6 @@ import Foundation +/// Includes all available messages when constructing context for a handoff. public struct ContextEngineeringPlanAll: Codable, Hashable, Sendable { /// Additional properties that are not explicitly defined in the schema public let additionalProperties: [String: JSONValue] diff --git a/Sources/Schemas/ContextEngineeringPlanLastNMessages.swift b/Sources/Schemas/ContextEngineeringPlanLastNMessages.swift index 4fe6ea2..420404b 100644 --- a/Sources/Schemas/ContextEngineeringPlanLastNMessages.swift +++ b/Sources/Schemas/ContextEngineeringPlanLastNMessages.swift @@ -1,5 +1,6 @@ import Foundation +/// Includes a configured number of the most recent messages when constructing context for a handoff. public struct ContextEngineeringPlanLastNMessages: Codable, Hashable, Sendable { /// This is the maximum number of messages to include in the context engineering plan. public let maxMessages: Double diff --git a/Sources/Schemas/ContextEngineeringPlanNone.swift b/Sources/Schemas/ContextEngineeringPlanNone.swift index abc1418..e0ef9ff 100644 --- a/Sources/Schemas/ContextEngineeringPlanNone.swift +++ b/Sources/Schemas/ContextEngineeringPlanNone.swift @@ -1,5 +1,6 @@ import Foundation +/// Excludes prior conversation messages when constructing context for a handoff. public struct ContextEngineeringPlanNone: Codable, Hashable, Sendable { /// Additional properties that are not explicitly defined in the schema public let additionalProperties: [String: JSONValue] diff --git a/Sources/Schemas/ContextEngineeringPlanUserAndAssistantMessages.swift b/Sources/Schemas/ContextEngineeringPlanUserAndAssistantMessages.swift index 23096a5..e2592ec 100644 --- a/Sources/Schemas/ContextEngineeringPlanUserAndAssistantMessages.swift +++ b/Sources/Schemas/ContextEngineeringPlanUserAndAssistantMessages.swift @@ -1,5 +1,6 @@ import Foundation +/// Includes only user and assistant messages when constructing context for a handoff. public struct ContextEngineeringPlanUserAndAssistantMessages: Codable, Hashable, Sendable { /// Additional properties that are not explicitly defined in the schema public let additionalProperties: [String: JSONValue] diff --git a/Sources/Schemas/ConversationNode.swift b/Sources/Schemas/ConversationNode.swift index eca2a28..931a81c 100644 --- a/Sources/Schemas/ConversationNode.swift +++ b/Sources/Schemas/ConversationNode.swift @@ -1,5 +1,6 @@ import Foundation +/// A workflow node where the assistant conducts a conversation using optional node-specific providers, tools, prompt, and variable extraction. public struct ConversationNode: Codable, Hashable, Sendable { /// This is the model for the node. /// @@ -21,6 +22,7 @@ public struct ConversationNode: Codable, Hashable, Sendable { /// /// Both `tools` and `toolIds` can be used together. public let toolIds: [String]? + /// Prompt that guides the assistant while this node is active. public let prompt: String? /// This is the plan for the global node. public let globalNodePlan: GlobalNodePlan? @@ -72,6 +74,7 @@ public struct ConversationNode: Codable, Hashable, Sendable { /// /// Note: The `schema` field is required for Conversation nodes if you want to extract variables from the user's responses. `aliases` is just a convenience. public let variableExtractionPlan: VariableExtractionPlan? + /// Unique name used to identify this workflow node. public let name: String /// This is whether or not the node is the start of the workflow. public let isStart: Bool? diff --git a/Sources/Schemas/CostBreakdown.swift b/Sources/Schemas/CostBreakdown.swift index e25ca22..7f23c57 100644 --- a/Sources/Schemas/CostBreakdown.swift +++ b/Sources/Schemas/CostBreakdown.swift @@ -1,5 +1,6 @@ import Foundation +/// Aggregated call costs and usage, including transport, transcription, model, voice, Vapi, analysis, token, and character totals. public struct CostBreakdown: Codable, Hashable, Sendable { /// This is the cost of the transport provider, like Twilio or Vonage. public let transport: Double? diff --git a/Sources/Schemas/CreateAnthropicBedrockCredentialDto.swift b/Sources/Schemas/CreateAnthropicBedrockCredentialDto.swift index ba5d046..850f337 100644 --- a/Sources/Schemas/CreateAnthropicBedrockCredentialDto.swift +++ b/Sources/Schemas/CreateAnthropicBedrockCredentialDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Credentials for authenticating Anthropic model requests through Amazon Bedrock, including AWS region and authentication method. public struct CreateAnthropicBedrockCredentialDto: Codable, Hashable, Sendable { /// AWS region where Bedrock is configured. public let region: CreateAnthropicBedrockCredentialDtoRegion diff --git a/Sources/Schemas/CreateAnthropicCredentialDto.swift b/Sources/Schemas/CreateAnthropicCredentialDto.swift index f7f02be..cb59202 100644 --- a/Sources/Schemas/CreateAnthropicCredentialDto.swift +++ b/Sources/Schemas/CreateAnthropicCredentialDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Credentials for authenticating assistant model requests with Anthropic. public struct CreateAnthropicCredentialDto: Codable, Hashable, Sendable { /// This is not returned in the API. public let apiKey: String diff --git a/Sources/Schemas/CreateAnyscaleCredentialDto.swift b/Sources/Schemas/CreateAnyscaleCredentialDto.swift index 14b83e5..d045321 100644 --- a/Sources/Schemas/CreateAnyscaleCredentialDto.swift +++ b/Sources/Schemas/CreateAnyscaleCredentialDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Credentials for authenticating assistant model requests with Anyscale. public struct CreateAnyscaleCredentialDto: Codable, Hashable, Sendable { /// This is not returned in the API. public let apiKey: String diff --git a/Sources/Schemas/CreateApiRequestToolDto.swift b/Sources/Schemas/CreateApiRequestToolDto.swift index cbcafd5..3f59089 100644 --- a/Sources/Schemas/CreateApiRequestToolDto.swift +++ b/Sources/Schemas/CreateApiRequestToolDto.swift @@ -1,10 +1,12 @@ import Foundation +/// Configuration used to create a reusable tool that sends HTTP requests to a configured API and can authenticate, retry failures, and extract variables from responses. public struct CreateApiRequestToolDto: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// /// For some tools, this is auto-filled based on special fields like `tool.destinations`. For others like the function tool, these can be custom configured. public let messages: [CreateApiRequestToolDtoMessagesItem]? + /// The HTTP method used for the API request. public let method: CreateApiRequestToolDtoMethod /// This is the timeout in seconds for the request. Defaults to 20 seconds. /// diff --git a/Sources/Schemas/CreateApiRequestToolDtoMethod.swift b/Sources/Schemas/CreateApiRequestToolDtoMethod.swift index 1b74d80..3d6cc32 100644 --- a/Sources/Schemas/CreateApiRequestToolDtoMethod.swift +++ b/Sources/Schemas/CreateApiRequestToolDtoMethod.swift @@ -1,5 +1,6 @@ import Foundation +/// The HTTP method used for the API request. public enum CreateApiRequestToolDtoMethod: String, Codable, Hashable, CaseIterable, Sendable { case post = "POST" case get = "GET" diff --git a/Sources/Schemas/CreateAssemblyAiCredentialDto.swift b/Sources/Schemas/CreateAssemblyAiCredentialDto.swift index d23f48c..e21938d 100644 --- a/Sources/Schemas/CreateAssemblyAiCredentialDto.swift +++ b/Sources/Schemas/CreateAssemblyAiCredentialDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Credentials for authenticating transcription requests with AssemblyAI. public struct CreateAssemblyAiCredentialDto: Codable, Hashable, Sendable { /// This is not returned in the API. public let apiKey: String diff --git a/Sources/Schemas/CreateAssistantDto.swift b/Sources/Schemas/CreateAssistantDto.swift index 2e5ca83..835cdb3 100644 --- a/Sources/Schemas/CreateAssistantDto.swift +++ b/Sources/Schemas/CreateAssistantDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration used to create an assistant, including its model, voice, transcriber, prompts, tools, messaging, and conversation behavior. public struct CreateAssistantDto: Codable, Hashable, Sendable { /// These are the options for the assistant's transcriber. public let transcriber: CreateAssistantDtoTranscriber? @@ -11,6 +12,7 @@ public struct CreateAssistantDto: Codable, Hashable, Sendable { /// /// If unspecified, assistant will wait for user to speak and use the model to respond once they speak. public let firstMessage: String? + /// Set to `true` to allow the user to interrupt the assistant while it speaks the first message. Default is `false`. public let firstMessageInterruptionsEnabled: Bool? /// This is the mode for the first message. Default is 'assistant-speaks-first'. /// @@ -63,6 +65,7 @@ public struct CreateAssistantDto: Codable, Hashable, Sendable { public let endCallMessage: String? /// This list contains phrases that, if spoken by the assistant, will trigger the call to be hung up. Case insensitive. public let endCallPhrases: [String]? + /// Compliance settings for the assistant, including HIPAA and PCI behavior, security filtering, and recording consent. public let compliancePlan: CompliancePlan? /// This is for metadata you want to store on the assistant. public let metadata: [String: JSONValue]? @@ -115,6 +118,7 @@ public struct CreateAssistantDto: Codable, Hashable, Sendable { /// 2. phoneNumber.serverUrl /// 3. org.serverUrl public let server: Server? + /// Configuration for collecting and processing DTMF keypad input during calls. public let keypadInputPlan: KeypadInputPlan? /// Additional properties that are not explicitly defined in the schema public let additionalProperties: [String: JSONValue] diff --git a/Sources/Schemas/CreateAzureCredentialDto.swift b/Sources/Schemas/CreateAzureCredentialDto.swift index 698d454..4ef04d4 100644 --- a/Sources/Schemas/CreateAzureCredentialDto.swift +++ b/Sources/Schemas/CreateAzureCredentialDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Credentials for Azure Speech or Blob Storage, including service, region, and optional storage bucket settings. public struct CreateAzureCredentialDto: Codable, Hashable, Sendable { /// This is the service being used in Azure. public let service: CreateAzureCredentialDtoService diff --git a/Sources/Schemas/CreateAzureOpenAiCredentialDto.swift b/Sources/Schemas/CreateAzureOpenAiCredentialDto.swift index e616c1e..bf41aea 100644 --- a/Sources/Schemas/CreateAzureOpenAiCredentialDto.swift +++ b/Sources/Schemas/CreateAzureOpenAiCredentialDto.swift @@ -1,12 +1,16 @@ import Foundation +/// Credentials for authenticating assistant model requests with Azure OpenAI, including region, endpoint, and available models. public struct CreateAzureOpenAiCredentialDto: Codable, Hashable, Sendable { + /// Azure region that hosts the OpenAI resource. public let region: CreateAzureOpenAiCredentialDtoRegion + /// Azure OpenAI models available through this credential. public let models: [CreateAzureOpenAiCredentialDtoModelsItem] /// This is not returned in the API. public let openAiKey: String /// This is not returned in the API. public let ocpApimSubscriptionKey: String? + /// Endpoint URL for the Azure OpenAI resource. public let openAiEndpoint: String /// This is the name of credential. This is just for your reference. public let name: String? diff --git a/Sources/Schemas/CreateAzureOpenAiCredentialDtoRegion.swift b/Sources/Schemas/CreateAzureOpenAiCredentialDtoRegion.swift index c684ac7..260aef7 100644 --- a/Sources/Schemas/CreateAzureOpenAiCredentialDtoRegion.swift +++ b/Sources/Schemas/CreateAzureOpenAiCredentialDtoRegion.swift @@ -1,5 +1,6 @@ import Foundation +/// Azure region that hosts the OpenAI resource. public enum CreateAzureOpenAiCredentialDtoRegion: String, Codable, Hashable, CaseIterable, Sendable { case australiaeast case canadaeast diff --git a/Sources/Schemas/CreateBarInsightFromCallTableDto.swift b/Sources/Schemas/CreateBarInsightFromCallTableDto.swift index 2b71aaa..db37c47 100644 --- a/Sources/Schemas/CreateBarInsightFromCallTableDto.swift +++ b/Sources/Schemas/CreateBarInsightFromCallTableDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration used to create a bar-chart insight from call data using metric queries, formulas, grouping, and a stepped time range. public struct CreateBarInsightFromCallTableDto: Codable, Hashable, Sendable { /// This is the name of the Insight. public let name: String? @@ -21,6 +22,7 @@ public struct CreateBarInsightFromCallTableDto: Codable, Hashable, Sendable { public let formulas: [InsightFormula]? /// This is the metadata for the insight. public let metadata: BarInsightMetadata? + /// The time range and interval used to aggregate the bar-chart data. public let timeRange: InsightTimeRangeWithStep? /// This is the group by column for the insight when table is `call`. /// These are the columns to group the results by. diff --git a/Sources/Schemas/CreateBashToolDto.swift b/Sources/Schemas/CreateBashToolDto.swift index 15575e0..e1a37b3 100644 --- a/Sources/Schemas/CreateBashToolDto.swift +++ b/Sources/Schemas/CreateBashToolDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration used to create a tool that executes shell commands in a configured environment. public struct CreateBashToolDto: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/CreateByoPhoneNumberDto.swift b/Sources/Schemas/CreateByoPhoneNumberDto.swift index c3e6b59..e695c67 100644 --- a/Sources/Schemas/CreateByoPhoneNumberDto.swift +++ b/Sources/Schemas/CreateByoPhoneNumberDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration used to connect a bring-your-own phone number to Vapi with a stored telephony credential and routing settings. public struct CreateByoPhoneNumberDto: Codable, Hashable, Sendable { /// This is the fallback destination an inbound call will be transferred to if: /// 1. `assistantId` is not set diff --git a/Sources/Schemas/CreateByoSipTrunkCredentialDto.swift b/Sources/Schemas/CreateByoSipTrunkCredentialDto.swift index 2367ed5..cabf06a 100644 --- a/Sources/Schemas/CreateByoSipTrunkCredentialDto.swift +++ b/Sources/Schemas/CreateByoSipTrunkCredentialDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for connecting Vapi to a bring-your-own SIP trunk or carrier, including gateways, outbound authentication, number handling, and optional session border controller routing. public struct CreateByoSipTrunkCredentialDto: Codable, Hashable, Sendable { /// This is the list of SIP trunk's gateways. public let gateways: [SipTrunkGateway] diff --git a/Sources/Schemas/CreateCartesiaCredentialDto.swift b/Sources/Schemas/CreateCartesiaCredentialDto.swift index f120911..fae235f 100644 --- a/Sources/Schemas/CreateCartesiaCredentialDto.swift +++ b/Sources/Schemas/CreateCartesiaCredentialDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Credentials for authenticating speech recognition and voice synthesis requests with Cartesia. public struct CreateCartesiaCredentialDto: Codable, Hashable, Sendable { /// This is not returned in the API. public let apiKey: String diff --git a/Sources/Schemas/CreateCerebrasCredentialDto.swift b/Sources/Schemas/CreateCerebrasCredentialDto.swift index 050949f..8614b3f 100644 --- a/Sources/Schemas/CreateCerebrasCredentialDto.swift +++ b/Sources/Schemas/CreateCerebrasCredentialDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Credentials for authenticating assistant model requests with Cerebras. public struct CreateCerebrasCredentialDto: Codable, Hashable, Sendable { /// This is not returned in the API. public let apiKey: String diff --git a/Sources/Schemas/CreateCloudflareCredentialDto.swift b/Sources/Schemas/CreateCloudflareCredentialDto.swift index 2b27082..2b72742 100644 --- a/Sources/Schemas/CreateCloudflareCredentialDto.swift +++ b/Sources/Schemas/CreateCloudflareCredentialDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Credentials for storing call artifacts in Cloudflare R2, including account details, bucket configuration, and upload fallback order. public struct CreateCloudflareCredentialDto: Codable, Hashable, Sendable { /// Cloudflare Account Id. public let accountId: String? diff --git a/Sources/Schemas/CreateCodeToolDto.swift b/Sources/Schemas/CreateCodeToolDto.swift index 83c487a..abbeeab 100644 --- a/Sources/Schemas/CreateCodeToolDto.swift +++ b/Sources/Schemas/CreateCodeToolDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration used to create a reusable tool that executes TypeScript code with configured credentials, environment variables, and timeout. public struct CreateCodeToolDto: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/CreateComputerToolDto.swift b/Sources/Schemas/CreateComputerToolDto.swift index b1ab043..3713d49 100644 --- a/Sources/Schemas/CreateComputerToolDto.swift +++ b/Sources/Schemas/CreateComputerToolDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration used to create a tool that lets the model interact with a computer display through screen, pointer, and keyboard actions. public struct CreateComputerToolDto: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/CreateCustomCredentialDto.swift b/Sources/Schemas/CreateCustomCredentialDto.swift index e4e4c54..fe94b36 100644 --- a/Sources/Schemas/CreateCustomCredentialDto.swift +++ b/Sources/Schemas/CreateCustomCredentialDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Reusable custom credentials for authenticating outbound requests, with optional public-key encryption for sensitive request data. public struct CreateCustomCredentialDto: Codable, Hashable, Sendable { /// This is the authentication plan. Supports OAuth2 RFC 6749, HMAC signing, and Bearer authentication. public let authenticationPlan: CreateCustomCredentialDtoAuthenticationPlan diff --git a/Sources/Schemas/CreateCustomKnowledgeBaseDto.swift b/Sources/Schemas/CreateCustomKnowledgeBaseDto.swift index 924a09f..184f55c 100644 --- a/Sources/Schemas/CreateCustomKnowledgeBaseDto.swift +++ b/Sources/Schemas/CreateCustomKnowledgeBaseDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for connecting a custom knowledge-base implementation through a customer-hosted server. public struct CreateCustomKnowledgeBaseDto: Codable, Hashable, Sendable { /// This knowledge base is bring your own knowledge base implementation. public let provider: CreateCustomKnowledgeBaseDtoProvider diff --git a/Sources/Schemas/CreateCustomLlmCredentialDto.swift b/Sources/Schemas/CreateCustomLlmCredentialDto.swift index a372ee4..5bbb2cd 100644 --- a/Sources/Schemas/CreateCustomLlmCredentialDto.swift +++ b/Sources/Schemas/CreateCustomLlmCredentialDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Credentials for authenticating requests to a custom language model with an API key or OAuth 2.0 authentication plan. public struct CreateCustomLlmCredentialDto: Codable, Hashable, Sendable { /// This is not returned in the API. public let apiKey: String diff --git a/Sources/Schemas/CreateCustomerDto.swift b/Sources/Schemas/CreateCustomerDto.swift index f3bf686..a82bfea 100644 --- a/Sources/Schemas/CreateCustomerDto.swift +++ b/Sources/Schemas/CreateCustomerDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Customer details used for call delivery and assistant personalization, including phone or SIP destination, contact identifiers, extension, and assistant overrides. public struct CreateCustomerDto: Codable, Hashable, Sendable { /// This is the flag to toggle the E164 check for the `number` field. This is an advanced property which should be used if you know your use case requires it. /// diff --git a/Sources/Schemas/CreateDeepInfraCredentialDto.swift b/Sources/Schemas/CreateDeepInfraCredentialDto.swift index 7d2b164..0cb5321 100644 --- a/Sources/Schemas/CreateDeepInfraCredentialDto.swift +++ b/Sources/Schemas/CreateDeepInfraCredentialDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Credentials for authenticating assistant model requests with DeepInfra. public struct CreateDeepInfraCredentialDto: Codable, Hashable, Sendable { /// This is not returned in the API. public let apiKey: String diff --git a/Sources/Schemas/CreateDeepSeekCredentialDto.swift b/Sources/Schemas/CreateDeepSeekCredentialDto.swift index a87bf7a..8de387d 100644 --- a/Sources/Schemas/CreateDeepSeekCredentialDto.swift +++ b/Sources/Schemas/CreateDeepSeekCredentialDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Credentials for authenticating assistant model requests with DeepSeek. public struct CreateDeepSeekCredentialDto: Codable, Hashable, Sendable { /// This is not returned in the API. public let apiKey: String diff --git a/Sources/Schemas/CreateDeepgramCredentialDto.swift b/Sources/Schemas/CreateDeepgramCredentialDto.swift index ca4d087..ca9ef44 100644 --- a/Sources/Schemas/CreateDeepgramCredentialDto.swift +++ b/Sources/Schemas/CreateDeepgramCredentialDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Credentials for authenticating speech recognition and voice synthesis requests with Deepgram, with an optional API URL for an on-premises instance. public struct CreateDeepgramCredentialDto: Codable, Hashable, Sendable { /// This is not returned in the API. public let apiKey: String diff --git a/Sources/Schemas/CreateDtmfToolDto.swift b/Sources/Schemas/CreateDtmfToolDto.swift index 8917e83..8bcd43c 100644 --- a/Sources/Schemas/CreateDtmfToolDto.swift +++ b/Sources/Schemas/CreateDtmfToolDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration used to create a tool that lets an assistant send DTMF keypad tones during a call. public struct CreateDtmfToolDto: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/CreateElevenLabsCredentialDto.swift b/Sources/Schemas/CreateElevenLabsCredentialDto.swift index 08cc4ed..01ec745 100644 --- a/Sources/Schemas/CreateElevenLabsCredentialDto.swift +++ b/Sources/Schemas/CreateElevenLabsCredentialDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Credentials for authenticating speech recognition and voice synthesis requests with ElevenLabs. public struct CreateElevenLabsCredentialDto: Codable, Hashable, Sendable { /// This is not returned in the API. public let apiKey: String diff --git a/Sources/Schemas/CreateEmailCredentialDto.swift b/Sources/Schemas/CreateEmailCredentialDto.swift index 931faff..5d48819 100644 --- a/Sources/Schemas/CreateEmailCredentialDto.swift +++ b/Sources/Schemas/CreateEmailCredentialDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Destination configuration for sending Vapi alerts to an email address. public struct CreateEmailCredentialDto: Codable, Hashable, Sendable { /// The recipient email address for alerts public let email: String diff --git a/Sources/Schemas/CreateEndCallToolDto.swift b/Sources/Schemas/CreateEndCallToolDto.swift index 42958d4..66194f1 100644 --- a/Sources/Schemas/CreateEndCallToolDto.swift +++ b/Sources/Schemas/CreateEndCallToolDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration used to create a tool that lets an assistant end the active call. public struct CreateEndCallToolDto: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/CreateEvalDto.swift b/Sources/Schemas/CreateEvalDto.swift index f53b5b7..c86310f 100644 --- a/Sources/Schemas/CreateEvalDto.swift +++ b/Sources/Schemas/CreateEvalDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration used to create a reusable eval containing a mock conversation and checkpoints for assessing assistant responses and tool calls. public struct CreateEvalDto: Codable, Hashable, Sendable { /// This is the mock conversation that will be used to evaluate the flow of the conversation. /// diff --git a/Sources/Schemas/CreateFunctionToolDto.swift b/Sources/Schemas/CreateFunctionToolDto.swift index 555e881..51bed07 100644 --- a/Sources/Schemas/CreateFunctionToolDto.swift +++ b/Sources/Schemas/CreateFunctionToolDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration used to create a custom function tool that sends model-generated arguments to a server and returns the result to the assistant. public struct CreateFunctionToolDto: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/CreateGcpCredentialDto.swift b/Sources/Schemas/CreateGcpCredentialDto.swift index 72e8c7d..30a3722 100644 --- a/Sources/Schemas/CreateGcpCredentialDto.swift +++ b/Sources/Schemas/CreateGcpCredentialDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Service-account credentials for Google Cloud resources and optional call-artifact storage, including region, bucket configuration, and upload fallback order. public struct CreateGcpCredentialDto: Codable, Hashable, Sendable { /// This is the order in which this storage provider is tried during upload retries. Lower numbers are tried first in increasing order. public let fallbackIndex: Double? @@ -9,6 +10,7 @@ public struct CreateGcpCredentialDto: Codable, Hashable, Sendable { public let gcpKey: GcpKey /// This is the region of the GCP resource. public let region: String? + /// Bucket configuration used to store call artifacts in Google Cloud Storage. public let bucketPlan: BucketPlan? /// This is the name of credential. This is just for your reference. public let name: String? diff --git a/Sources/Schemas/CreateGladiaCredentialDto.swift b/Sources/Schemas/CreateGladiaCredentialDto.swift index a151e70..a9c77c3 100644 --- a/Sources/Schemas/CreateGladiaCredentialDto.swift +++ b/Sources/Schemas/CreateGladiaCredentialDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Credentials for authenticating transcription requests with Gladia. public struct CreateGladiaCredentialDto: Codable, Hashable, Sendable { /// This is not returned in the API. public let apiKey: String diff --git a/Sources/Schemas/CreateGoHighLevelCalendarAvailabilityToolDto.swift b/Sources/Schemas/CreateGoHighLevelCalendarAvailabilityToolDto.swift index 640013d..28511b2 100644 --- a/Sources/Schemas/CreateGoHighLevelCalendarAvailabilityToolDto.swift +++ b/Sources/Schemas/CreateGoHighLevelCalendarAvailabilityToolDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration used to create a tool that checks calendar availability in a connected GoHighLevel account. public struct CreateGoHighLevelCalendarAvailabilityToolDto: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/CreateGoHighLevelCalendarEventCreateToolDto.swift b/Sources/Schemas/CreateGoHighLevelCalendarEventCreateToolDto.swift index 4c5e166..5940bb3 100644 --- a/Sources/Schemas/CreateGoHighLevelCalendarEventCreateToolDto.swift +++ b/Sources/Schemas/CreateGoHighLevelCalendarEventCreateToolDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration used to create a tool that adds calendar events to a connected GoHighLevel account. public struct CreateGoHighLevelCalendarEventCreateToolDto: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/CreateGoHighLevelContactCreateToolDto.swift b/Sources/Schemas/CreateGoHighLevelContactCreateToolDto.swift index 3f7e071..28d7308 100644 --- a/Sources/Schemas/CreateGoHighLevelContactCreateToolDto.swift +++ b/Sources/Schemas/CreateGoHighLevelContactCreateToolDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration used to create a tool that adds contacts to a connected GoHighLevel account. public struct CreateGoHighLevelContactCreateToolDto: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/CreateGoHighLevelContactGetToolDto.swift b/Sources/Schemas/CreateGoHighLevelContactGetToolDto.swift index a7110dc..2e01d23 100644 --- a/Sources/Schemas/CreateGoHighLevelContactGetToolDto.swift +++ b/Sources/Schemas/CreateGoHighLevelContactGetToolDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration used to create a tool that retrieves contacts from a connected GoHighLevel account. public struct CreateGoHighLevelContactGetToolDto: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/CreateGoHighLevelCredentialDto.swift b/Sources/Schemas/CreateGoHighLevelCredentialDto.swift index 8d4c053..1cdb275 100644 --- a/Sources/Schemas/CreateGoHighLevelCredentialDto.swift +++ b/Sources/Schemas/CreateGoHighLevelCredentialDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Credentials for authenticating Vapi integrations with GoHighLevel. public struct CreateGoHighLevelCredentialDto: Codable, Hashable, Sendable { /// This is not returned in the API. public let apiKey: String diff --git a/Sources/Schemas/CreateGoHighLevelMcpCredentialDto.swift b/Sources/Schemas/CreateGoHighLevelMcpCredentialDto.swift index 28928d0..6e43aac 100644 --- a/Sources/Schemas/CreateGoHighLevelMcpCredentialDto.swift +++ b/Sources/Schemas/CreateGoHighLevelMcpCredentialDto.swift @@ -1,5 +1,6 @@ import Foundation +/// OAuth 2.0 session credentials for authenticating GoHighLevel MCP requests. public struct CreateGoHighLevelMcpCredentialDto: Codable, Hashable, Sendable { /// This is the authentication session for the credential. public let authenticationSession: Oauth2AuthenticationSession diff --git a/Sources/Schemas/CreateGoogleCalendarCheckAvailabilityToolDto.swift b/Sources/Schemas/CreateGoogleCalendarCheckAvailabilityToolDto.swift index c1b847b..38370eb 100644 --- a/Sources/Schemas/CreateGoogleCalendarCheckAvailabilityToolDto.swift +++ b/Sources/Schemas/CreateGoogleCalendarCheckAvailabilityToolDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration used to create a tool that checks availability in a connected Google Calendar. public struct CreateGoogleCalendarCheckAvailabilityToolDto: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/CreateGoogleCalendarCreateEventToolDto.swift b/Sources/Schemas/CreateGoogleCalendarCreateEventToolDto.swift index b883e62..8148cbe 100644 --- a/Sources/Schemas/CreateGoogleCalendarCreateEventToolDto.swift +++ b/Sources/Schemas/CreateGoogleCalendarCreateEventToolDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration used to create a tool that adds events to a connected Google Calendar. public struct CreateGoogleCalendarCreateEventToolDto: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/CreateGoogleCalendarOAuth2AuthorizationCredentialDto.swift b/Sources/Schemas/CreateGoogleCalendarOAuth2AuthorizationCredentialDto.swift index 5ccee14..7aad877 100644 --- a/Sources/Schemas/CreateGoogleCalendarOAuth2AuthorizationCredentialDto.swift +++ b/Sources/Schemas/CreateGoogleCalendarOAuth2AuthorizationCredentialDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Stored OAuth 2.0 authorization for Google Calendar operations. public struct CreateGoogleCalendarOAuth2AuthorizationCredentialDto: Codable, Hashable, Sendable { /// The authorization ID for the OAuth2 authorization public let authorizationId: String diff --git a/Sources/Schemas/CreateGoogleCalendarOAuth2ClientCredentialDto.swift b/Sources/Schemas/CreateGoogleCalendarOAuth2ClientCredentialDto.swift index f529f5f..5532b14 100644 --- a/Sources/Schemas/CreateGoogleCalendarOAuth2ClientCredentialDto.swift +++ b/Sources/Schemas/CreateGoogleCalendarOAuth2ClientCredentialDto.swift @@ -1,5 +1,6 @@ import Foundation +/// OAuth 2.0 client credential for Google Calendar integrations. public struct CreateGoogleCalendarOAuth2ClientCredentialDto: Codable, Hashable, Sendable { /// This is the name of credential. This is just for your reference. public let name: String? diff --git a/Sources/Schemas/CreateGoogleCredentialDto.swift b/Sources/Schemas/CreateGoogleCredentialDto.swift index dcc4823..90acac7 100644 --- a/Sources/Schemas/CreateGoogleCredentialDto.swift +++ b/Sources/Schemas/CreateGoogleCredentialDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Credentials for authenticating assistant model requests with Google AI. public struct CreateGoogleCredentialDto: Codable, Hashable, Sendable { /// This is not returned in the API. public let apiKey: String diff --git a/Sources/Schemas/CreateGoogleSheetsOAuth2AuthorizationCredentialDto.swift b/Sources/Schemas/CreateGoogleSheetsOAuth2AuthorizationCredentialDto.swift index 14d55b7..566b985 100644 --- a/Sources/Schemas/CreateGoogleSheetsOAuth2AuthorizationCredentialDto.swift +++ b/Sources/Schemas/CreateGoogleSheetsOAuth2AuthorizationCredentialDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Stored OAuth 2.0 authorization for Google Sheets operations. public struct CreateGoogleSheetsOAuth2AuthorizationCredentialDto: Codable, Hashable, Sendable { /// The authorization ID for the OAuth2 authorization public let authorizationId: String diff --git a/Sources/Schemas/CreateGoogleSheetsRowAppendToolDto.swift b/Sources/Schemas/CreateGoogleSheetsRowAppendToolDto.swift index 63d81f5..8291190 100644 --- a/Sources/Schemas/CreateGoogleSheetsRowAppendToolDto.swift +++ b/Sources/Schemas/CreateGoogleSheetsRowAppendToolDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration used to create a tool that appends rows to a connected Google Sheet. public struct CreateGoogleSheetsRowAppendToolDto: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/CreateGroqCredentialDto.swift b/Sources/Schemas/CreateGroqCredentialDto.swift index 9ab05ff..e9a42ae 100644 --- a/Sources/Schemas/CreateGroqCredentialDto.swift +++ b/Sources/Schemas/CreateGroqCredentialDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Credentials for authenticating assistant model requests with Groq. public struct CreateGroqCredentialDto: Codable, Hashable, Sendable { /// This is not returned in the API. public let apiKey: String diff --git a/Sources/Schemas/CreateHandoffToolDto.swift b/Sources/Schemas/CreateHandoffToolDto.swift index 8534813..5252c43 100644 --- a/Sources/Schemas/CreateHandoffToolDto.swift +++ b/Sources/Schemas/CreateHandoffToolDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration used to create a tool that hands a conversation to another assistant, squad, or dynamically selected destination. public struct CreateHandoffToolDto: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/CreateHumeCredentialDto.swift b/Sources/Schemas/CreateHumeCredentialDto.swift index 5fca34d..8ffe1f7 100644 --- a/Sources/Schemas/CreateHumeCredentialDto.swift +++ b/Sources/Schemas/CreateHumeCredentialDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Credentials for authenticating voice synthesis requests with Hume. public struct CreateHumeCredentialDto: Codable, Hashable, Sendable { /// This is not returned in the API. public let apiKey: String diff --git a/Sources/Schemas/CreateInflectionAiCredentialDto.swift b/Sources/Schemas/CreateInflectionAiCredentialDto.swift index 3d1dd9a..1818a69 100644 --- a/Sources/Schemas/CreateInflectionAiCredentialDto.swift +++ b/Sources/Schemas/CreateInflectionAiCredentialDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Credentials for authenticating assistant model requests with Inflection AI. public struct CreateInflectionAiCredentialDto: Codable, Hashable, Sendable { /// This is not returned in the API. public let apiKey: String diff --git a/Sources/Schemas/CreateInworldCredentialDto.swift b/Sources/Schemas/CreateInworldCredentialDto.swift index e8f28ae..9afede2 100644 --- a/Sources/Schemas/CreateInworldCredentialDto.swift +++ b/Sources/Schemas/CreateInworldCredentialDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Credentials for authenticating voice synthesis requests with Inworld. public struct CreateInworldCredentialDto: Codable, Hashable, Sendable { /// This is the Inworld Basic (Base64) authentication token. This is not returned in the API. public let apiKey: String diff --git a/Sources/Schemas/CreateLangfuseCredentialDto.swift b/Sources/Schemas/CreateLangfuseCredentialDto.swift index 0068363..649f828 100644 --- a/Sources/Schemas/CreateLangfuseCredentialDto.swift +++ b/Sources/Schemas/CreateLangfuseCredentialDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Credentials for sending assistant call traces to a Langfuse project, including its public key, secret key, and host URL. public struct CreateLangfuseCredentialDto: Codable, Hashable, Sendable { /// The public key for Langfuse project. Eg: pk-lf-... public let publicKey: String diff --git a/Sources/Schemas/CreateLineInsightFromCallTableDto.swift b/Sources/Schemas/CreateLineInsightFromCallTableDto.swift index 146927c..d2ec0c5 100644 --- a/Sources/Schemas/CreateLineInsightFromCallTableDto.swift +++ b/Sources/Schemas/CreateLineInsightFromCallTableDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration used to create a line-chart insight from call data using metric queries, formulas, grouping, and a stepped time range. public struct CreateLineInsightFromCallTableDto: Codable, Hashable, Sendable { /// This is the name of the Insight. public let name: String? @@ -21,6 +22,7 @@ public struct CreateLineInsightFromCallTableDto: Codable, Hashable, Sendable { public let formulas: [InsightFormula]? /// This is the metadata for the insight. public let metadata: LineInsightMetadata? + /// The time range and interval used to aggregate the line-chart data. public let timeRange: InsightTimeRangeWithStep? /// This is the group by column for the insight when table is `call`. /// These are the columns to group the results by. diff --git a/Sources/Schemas/CreateLmntCredentialDto.swift b/Sources/Schemas/CreateLmntCredentialDto.swift index 83f2036..6b6590f 100644 --- a/Sources/Schemas/CreateLmntCredentialDto.swift +++ b/Sources/Schemas/CreateLmntCredentialDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Credentials for authenticating voice synthesis requests with LMNT. public struct CreateLmntCredentialDto: Codable, Hashable, Sendable { /// This is not returned in the API. public let apiKey: String diff --git a/Sources/Schemas/CreateMakeCredentialDto.swift b/Sources/Schemas/CreateMakeCredentialDto.swift index 8e1c4d8..a58d911 100644 --- a/Sources/Schemas/CreateMakeCredentialDto.swift +++ b/Sources/Schemas/CreateMakeCredentialDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Credentials for authenticating Vapi integrations with Make, including team, region, and API key. public struct CreateMakeCredentialDto: Codable, Hashable, Sendable { /// Team ID public let teamId: String diff --git a/Sources/Schemas/CreateMcpToolDto.swift b/Sources/Schemas/CreateMcpToolDto.swift index 4b8a3d8..8f6efd8 100644 --- a/Sources/Schemas/CreateMcpToolDto.swift +++ b/Sources/Schemas/CreateMcpToolDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration used to create a tool that connects an assistant to a Model Context Protocol server and exposes its available tools. public struct CreateMcpToolDto: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// @@ -17,6 +18,7 @@ public struct CreateMcpToolDto: Codable, Hashable, Sendable { public let server: Server? /// Per-tool message overrides for individual tools loaded from the MCP server. Set messages to an empty array to suppress messages for a specific tool. Tools not listed here will use the default messages from the parent tool. public let toolMessages: [McpToolMessages]? + /// Connection metadata for the MCP server, including its communication protocol. public let metadata: McpToolMetadata? /// This is the plan to reject a tool call based on the conversation state. /// diff --git a/Sources/Schemas/CreateMinimaxCredentialDto.swift b/Sources/Schemas/CreateMinimaxCredentialDto.swift index f643684..033dd20 100644 --- a/Sources/Schemas/CreateMinimaxCredentialDto.swift +++ b/Sources/Schemas/CreateMinimaxCredentialDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Credentials for authenticating assistant model and voice synthesis requests with MiniMax, including the MiniMax group identifier. public struct CreateMinimaxCredentialDto: Codable, Hashable, Sendable { /// This is not returned in the API. public let apiKey: String diff --git a/Sources/Schemas/CreateMistralCredentialDto.swift b/Sources/Schemas/CreateMistralCredentialDto.swift index 526568a..2e73216 100644 --- a/Sources/Schemas/CreateMistralCredentialDto.swift +++ b/Sources/Schemas/CreateMistralCredentialDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Credentials for authenticating assistant model requests with Mistral. public struct CreateMistralCredentialDto: Codable, Hashable, Sendable { /// This is not returned in the API. public let apiKey: String diff --git a/Sources/Schemas/CreateNeuphonicCredentialDto.swift b/Sources/Schemas/CreateNeuphonicCredentialDto.swift index 29ed07e..58afe67 100644 --- a/Sources/Schemas/CreateNeuphonicCredentialDto.swift +++ b/Sources/Schemas/CreateNeuphonicCredentialDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Credentials for authenticating voice synthesis requests with Neuphonic. public struct CreateNeuphonicCredentialDto: Codable, Hashable, Sendable { /// This is not returned in the API. public let apiKey: String diff --git a/Sources/Schemas/CreateOpenAiCredentialDto.swift b/Sources/Schemas/CreateOpenAiCredentialDto.swift index 140487b..dd1758b 100644 --- a/Sources/Schemas/CreateOpenAiCredentialDto.swift +++ b/Sources/Schemas/CreateOpenAiCredentialDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Credentials for authenticating assistant model, transcription, and voice synthesis requests with OpenAI. public struct CreateOpenAiCredentialDto: Codable, Hashable, Sendable { /// This is not returned in the API. public let apiKey: String diff --git a/Sources/Schemas/CreateOpenRouterCredentialDto.swift b/Sources/Schemas/CreateOpenRouterCredentialDto.swift index 48027d3..bbdd13d 100644 --- a/Sources/Schemas/CreateOpenRouterCredentialDto.swift +++ b/Sources/Schemas/CreateOpenRouterCredentialDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Credentials for authenticating assistant model requests with OpenRouter. public struct CreateOpenRouterCredentialDto: Codable, Hashable, Sendable { /// This is not returned in the API. public let apiKey: String diff --git a/Sources/Schemas/CreatePerplexityAiCredentialDto.swift b/Sources/Schemas/CreatePerplexityAiCredentialDto.swift index 542e586..1454ea9 100644 --- a/Sources/Schemas/CreatePerplexityAiCredentialDto.swift +++ b/Sources/Schemas/CreatePerplexityAiCredentialDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Credentials for authenticating assistant model requests with Perplexity AI. public struct CreatePerplexityAiCredentialDto: Codable, Hashable, Sendable { /// This is not returned in the API. public let apiKey: String diff --git a/Sources/Schemas/CreatePieInsightFromCallTableDto.swift b/Sources/Schemas/CreatePieInsightFromCallTableDto.swift index 12ee135..4dcea40 100644 --- a/Sources/Schemas/CreatePieInsightFromCallTableDto.swift +++ b/Sources/Schemas/CreatePieInsightFromCallTableDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration used to create a pie-chart insight from call data using metric queries, formulas, grouping, and a time range. public struct CreatePieInsightFromCallTableDto: Codable, Hashable, Sendable { /// This is the name of the Insight. public let name: String? @@ -19,6 +20,7 @@ public struct CreatePieInsightFromCallTableDto: Codable, Hashable, Sendable { /// /// You can also use the query names as the variable in the formula. public let formulas: [InsightFormula]? + /// The time range used to query the pie-chart data. public let timeRange: InsightTimeRange? /// This is the group by column for the insight when table is `call`. /// These are the columns to group the results by. diff --git a/Sources/Schemas/CreatePlayHtCredentialDto.swift b/Sources/Schemas/CreatePlayHtCredentialDto.swift index 9862065..2281033 100644 --- a/Sources/Schemas/CreatePlayHtCredentialDto.swift +++ b/Sources/Schemas/CreatePlayHtCredentialDto.swift @@ -1,8 +1,10 @@ import Foundation +/// Credentials for authenticating voice synthesis requests with PlayHT, including the PlayHT user identifier. public struct CreatePlayHtCredentialDto: Codable, Hashable, Sendable { /// This is not returned in the API. public let apiKey: String + /// PlayHT user identifier associated with the API key. public let userId: String /// This is the name of credential. This is just for your reference. public let name: String? diff --git a/Sources/Schemas/CreateQueryToolDto.swift b/Sources/Schemas/CreateQueryToolDto.swift index f092299..b2b297b 100644 --- a/Sources/Schemas/CreateQueryToolDto.swift +++ b/Sources/Schemas/CreateQueryToolDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration used to create a tool that searches configured knowledge bases and returns relevant content to the assistant. public struct CreateQueryToolDto: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/CreateRimeAiCredentialDto.swift b/Sources/Schemas/CreateRimeAiCredentialDto.swift index 626643a..20d5f8f 100644 --- a/Sources/Schemas/CreateRimeAiCredentialDto.swift +++ b/Sources/Schemas/CreateRimeAiCredentialDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Credentials for authenticating voice synthesis requests with Rime AI. public struct CreateRimeAiCredentialDto: Codable, Hashable, Sendable { /// This is not returned in the API. public let apiKey: String diff --git a/Sources/Schemas/CreateRunpodCredentialDto.swift b/Sources/Schemas/CreateRunpodCredentialDto.swift index 27f1065..1824b3d 100644 --- a/Sources/Schemas/CreateRunpodCredentialDto.swift +++ b/Sources/Schemas/CreateRunpodCredentialDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Credentials for authenticating assistant model requests through Runpod. public struct CreateRunpodCredentialDto: Codable, Hashable, Sendable { /// This is not returned in the API. public let apiKey: String diff --git a/Sources/Schemas/CreateS3CredentialDto.swift b/Sources/Schemas/CreateS3CredentialDto.swift index b77ff62..8f6f691 100644 --- a/Sources/Schemas/CreateS3CredentialDto.swift +++ b/Sources/Schemas/CreateS3CredentialDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Credentials for storing call artifacts in Amazon S3, including access keys, region, bucket, path prefix, and upload fallback order. public struct CreateS3CredentialDto: Codable, Hashable, Sendable { /// AWS access key ID. public let awsAccessKeyId: String diff --git a/Sources/Schemas/CreateScorecardDto.swift b/Sources/Schemas/CreateScorecardDto.swift index 7ffab5c..107ea5b 100644 --- a/Sources/Schemas/CreateScorecardDto.swift +++ b/Sources/Schemas/CreateScorecardDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration used to create a scorecard containing evaluation metrics, scoring conditions, and optional assistant associations. public struct CreateScorecardDto: Codable, Hashable, Sendable { /// This is the name of the scorecard. It is only for user reference and will not be used for any evaluation. public let name: String? diff --git a/Sources/Schemas/CreateSipRequestToolDto.swift b/Sources/Schemas/CreateSipRequestToolDto.swift index 61bf503..70bac07 100644 --- a/Sources/Schemas/CreateSipRequestToolDto.swift +++ b/Sources/Schemas/CreateSipRequestToolDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration used to create a tool that sends SIP `INFO`, `MESSAGE`, or `NOTIFY` requests with configured headers and body. public struct CreateSipRequestToolDto: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/CreateSlackOAuth2AuthorizationCredentialDto.swift b/Sources/Schemas/CreateSlackOAuth2AuthorizationCredentialDto.swift index 4215d62..9775daf 100644 --- a/Sources/Schemas/CreateSlackOAuth2AuthorizationCredentialDto.swift +++ b/Sources/Schemas/CreateSlackOAuth2AuthorizationCredentialDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Stored OAuth 2.0 authorization for Slack operations. public struct CreateSlackOAuth2AuthorizationCredentialDto: Codable, Hashable, Sendable { /// The authorization ID for the OAuth2 authorization public let authorizationId: String diff --git a/Sources/Schemas/CreateSlackSendMessageToolDto.swift b/Sources/Schemas/CreateSlackSendMessageToolDto.swift index ec9deb0..c43eff1 100644 --- a/Sources/Schemas/CreateSlackSendMessageToolDto.swift +++ b/Sources/Schemas/CreateSlackSendMessageToolDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration used to create a tool that lets an assistant send a message to Slack. public struct CreateSlackSendMessageToolDto: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/CreateSlackWebhookCredentialDto.swift b/Sources/Schemas/CreateSlackWebhookCredentialDto.swift index 467ecdf..9d3a7b6 100644 --- a/Sources/Schemas/CreateSlackWebhookCredentialDto.swift +++ b/Sources/Schemas/CreateSlackWebhookCredentialDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Credentials for sending Vapi alerts through a Slack incoming webhook. public struct CreateSlackWebhookCredentialDto: Codable, Hashable, Sendable { /// Slack incoming webhook URL. See https://api.slack.com/messaging/webhooks for setup instructions. This is not returned in the API. public let webhookUrl: String diff --git a/Sources/Schemas/CreateSmallestAiCredentialDto.swift b/Sources/Schemas/CreateSmallestAiCredentialDto.swift index 3a01386..2cd9e21 100644 --- a/Sources/Schemas/CreateSmallestAiCredentialDto.swift +++ b/Sources/Schemas/CreateSmallestAiCredentialDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Credentials for authenticating voice synthesis requests with Smallest AI. public struct CreateSmallestAiCredentialDto: Codable, Hashable, Sendable { /// This is not returned in the API. public let apiKey: String diff --git a/Sources/Schemas/CreateSmsToolDto.swift b/Sources/Schemas/CreateSmsToolDto.swift index 1033e92..56b93f7 100644 --- a/Sources/Schemas/CreateSmsToolDto.swift +++ b/Sources/Schemas/CreateSmsToolDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration used to create a tool that lets an assistant send an SMS message during a call. public struct CreateSmsToolDto: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/CreateSonioxCredentialDto.swift b/Sources/Schemas/CreateSonioxCredentialDto.swift index 5a83d41..fd8efca 100644 --- a/Sources/Schemas/CreateSonioxCredentialDto.swift +++ b/Sources/Schemas/CreateSonioxCredentialDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Credentials for authenticating transcription requests with Soniox. public struct CreateSonioxCredentialDto: Codable, Hashable, Sendable { /// This is not returned in the API. public let apiKey: String diff --git a/Sources/Schemas/CreateSpeechmaticsCredentialDto.swift b/Sources/Schemas/CreateSpeechmaticsCredentialDto.swift index 4b742bc..630b5c0 100644 --- a/Sources/Schemas/CreateSpeechmaticsCredentialDto.swift +++ b/Sources/Schemas/CreateSpeechmaticsCredentialDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Credentials for authenticating transcription requests with Speechmatics. public struct CreateSpeechmaticsCredentialDto: Codable, Hashable, Sendable { /// This is not returned in the API. public let apiKey: String diff --git a/Sources/Schemas/CreateSquadDto.swift b/Sources/Schemas/CreateSquadDto.swift index 551fd7c..65a5fbb 100644 --- a/Sources/Schemas/CreateSquadDto.swift +++ b/Sources/Schemas/CreateSquadDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration used to create a squad. Provide an ordered list of assistant members and optional overrides that control how the squad handles a conversation and transfers between assistants. public struct CreateSquadDto: Codable, Hashable, Sendable { /// This is the name of the squad. public let name: String? diff --git a/Sources/Schemas/CreateStructuredOutputDto.swift b/Sources/Schemas/CreateStructuredOutputDto.swift index 7598613..6e65370 100644 --- a/Sources/Schemas/CreateStructuredOutputDto.swift +++ b/Sources/Schemas/CreateStructuredOutputDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration used to create a structured-output definition that extracts validated data from calls using an AI model or regular expression. public struct CreateStructuredOutputDto: Codable, Hashable, Sendable { /// This is the type of structured output. /// diff --git a/Sources/Schemas/CreateSupabaseCredentialDto.swift b/Sources/Schemas/CreateSupabaseCredentialDto.swift index 238f7e8..5a39f40 100644 --- a/Sources/Schemas/CreateSupabaseCredentialDto.swift +++ b/Sources/Schemas/CreateSupabaseCredentialDto.swift @@ -1,8 +1,10 @@ import Foundation +/// Credentials for storing call artifacts in Supabase's S3-compatible storage, including bucket configuration and upload fallback order. public struct CreateSupabaseCredentialDto: Codable, Hashable, Sendable { /// This is the order in which this storage provider is tried during upload retries. Lower numbers are tried first in increasing order. public let fallbackIndex: Double? + /// Supabase S3-compatible bucket configuration used to store call artifacts. public let bucketPlan: SupabaseBucketPlan? /// This is the name of credential. This is just for your reference. public let name: String? diff --git a/Sources/Schemas/CreateTavusCredentialDto.swift b/Sources/Schemas/CreateTavusCredentialDto.swift index 80778c2..3246b03 100644 --- a/Sources/Schemas/CreateTavusCredentialDto.swift +++ b/Sources/Schemas/CreateTavusCredentialDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Credentials for authenticating voice synthesis requests with Tavus. public struct CreateTavusCredentialDto: Codable, Hashable, Sendable { /// This is not returned in the API. public let apiKey: String diff --git a/Sources/Schemas/CreateTelnyxPhoneNumberDto.swift b/Sources/Schemas/CreateTelnyxPhoneNumberDto.swift index 084f1af..c17418b 100644 --- a/Sources/Schemas/CreateTelnyxPhoneNumberDto.swift +++ b/Sources/Schemas/CreateTelnyxPhoneNumberDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration used to import a Telnyx phone number into Vapi with a stored credential and routing settings. public struct CreateTelnyxPhoneNumberDto: Codable, Hashable, Sendable { /// This is the fallback destination an inbound call will be transferred to if: /// 1. `assistantId` is not set diff --git a/Sources/Schemas/CreateTextEditorToolDto.swift b/Sources/Schemas/CreateTextEditorToolDto.swift index 1708223..358f770 100644 --- a/Sources/Schemas/CreateTextEditorToolDto.swift +++ b/Sources/Schemas/CreateTextEditorToolDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration used to create a tool that reads and edits text files in a configured environment. public struct CreateTextEditorToolDto: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/CreateTextInsightFromCallTableDto.swift b/Sources/Schemas/CreateTextInsightFromCallTableDto.swift index aea2b31..9c6ec50 100644 --- a/Sources/Schemas/CreateTextInsightFromCallTableDto.swift +++ b/Sources/Schemas/CreateTextInsightFromCallTableDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration used to create a text-value insight from call data using metric queries, a formula, and a time range. public struct CreateTextInsightFromCallTableDto: Codable, Hashable, Sendable { /// This is the name of the Insight. public let name: String? @@ -19,6 +20,7 @@ public struct CreateTextInsightFromCallTableDto: Codable, Hashable, Sendable { /// /// You can also use the query names as the variable in the formula. public let formula: [String: JSONValue]? + /// The time range used to query the text-value data. public let timeRange: InsightTimeRange? /// These are the queries to run to generate the insight. /// For Text Insights, we only allow a single query, or require a formula if multiple queries are provided diff --git a/Sources/Schemas/CreateTogetherAiCredentialDto.swift b/Sources/Schemas/CreateTogetherAiCredentialDto.swift index 4ac405d..79ce424 100644 --- a/Sources/Schemas/CreateTogetherAiCredentialDto.swift +++ b/Sources/Schemas/CreateTogetherAiCredentialDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Credentials for authenticating assistant model requests with Together AI. public struct CreateTogetherAiCredentialDto: Codable, Hashable, Sendable { /// This is not returned in the API. public let apiKey: String diff --git a/Sources/Schemas/CreateTransferCallToolDto.swift b/Sources/Schemas/CreateTransferCallToolDto.swift index 7616216..a1215ce 100644 --- a/Sources/Schemas/CreateTransferCallToolDto.swift +++ b/Sources/Schemas/CreateTransferCallToolDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration used to create a tool that transfers the active call to one of its configured destinations. public struct CreateTransferCallToolDto: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/CreateTrieveCredentialDto.swift b/Sources/Schemas/CreateTrieveCredentialDto.swift index 0d70c6a..1efd216 100644 --- a/Sources/Schemas/CreateTrieveCredentialDto.swift +++ b/Sources/Schemas/CreateTrieveCredentialDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Credentials for authenticating knowledge-base requests with Trieve. public struct CreateTrieveCredentialDto: Codable, Hashable, Sendable { /// This is not returned in the API. public let apiKey: String diff --git a/Sources/Schemas/CreateTwilioCredentialDto.swift b/Sources/Schemas/CreateTwilioCredentialDto.swift index 40b8379..0917f4c 100644 --- a/Sources/Schemas/CreateTwilioCredentialDto.swift +++ b/Sources/Schemas/CreateTwilioCredentialDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Credentials for authenticating telephony requests with Twilio using an account SID and either an auth token or API key credentials. public struct CreateTwilioCredentialDto: Codable, Hashable, Sendable { /// This is not returned in the API. public let authToken: String? @@ -7,6 +8,7 @@ public struct CreateTwilioCredentialDto: Codable, Hashable, Sendable { public let apiKey: String? /// This is not returned in the API. public let apiSecret: String? + /// Twilio Account SID associated with the credential. public let accountSid: String /// This is the name of credential. This is just for your reference. public let name: String? diff --git a/Sources/Schemas/CreateTwilioPhoneNumberDto.swift b/Sources/Schemas/CreateTwilioPhoneNumberDto.swift index bf2283c..f60e061 100644 --- a/Sources/Schemas/CreateTwilioPhoneNumberDto.swift +++ b/Sources/Schemas/CreateTwilioPhoneNumberDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration used to import a Twilio phone number into Vapi with its account credentials and routing settings. public struct CreateTwilioPhoneNumberDto: Codable, Hashable, Sendable { /// This is the fallback destination an inbound call will be transferred to if: /// 1. `assistantId` is not set diff --git a/Sources/Schemas/CreateVapiPhoneNumberDto.swift b/Sources/Schemas/CreateVapiPhoneNumberDto.swift index 84689f1..d39fb7b 100644 --- a/Sources/Schemas/CreateVapiPhoneNumberDto.swift +++ b/Sources/Schemas/CreateVapiPhoneNumberDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration used to provision a Vapi-managed phone number or connect a SIP URI, with optional routing and authentication settings. public struct CreateVapiPhoneNumberDto: Codable, Hashable, Sendable { /// This is the fallback destination an inbound call will be transferred to if: /// 1. `assistantId` is not set diff --git a/Sources/Schemas/CreateVoicemailToolDto.swift b/Sources/Schemas/CreateVoicemailToolDto.swift index 6ff7e25..6639d89 100644 --- a/Sources/Schemas/CreateVoicemailToolDto.swift +++ b/Sources/Schemas/CreateVoicemailToolDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration used to create a voicemail-detection tool with optional beep detection for supported calls. public struct CreateVoicemailToolDto: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/CreateVonageCredentialDto.swift b/Sources/Schemas/CreateVonageCredentialDto.swift index 5e131b2..b1cd5b1 100644 --- a/Sources/Schemas/CreateVonageCredentialDto.swift +++ b/Sources/Schemas/CreateVonageCredentialDto.swift @@ -1,8 +1,10 @@ import Foundation +/// Credentials for authenticating telephony requests with Vonage. public struct CreateVonageCredentialDto: Codable, Hashable, Sendable { /// This is not returned in the API. public let apiSecret: String + /// Vonage API key associated with the credential. public let apiKey: String /// This is the name of credential. This is just for your reference. public let name: String? diff --git a/Sources/Schemas/CreateVonagePhoneNumberDto.swift b/Sources/Schemas/CreateVonagePhoneNumberDto.swift index 72279d8..fbfff17 100644 --- a/Sources/Schemas/CreateVonagePhoneNumberDto.swift +++ b/Sources/Schemas/CreateVonagePhoneNumberDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration used to import a Vonage phone number into Vapi with a stored credential and routing settings. public struct CreateVonagePhoneNumberDto: Codable, Hashable, Sendable { /// This is the fallback destination an inbound call will be transferred to if: /// 1. `assistantId` is not set diff --git a/Sources/Schemas/CreateWellSaidCredentialDto.swift b/Sources/Schemas/CreateWellSaidCredentialDto.swift index 88368f8..220f640 100644 --- a/Sources/Schemas/CreateWellSaidCredentialDto.swift +++ b/Sources/Schemas/CreateWellSaidCredentialDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Credentials for authenticating voice synthesis requests with WellSaid. public struct CreateWellSaidCredentialDto: Codable, Hashable, Sendable { /// This is not returned in the API. public let apiKey: String diff --git a/Sources/Schemas/CreateWorkflowDto.swift b/Sources/Schemas/CreateWorkflowDto.swift index 60de558..8d7c832 100644 --- a/Sources/Schemas/CreateWorkflowDto.swift +++ b/Sources/Schemas/CreateWorkflowDto.swift @@ -1,6 +1,8 @@ import Foundation +/// Configuration for creating a graph-based workflow, including conversation and tool nodes, directed edges, global prompts, shared providers, hooks, credentials, and call behavior. public struct CreateWorkflowDto: Codable, Hashable, Sendable { + /// Nodes that make up the workflow graph. Conversation nodes interact with the customer, while tool nodes invoke configured tools. public let nodes: [CreateWorkflowDtoNodesItem] /// This is the model for the workflow. /// @@ -33,8 +35,11 @@ public struct CreateWorkflowDto: Codable, Hashable, Sendable { /// /// Default is 1800 (30 minutes), max is 43200 (12 hours), and min is 10 seconds. public let maxDurationSeconds: Double? + /// Name used to identify the workflow. public let name: String + /// Directed connections that determine transitions between nodes. public let edges: [Edge] + /// Prompt applied across the workflow's conversation nodes. public let globalPrompt: String? /// This is where Vapi will send webhooks. You can find all webhooks available along with their shape in ServerMessage schema. /// diff --git a/Sources/Schemas/CreateXAiCredentialDto.swift b/Sources/Schemas/CreateXAiCredentialDto.swift index fb4a977..93d6b8f 100644 --- a/Sources/Schemas/CreateXAiCredentialDto.swift +++ b/Sources/Schemas/CreateXAiCredentialDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Credentials for authenticating assistant model requests with xAI. public struct CreateXAiCredentialDto: Codable, Hashable, Sendable { /// This is not returned in the API. public let apiKey: String diff --git a/Sources/Schemas/CustomEndpointingModelSmartEndpointingPlan.swift b/Sources/Schemas/CustomEndpointingModelSmartEndpointingPlan.swift index 5174cfe..d9b56a7 100644 --- a/Sources/Schemas/CustomEndpointingModelSmartEndpointingPlan.swift +++ b/Sources/Schemas/CustomEndpointingModelSmartEndpointingPlan.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for using a custom endpointing model, including its provider identifier and server connection. public struct CustomEndpointingModelSmartEndpointingPlan: Codable, Hashable, Sendable { /// This is the provider for the smart endpointing plan. Use `custom-endpointing-model` for custom endpointing providers that are not natively supported. public let provider: CustomEndpointingModelSmartEndpointingPlanProvider diff --git a/Sources/Schemas/CustomLlmModel.swift b/Sources/Schemas/CustomLlmModel.swift index 5db5a33..9ad8226 100644 --- a/Sources/Schemas/CustomLlmModel.swift +++ b/Sources/Schemas/CustomLlmModel.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for generating assistant responses through a custom language model endpoint, including server URL, headers, metadata, prompts, tools, and generation settings. public struct CustomLlmModel: Codable, Hashable, Sendable { /// This is the starting state for the conversation. public let messages: [OpenAiMessage]? diff --git a/Sources/Schemas/CustomMessage.swift b/Sources/Schemas/CustomMessage.swift index ea344e3..037fc7a 100644 --- a/Sources/Schemas/CustomMessage.swift +++ b/Sources/Schemas/CustomMessage.swift @@ -1,5 +1,6 @@ import Foundation +/// A message spoken by the assistant with optional language-specific content variants. public struct CustomMessage: Codable, Hashable, Sendable { /// This is an alternative to the `content` property. It allows to specify variants of the same content, one per language. /// diff --git a/Sources/Schemas/CustomTranscriber.swift b/Sources/Schemas/CustomTranscriber.swift index 02a31ff..f81abfd 100644 --- a/Sources/Schemas/CustomTranscriber.swift +++ b/Sources/Schemas/CustomTranscriber.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for sending conversation audio to a custom WebSocket transcription server. public struct CustomTranscriber: Codable, Hashable, Sendable { /// This is where the transcription request will be sent. /// diff --git a/Sources/Schemas/CustomVoice.swift b/Sources/Schemas/CustomVoice.swift index ed247af..7241583 100644 --- a/Sources/Schemas/CustomVoice.swift +++ b/Sources/Schemas/CustomVoice.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for synthesizing assistant speech through a custom server, including voice selection, server connection, chunking, caching, and fallback settings. public struct CustomVoice: Codable, Hashable, Sendable { /// This is the flag to toggle voice caching for the assistant. public let cachingEnabled: Bool? diff --git a/Sources/Schemas/CustomerCustomEndpointingRule.swift b/Sources/Schemas/CustomerCustomEndpointingRule.swift index 94e4624..21c1e82 100644 --- a/Sources/Schemas/CustomerCustomEndpointingRule.swift +++ b/Sources/Schemas/CustomerCustomEndpointingRule.swift @@ -1,5 +1,6 @@ import Foundation +/// A custom endpointing rule that matches the customer's current speech and applies a configured timeout. public struct CustomerCustomEndpointingRule: Codable, Hashable, Sendable { /// This is the regex pattern to match. /// diff --git a/Sources/Schemas/CustomerSpeechTimeoutOptions.swift b/Sources/Schemas/CustomerSpeechTimeoutOptions.swift index cad5d0c..57fb59a 100644 --- a/Sources/Schemas/CustomerSpeechTimeoutOptions.swift +++ b/Sources/Schemas/CustomerSpeechTimeoutOptions.swift @@ -1,5 +1,6 @@ import Foundation +/// Controls how long a hook waits for customer speech, how often it can trigger, and when its trigger counter resets. public struct CustomerSpeechTimeoutOptions: Codable, Hashable, Sendable { /// This is the timeout in seconds before action is triggered. /// The clock starts when the assistant finishes speaking and remains active until the user speaks. @@ -10,9 +11,7 @@ public struct CustomerSpeechTimeoutOptions: Codable, Hashable, Sendable { /// /// @default 3 public let triggerMaxCount: Double? - /// This is whether the counter for hook trigger resets the user speaks. - /// - /// @default never + /// Controls whether the hook's trigger counter resets after the customer speaks. Defaults to `never`. public let triggerResetMode: [String: JSONValue]? /// Additional properties that are not explicitly defined in the schema public let additionalProperties: [String: JSONValue] diff --git a/Sources/Schemas/DeepInfraModel.swift b/Sources/Schemas/DeepInfraModel.swift index 631d35c..4164aab 100644 --- a/Sources/Schemas/DeepInfraModel.swift +++ b/Sources/Schemas/DeepInfraModel.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for generating assistant responses with DeepInfra, including model, prompts, tools, knowledge-base access, and generation settings. public struct DeepInfraModel: Codable, Hashable, Sendable { /// This is the starting state for the conversation. public let messages: [OpenAiMessage]? diff --git a/Sources/Schemas/DeepSeekModel.swift b/Sources/Schemas/DeepSeekModel.swift index fe35c2c..a33dcf6 100644 --- a/Sources/Schemas/DeepSeekModel.swift +++ b/Sources/Schemas/DeepSeekModel.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for generating assistant responses with DeepSeek, including model, prompts, tools, knowledge-base access, and generation settings. public struct DeepSeekModel: Codable, Hashable, Sendable { /// This is the starting state for the conversation. public let messages: [OpenAiMessage]? diff --git a/Sources/Schemas/DeepgramTranscriber.swift b/Sources/Schemas/DeepgramTranscriber.swift index 4d497ab..b73f223 100644 --- a/Sources/Schemas/DeepgramTranscriber.swift +++ b/Sources/Schemas/DeepgramTranscriber.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for transcribing speech during assistant conversations with Deepgram, including model, language, formatting, endpointing, vocabulary, and fallback settings. public struct DeepgramTranscriber: Codable, Hashable, Sendable { /// This is the Deepgram model that will be used. A list of models can be found here: https://developers.deepgram.com/docs/models-languages-overview public let model: DeepgramTranscriberModel? diff --git a/Sources/Schemas/DeepgramVoice.swift b/Sources/Schemas/DeepgramVoice.swift index 5575a08..1dc8c41 100644 --- a/Sources/Schemas/DeepgramVoice.swift +++ b/Sources/Schemas/DeepgramVoice.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for synthesizing assistant speech with Deepgram, including voice and model selection, model-improvement preferences, chunking, caching, and fallback settings. public struct DeepgramVoice: Codable, Hashable, Sendable { /// This is the flag to toggle voice caching for the assistant. public let cachingEnabled: Bool? diff --git a/Sources/Schemas/DeveloperMessage.swift b/Sources/Schemas/DeveloperMessage.swift index 9bccd0b..5ad69d9 100644 --- a/Sources/Schemas/DeveloperMessage.swift +++ b/Sources/Schemas/DeveloperMessage.swift @@ -1,5 +1,6 @@ import Foundation +/// A developer-authored instruction message supplied to the language model. public struct DeveloperMessage: Codable, Hashable, Sendable { /// This is the role of the message author public let role: DeveloperMessageRole diff --git a/Sources/Schemas/DialPlanEntry.swift b/Sources/Schemas/DialPlanEntry.swift index f4bc5d9..ed20b6d 100644 --- a/Sources/Schemas/DialPlanEntry.swift +++ b/Sources/Schemas/DialPlanEntry.swift @@ -1,5 +1,6 @@ import Foundation +/// Associates a phone number with the customers to dial through that number in a batch call plan. public struct DialPlanEntry: Codable, Hashable, Sendable { /// The phone number ID to use for calling the customers in this entry. public let phoneNumberId: String diff --git a/Sources/Schemas/DtmfTool.swift b/Sources/Schemas/DtmfTool.swift index 5635e6a..d474830 100644 --- a/Sources/Schemas/DtmfTool.swift +++ b/Sources/Schemas/DtmfTool.swift @@ -1,5 +1,6 @@ import Foundation +/// A reusable tool that lets an assistant send DTMF keypad tones during a call. public struct DtmfTool: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/Edge.swift b/Sources/Schemas/Edge.swift index 217c28b..7cac2a4 100644 --- a/Sources/Schemas/Edge.swift +++ b/Sources/Schemas/Edge.swift @@ -1,8 +1,12 @@ import Foundation +/// A directed connection between two workflow nodes, with an optional AI-evaluated transition condition. public struct Edge: Codable, Hashable, Sendable { + /// Condition that must evaluate to true to follow this edge. public let condition: AiEdgeCondition? + /// Name of the source workflow node. public let from: String + /// Name of the destination workflow node. public let to: String /// This is for metadata you want to store on the edge. public let metadata: [String: JSONValue]? diff --git a/Sources/Schemas/ElevenLabsPronunciationDictionaryLocator.swift b/Sources/Schemas/ElevenLabsPronunciationDictionaryLocator.swift index d30c911..1a74435 100644 --- a/Sources/Schemas/ElevenLabsPronunciationDictionaryLocator.swift +++ b/Sources/Schemas/ElevenLabsPronunciationDictionaryLocator.swift @@ -1,5 +1,6 @@ import Foundation +/// Identifies a specific version of an ElevenLabs pronunciation dictionary. public struct ElevenLabsPronunciationDictionaryLocator: Codable, Hashable, Sendable { /// This is the ID of the pronunciation dictionary to use. public let pronunciationDictionaryId: String diff --git a/Sources/Schemas/ElevenLabsTranscriber.swift b/Sources/Schemas/ElevenLabsTranscriber.swift index 0d89c9b..28b9a10 100644 --- a/Sources/Schemas/ElevenLabsTranscriber.swift +++ b/Sources/Schemas/ElevenLabsTranscriber.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for transcribing speech during assistant conversations with ElevenLabs, including model, language, speech thresholds, and fallback settings. public struct ElevenLabsTranscriber: Codable, Hashable, Sendable { /// This is the model that will be used for the transcription. public let model: ElevenLabsTranscriberModel? diff --git a/Sources/Schemas/ElevenLabsVoice.swift b/Sources/Schemas/ElevenLabsVoice.swift index 580cbe0..cef16e4 100644 --- a/Sources/Schemas/ElevenLabsVoice.swift +++ b/Sources/Schemas/ElevenLabsVoice.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for synthesizing assistant speech with ElevenLabs, including voice and model selection, language, voice tuning, streaming, Speech Synthesis Markup Language parsing, pronunciation dictionaries, chunking, caching, and fallback settings. public struct ElevenLabsVoice: Codable, Hashable, Sendable { /// This is the flag to toggle voice caching for the assistant. public let cachingEnabled: Bool? diff --git a/Sources/Schemas/EndCallTool.swift b/Sources/Schemas/EndCallTool.swift index 7fd933c..0465e96 100644 --- a/Sources/Schemas/EndCallTool.swift +++ b/Sources/Schemas/EndCallTool.swift @@ -1,5 +1,6 @@ import Foundation +/// A reusable tool that lets an assistant end the active call. public struct EndCallTool: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/Eval.swift b/Sources/Schemas/Eval.swift index c4b6356..9aa1fdb 100644 --- a/Sources/Schemas/Eval.swift +++ b/Sources/Schemas/Eval.swift @@ -1,5 +1,6 @@ import Foundation +/// A saved eval definition containing its mock conversation, checkpoints, descriptive metadata, type, and lifecycle information. public struct Eval: Codable, Hashable, Sendable { /// This is the mock conversation that will be used to evaluate the flow of the conversation. /// @@ -7,9 +8,13 @@ public struct Eval: Codable, Hashable, Sendable { /// /// Evaluation Messages are used as checkpoints in the flow where the model's response to previous conversation needs to be evaluated to check the content and tool calls public let messages: [EvalMessagesItem] + /// The unique identifier for the eval. public let id: String + /// The unique identifier for the organization that owns the eval. public let orgId: String + /// The ISO 8601 timestamp when the eval was created. public let createdAt: Date + /// The ISO 8601 timestamp when the eval was last updated. public let updatedAt: Date /// This is the name of the eval. /// It helps identify what the eval is checking for. diff --git a/Sources/Schemas/EvalAnthropicModel.swift b/Sources/Schemas/EvalAnthropicModel.swift index b540a21..50ce23b 100644 --- a/Sources/Schemas/EvalAnthropicModel.swift +++ b/Sources/Schemas/EvalAnthropicModel.swift @@ -1,5 +1,6 @@ import Foundation +/// Anthropic model configuration for an LLM judge, including its messages, generation settings, and optional extended thinking. public struct EvalAnthropicModel: Codable, Hashable, Sendable { /// This is the specific model that will be used. public let model: EvalAnthropicModelModel diff --git a/Sources/Schemas/EvalCustomModel.swift b/Sources/Schemas/EvalCustomModel.swift index 474af7d..04f6164 100644 --- a/Sources/Schemas/EvalCustomModel.swift +++ b/Sources/Schemas/EvalCustomModel.swift @@ -1,5 +1,6 @@ import Foundation +/// OpenAI-compatible custom model configuration for an LLM judge, including its endpoint, headers, messages, and generation settings. public struct EvalCustomModel: Codable, Hashable, Sendable { /// These is the URL we'll use for the OpenAI client's `baseURL`. Ex. https://openrouter.ai/api/v1 public let url: String diff --git a/Sources/Schemas/EvalGoogleModel.swift b/Sources/Schemas/EvalGoogleModel.swift index d5cbf5b..1d05064 100644 --- a/Sources/Schemas/EvalGoogleModel.swift +++ b/Sources/Schemas/EvalGoogleModel.swift @@ -1,5 +1,6 @@ import Foundation +/// Google model configuration for an LLM judge, including its messages and generation settings. public struct EvalGoogleModel: Codable, Hashable, Sendable { /// This is the name of the model. Ex. gpt-4o public let model: EvalGoogleModelModel diff --git a/Sources/Schemas/EvalOpenAiModel.swift b/Sources/Schemas/EvalOpenAiModel.swift index 9c6a31b..cfbc39a 100644 --- a/Sources/Schemas/EvalOpenAiModel.swift +++ b/Sources/Schemas/EvalOpenAiModel.swift @@ -1,5 +1,6 @@ import Foundation +/// OpenAI model configuration for an LLM judge, including its messages and generation settings. public struct EvalOpenAiModel: Codable, Hashable, Sendable { /// This is the OpenAI model that will be used. /// diff --git a/Sources/Schemas/EvalPaginatedResponse.swift b/Sources/Schemas/EvalPaginatedResponse.swift index 53e5300..bae4f96 100644 --- a/Sources/Schemas/EvalPaginatedResponse.swift +++ b/Sources/Schemas/EvalPaginatedResponse.swift @@ -1,7 +1,10 @@ import Foundation +/// A paginated collection of saved eval definitions and metadata describing the result set. public struct EvalPaginatedResponse: Codable, Hashable, Sendable { + /// The eval definitions returned for the current page. public let results: [Eval] + /// Pagination metadata for the eval result set. public let metadata: PaginationMeta /// Additional properties that are not explicitly defined in the schema public let additionalProperties: [String: JSONValue] diff --git a/Sources/Schemas/EvalRun.swift b/Sources/Schemas/EvalRun.swift index 836e1e0..f69697f 100644 --- a/Sources/Schemas/EvalRun.swift +++ b/Sources/Schemas/EvalRun.swift @@ -1,5 +1,6 @@ import Foundation +/// A record of an eval execution, including its target, status, results, costs, completion details, and lifecycle timestamps. public struct EvalRun: Codable, Hashable, Sendable { /// This is the status of the eval run. When an eval run is created, the status is 'running'. /// When the eval run is completed, the status is 'ended'. @@ -15,10 +16,15 @@ public struct EvalRun: Codable, Hashable, Sendable { public let eval: CreateEvalDto? /// This is the target that will be run against the eval public let target: EvalRunTarget + /// The unique identifier for the eval run. public let id: String + /// The unique identifier for the organization that owns the run. public let orgId: String + /// The ISO 8601 timestamp when the eval run was created. public let createdAt: Date + /// The ISO 8601 timestamp when the eval run started. public let startedAt: Date + /// The ISO 8601 timestamp when the eval run ended. public let endedAt: Date /// This is the ended message when the eval run ended for any reason apart from mockConversation.done public let endedMessage: String? diff --git a/Sources/Schemas/EvalRunPaginatedResponse.swift b/Sources/Schemas/EvalRunPaginatedResponse.swift index 1b4a4a4..8311844 100644 --- a/Sources/Schemas/EvalRunPaginatedResponse.swift +++ b/Sources/Schemas/EvalRunPaginatedResponse.swift @@ -1,7 +1,10 @@ import Foundation +/// A paginated collection of eval runs and metadata describing the result set. public struct EvalRunPaginatedResponse: Codable, Hashable, Sendable { + /// The eval runs returned for the current page. public let results: [EvalRun] + /// Pagination metadata for the eval-run result set. public let metadata: PaginationMeta /// Additional properties that are not explicitly defined in the schema public let additionalProperties: [String: JSONValue] diff --git a/Sources/Schemas/EvalRunResult.swift b/Sources/Schemas/EvalRunResult.swift index 8d1a756..673c0aa 100644 --- a/Sources/Schemas/EvalRunResult.swift +++ b/Sources/Schemas/EvalRunResult.swift @@ -1,5 +1,6 @@ import Foundation +/// The pass or fail result of an evaluation run, including its conversation messages and timing. public struct EvalRunResult: Codable, Hashable, Sendable { /// This is the status of the eval run result. /// The status is only 'pass' or 'fail' for an eval run result. diff --git a/Sources/Schemas/EvalRunTargetAssistant.swift b/Sources/Schemas/EvalRunTargetAssistant.swift index 48249b0..0645e36 100644 --- a/Sources/Schemas/EvalRunTargetAssistant.swift +++ b/Sources/Schemas/EvalRunTargetAssistant.swift @@ -1,5 +1,6 @@ import Foundation +/// An assistant evaluation target provided as a saved assistant ID or a transient assistant, with optional assistant overrides. public struct EvalRunTargetAssistant: Codable, Hashable, Sendable { /// This is the transient assistant that will be run against the eval public let assistant: CreateAssistantDto? diff --git a/Sources/Schemas/EvalRunTargetSquad.swift b/Sources/Schemas/EvalRunTargetSquad.swift index 7585083..770d564 100644 --- a/Sources/Schemas/EvalRunTargetSquad.swift +++ b/Sources/Schemas/EvalRunTargetSquad.swift @@ -1,5 +1,6 @@ import Foundation +/// A squad evaluation target provided as a saved squad ID or a transient squad, with optional assistant overrides. public struct EvalRunTargetSquad: Codable, Hashable, Sendable { /// This is the transient squad that will be run against the eval public let squad: CreateSquadDto? diff --git a/Sources/Schemas/EventsTableBooleanCondition.swift b/Sources/Schemas/EventsTableBooleanCondition.swift index 01bb195..913377d 100644 --- a/Sources/Schemas/EventsTableBooleanCondition.swift +++ b/Sources/Schemas/EventsTableBooleanCondition.swift @@ -1,5 +1,6 @@ import Foundation +/// Filters event data by comparing a boolean field with an expected value. public struct EventsTableBooleanCondition: Codable, Hashable, Sendable { /// The boolean field name from the event data public let column: String diff --git a/Sources/Schemas/EventsTableNumberCondition.swift b/Sources/Schemas/EventsTableNumberCondition.swift index 4e96d08..0fca0ff 100644 --- a/Sources/Schemas/EventsTableNumberCondition.swift +++ b/Sources/Schemas/EventsTableNumberCondition.swift @@ -1,5 +1,6 @@ import Foundation +/// Filters event data by comparing a numeric field with a value. public struct EventsTableNumberCondition: Codable, Hashable, Sendable { /// The number field name from the event data public let column: String diff --git a/Sources/Schemas/EventsTableStringCondition.swift b/Sources/Schemas/EventsTableStringCondition.swift index 3e05498..762a937 100644 --- a/Sources/Schemas/EventsTableStringCondition.swift +++ b/Sources/Schemas/EventsTableStringCondition.swift @@ -1,5 +1,6 @@ import Foundation +/// Filters event data by comparing or searching a string field. public struct EventsTableStringCondition: Codable, Hashable, Sendable { /// The string field name from the event data public let column: String diff --git a/Sources/Schemas/ExactReplacement.swift b/Sources/Schemas/ExactReplacement.swift index 577923e..10cfd13 100644 --- a/Sources/Schemas/ExactReplacement.swift +++ b/Sources/Schemas/ExactReplacement.swift @@ -1,5 +1,6 @@ import Foundation +/// Replaces an exact word or phrase before text is sent to a voice provider. public struct ExactReplacement: Codable, Hashable, Sendable { /// This option let's you control whether to replace all instances of the key or only the first one. By default, it only replaces the first instance. /// Examples: diff --git a/Sources/Schemas/FallbackAssemblyAiTranscriber.swift b/Sources/Schemas/FallbackAssemblyAiTranscriber.swift index 004cf82..0de6a48 100644 --- a/Sources/Schemas/FallbackAssemblyAiTranscriber.swift +++ b/Sources/Schemas/FallbackAssemblyAiTranscriber.swift @@ -1,5 +1,6 @@ import Foundation +/// Fallback configuration for transcribing speech with AssemblyAI, including language, streaming model, endpointing, and vocabulary. public struct FallbackAssemblyAiTranscriber: Codable, Hashable, Sendable { /// This is the language that will be set for the transcription. public let language: FallbackAssemblyAiTranscriberLanguage? diff --git a/Sources/Schemas/FallbackAzureSpeechTranscriber.swift b/Sources/Schemas/FallbackAzureSpeechTranscriber.swift index a415359..d6f524e 100644 --- a/Sources/Schemas/FallbackAzureSpeechTranscriber.swift +++ b/Sources/Schemas/FallbackAzureSpeechTranscriber.swift @@ -1,5 +1,6 @@ import Foundation +/// Fallback configuration for transcribing speech with Azure Speech, including language and segmentation. public struct FallbackAzureSpeechTranscriber: Codable, Hashable, Sendable { /// This is the language that will be set for the transcription. The list of languages Azure supports can be found here: https://learn.microsoft.com/en-us/azure/ai-services/speech-service/language-support?tabs=stt public let language: FallbackAzureSpeechTranscriberLanguage? diff --git a/Sources/Schemas/FallbackAzureVoice.swift b/Sources/Schemas/FallbackAzureVoice.swift index 4e36939..2b31d15 100644 --- a/Sources/Schemas/FallbackAzureVoice.swift +++ b/Sources/Schemas/FallbackAzureVoice.swift @@ -1,5 +1,6 @@ import Foundation +/// Fallback configuration for synthesizing assistant speech with Azure, including voice selection, speed, chunking, and caching. public struct FallbackAzureVoice: Codable, Hashable, Sendable { /// This is the flag to toggle voice caching for the assistant. public let cachingEnabled: Bool? diff --git a/Sources/Schemas/FallbackCartesiaTranscriber.swift b/Sources/Schemas/FallbackCartesiaTranscriber.swift index b02fa63..f8d1238 100644 --- a/Sources/Schemas/FallbackCartesiaTranscriber.swift +++ b/Sources/Schemas/FallbackCartesiaTranscriber.swift @@ -1,7 +1,10 @@ import Foundation +/// Fallback configuration for transcribing speech with Cartesia, including model and language. public struct FallbackCartesiaTranscriber: Codable, Hashable, Sendable { + /// The Cartesia speech-to-text model used for transcription. public let model: FallbackCartesiaTranscriberModel? + /// The language code used for transcription. public let language: FallbackCartesiaTranscriberLanguage? /// Additional properties that are not explicitly defined in the schema public let additionalProperties: [String: JSONValue] diff --git a/Sources/Schemas/FallbackCartesiaTranscriberLanguage.swift b/Sources/Schemas/FallbackCartesiaTranscriberLanguage.swift index b43fa0e..f5e0a15 100644 --- a/Sources/Schemas/FallbackCartesiaTranscriberLanguage.swift +++ b/Sources/Schemas/FallbackCartesiaTranscriberLanguage.swift @@ -1,5 +1,6 @@ import Foundation +/// The language code used for transcription. public enum FallbackCartesiaTranscriberLanguage: String, Codable, Hashable, CaseIterable, Sendable { case aa case ab diff --git a/Sources/Schemas/FallbackCartesiaTranscriberModel.swift b/Sources/Schemas/FallbackCartesiaTranscriberModel.swift index 28cdcd1..df23e4f 100644 --- a/Sources/Schemas/FallbackCartesiaTranscriberModel.swift +++ b/Sources/Schemas/FallbackCartesiaTranscriberModel.swift @@ -1,5 +1,6 @@ import Foundation +/// The Cartesia speech-to-text model used for transcription. public enum FallbackCartesiaTranscriberModel: String, Codable, Hashable, CaseIterable, Sendable { case inkWhisper = "ink-whisper" } \ No newline at end of file diff --git a/Sources/Schemas/FallbackCartesiaVoice.swift b/Sources/Schemas/FallbackCartesiaVoice.swift index 783a045..b378372 100644 --- a/Sources/Schemas/FallbackCartesiaVoice.swift +++ b/Sources/Schemas/FallbackCartesiaVoice.swift @@ -1,5 +1,6 @@ import Foundation +/// Fallback configuration for synthesizing assistant speech with Cartesia, including voice and model selection, language, generation controls, pronunciation dictionaries, chunking, and caching. public struct FallbackCartesiaVoice: Codable, Hashable, Sendable { /// This is the flag to toggle voice caching for the assistant. public let cachingEnabled: Bool? diff --git a/Sources/Schemas/FallbackCustomTranscriber.swift b/Sources/Schemas/FallbackCustomTranscriber.swift index c8af0e3..c95a5a5 100644 --- a/Sources/Schemas/FallbackCustomTranscriber.swift +++ b/Sources/Schemas/FallbackCustomTranscriber.swift @@ -1,5 +1,6 @@ import Foundation +/// Fallback configuration for sending conversation audio to a custom WebSocket transcription server. public struct FallbackCustomTranscriber: Codable, Hashable, Sendable { /// This is where the transcription request will be sent. /// diff --git a/Sources/Schemas/FallbackCustomVoice.swift b/Sources/Schemas/FallbackCustomVoice.swift index 4359015..68f28f1 100644 --- a/Sources/Schemas/FallbackCustomVoice.swift +++ b/Sources/Schemas/FallbackCustomVoice.swift @@ -1,5 +1,6 @@ import Foundation +/// Fallback configuration for synthesizing assistant speech through a custom server, including voice selection, server connection, chunking, and caching. public struct FallbackCustomVoice: Codable, Hashable, Sendable { /// This is the flag to toggle voice caching for the assistant. public let cachingEnabled: Bool? diff --git a/Sources/Schemas/FallbackDeepgramTranscriber.swift b/Sources/Schemas/FallbackDeepgramTranscriber.swift index ae6482e..5f1208b 100644 --- a/Sources/Schemas/FallbackDeepgramTranscriber.swift +++ b/Sources/Schemas/FallbackDeepgramTranscriber.swift @@ -1,5 +1,6 @@ import Foundation +/// Fallback configuration for transcribing speech with Deepgram, including model, language, formatting, endpointing, and vocabulary. public struct FallbackDeepgramTranscriber: Codable, Hashable, Sendable { /// This is the Deepgram model that will be used. A list of models can be found here: https://developers.deepgram.com/docs/models-languages-overview public let model: DeepgramTranscriberModel? diff --git a/Sources/Schemas/FallbackDeepgramVoice.swift b/Sources/Schemas/FallbackDeepgramVoice.swift index 628c490..56fbceb 100644 --- a/Sources/Schemas/FallbackDeepgramVoice.swift +++ b/Sources/Schemas/FallbackDeepgramVoice.swift @@ -1,5 +1,6 @@ import Foundation +/// Fallback configuration for synthesizing assistant speech with Deepgram, including voice and model selection, model-improvement preferences, chunking, and caching. public struct FallbackDeepgramVoice: Codable, Hashable, Sendable { /// This is the flag to toggle voice caching for the assistant. public let cachingEnabled: Bool? diff --git a/Sources/Schemas/FallbackElevenLabsTranscriber.swift b/Sources/Schemas/FallbackElevenLabsTranscriber.swift index b853547..cf32deb 100644 --- a/Sources/Schemas/FallbackElevenLabsTranscriber.swift +++ b/Sources/Schemas/FallbackElevenLabsTranscriber.swift @@ -1,5 +1,6 @@ import Foundation +/// Fallback configuration for transcribing speech with ElevenLabs, including model, language, and speech thresholds. public struct FallbackElevenLabsTranscriber: Codable, Hashable, Sendable { /// This is the model that will be used for the transcription. public let model: FallbackElevenLabsTranscriberModel? diff --git a/Sources/Schemas/FallbackElevenLabsVoice.swift b/Sources/Schemas/FallbackElevenLabsVoice.swift index 160ef1f..b595793 100644 --- a/Sources/Schemas/FallbackElevenLabsVoice.swift +++ b/Sources/Schemas/FallbackElevenLabsVoice.swift @@ -1,5 +1,6 @@ import Foundation +/// Fallback configuration for synthesizing assistant speech with ElevenLabs, including voice and model selection, language, voice tuning, streaming, Speech Synthesis Markup Language parsing, pronunciation dictionaries, chunking, and caching. public struct FallbackElevenLabsVoice: Codable, Hashable, Sendable { /// This is the flag to toggle voice caching for the assistant. public let cachingEnabled: Bool? diff --git a/Sources/Schemas/FallbackGladiaTranscriber.swift b/Sources/Schemas/FallbackGladiaTranscriber.swift index f2fbd2c..17cb847 100644 --- a/Sources/Schemas/FallbackGladiaTranscriber.swift +++ b/Sources/Schemas/FallbackGladiaTranscriber.swift @@ -1,5 +1,6 @@ import Foundation +/// Fallback configuration for transcribing speech with Gladia, including language behavior, audio processing, endpointing, vocabulary, and region. public struct FallbackGladiaTranscriber: Codable, Hashable, Sendable { /// This is the Gladia model that will be used. Default is 'fast' public let model: FallbackGladiaTranscriberModel? diff --git a/Sources/Schemas/FallbackGoogleTranscriber.swift b/Sources/Schemas/FallbackGoogleTranscriber.swift index ecc0abd..50cbdb1 100644 --- a/Sources/Schemas/FallbackGoogleTranscriber.swift +++ b/Sources/Schemas/FallbackGoogleTranscriber.swift @@ -1,5 +1,6 @@ import Foundation +/// Fallback configuration for transcribing speech with Google, including model and language. public struct FallbackGoogleTranscriber: Codable, Hashable, Sendable { /// This is the model that will be used for the transcription. public let model: FallbackGoogleTranscriberModel? diff --git a/Sources/Schemas/FallbackHumeVoice.swift b/Sources/Schemas/FallbackHumeVoice.swift index c0abd58..d7b66a6 100644 --- a/Sources/Schemas/FallbackHumeVoice.swift +++ b/Sources/Schemas/FallbackHumeVoice.swift @@ -1,5 +1,6 @@ import Foundation +/// Fallback configuration for synthesizing assistant speech with Hume, including model and voice selection, custom voice metadata, chunking, and caching. public struct FallbackHumeVoice: Codable, Hashable, Sendable { /// This is the flag to toggle voice caching for the assistant. public let cachingEnabled: Bool? diff --git a/Sources/Schemas/FallbackInworldVoice.swift b/Sources/Schemas/FallbackInworldVoice.swift index e696586..d8f0f62 100644 --- a/Sources/Schemas/FallbackInworldVoice.swift +++ b/Sources/Schemas/FallbackInworldVoice.swift @@ -1,5 +1,6 @@ import Foundation +/// Fallback configuration for synthesizing assistant speech with Inworld, including voice and model selection, language, temperature, speaking rate, chunking, and caching. public struct FallbackInworldVoice: Codable, Hashable, Sendable { /// This is the flag to toggle voice caching for the assistant. public let cachingEnabled: Bool? diff --git a/Sources/Schemas/FallbackLmntVoice.swift b/Sources/Schemas/FallbackLmntVoice.swift index 70bfb96..fca568f 100644 --- a/Sources/Schemas/FallbackLmntVoice.swift +++ b/Sources/Schemas/FallbackLmntVoice.swift @@ -1,5 +1,6 @@ import Foundation +/// Fallback configuration for synthesizing assistant speech with LMNT, including voice selection, language, speed, chunking, and caching. public struct FallbackLmntVoice: Codable, Hashable, Sendable { /// This is the flag to toggle voice caching for the assistant. public let cachingEnabled: Bool? diff --git a/Sources/Schemas/FallbackNeuphonicVoice.swift b/Sources/Schemas/FallbackNeuphonicVoice.swift index 57ad826..3e869d9 100644 --- a/Sources/Schemas/FallbackNeuphonicVoice.swift +++ b/Sources/Schemas/FallbackNeuphonicVoice.swift @@ -1,5 +1,6 @@ import Foundation +/// Fallback configuration for synthesizing assistant speech with Neuphonic, including voice and model selection, language, speed, chunking, and caching. public struct FallbackNeuphonicVoice: Codable, Hashable, Sendable { /// This is the flag to toggle voice caching for the assistant. public let cachingEnabled: Bool? diff --git a/Sources/Schemas/FallbackOpenAiTranscriber.swift b/Sources/Schemas/FallbackOpenAiTranscriber.swift index 39b5f64..4993c17 100644 --- a/Sources/Schemas/FallbackOpenAiTranscriber.swift +++ b/Sources/Schemas/FallbackOpenAiTranscriber.swift @@ -1,5 +1,6 @@ import Foundation +/// Fallback configuration for transcribing speech with OpenAI, including model and language. public struct FallbackOpenAiTranscriber: Codable, Hashable, Sendable { /// This is the model that will be used for the transcription. public let model: FallbackOpenAiTranscriberModel diff --git a/Sources/Schemas/FallbackOpenAiVoice.swift b/Sources/Schemas/FallbackOpenAiVoice.swift index 8ec1042..f2cc832 100644 --- a/Sources/Schemas/FallbackOpenAiVoice.swift +++ b/Sources/Schemas/FallbackOpenAiVoice.swift @@ -1,5 +1,6 @@ import Foundation +/// Fallback configuration for synthesizing assistant speech with OpenAI, including voice and model selection, delivery instructions, speed, chunking, and caching. public struct FallbackOpenAiVoice: Codable, Hashable, Sendable { /// This is the flag to toggle voice caching for the assistant. public let cachingEnabled: Bool? diff --git a/Sources/Schemas/FallbackPlan.swift b/Sources/Schemas/FallbackPlan.swift index 26f3b5a..4b88181 100644 --- a/Sources/Schemas/FallbackPlan.swift +++ b/Sources/Schemas/FallbackPlan.swift @@ -1,5 +1,6 @@ import Foundation +/// Lists backup voice configurations that can be used if the primary voice provider fails. public struct FallbackPlan: Codable, Hashable, Sendable { /// This is the list of voices to fallback to in the event that the primary voice provider fails. public let voices: [FallbackPlanVoicesItem] diff --git a/Sources/Schemas/FallbackPlayHtVoice.swift b/Sources/Schemas/FallbackPlayHtVoice.swift index 5eb8178..fcc8deb 100644 --- a/Sources/Schemas/FallbackPlayHtVoice.swift +++ b/Sources/Schemas/FallbackPlayHtVoice.swift @@ -1,5 +1,6 @@ import Foundation +/// Fallback configuration for synthesizing assistant speech with PlayHT, including voice and model selection, language, emotion and style guidance, chunking, and caching. public struct FallbackPlayHtVoice: Codable, Hashable, Sendable { /// This is the flag to toggle voice caching for the assistant. public let cachingEnabled: Bool? diff --git a/Sources/Schemas/FallbackRimeAiVoice.swift b/Sources/Schemas/FallbackRimeAiVoice.swift index 1ebd443..c64e1f7 100644 --- a/Sources/Schemas/FallbackRimeAiVoice.swift +++ b/Sources/Schemas/FallbackRimeAiVoice.swift @@ -1,5 +1,6 @@ import Foundation +/// Fallback configuration for synthesizing assistant speech with Rime AI, including voice and model selection, language, speed, pauses, phonemization, latency, chunking, and caching. public struct FallbackRimeAiVoice: Codable, Hashable, Sendable { /// This is the flag to toggle voice caching for the assistant. public let cachingEnabled: Bool? diff --git a/Sources/Schemas/FallbackSesameVoice.swift b/Sources/Schemas/FallbackSesameVoice.swift index 73706a6..deef244 100644 --- a/Sources/Schemas/FallbackSesameVoice.swift +++ b/Sources/Schemas/FallbackSesameVoice.swift @@ -1,5 +1,6 @@ import Foundation +/// Fallback configuration for synthesizing assistant speech with Sesame, including voice and model selection, chunking, and caching. public struct FallbackSesameVoice: Codable, Hashable, Sendable { /// This is the flag to toggle voice caching for the assistant. public let cachingEnabled: Bool? diff --git a/Sources/Schemas/FallbackSmallestAiVoice.swift b/Sources/Schemas/FallbackSmallestAiVoice.swift index 4253c9e..38c8fcc 100644 --- a/Sources/Schemas/FallbackSmallestAiVoice.swift +++ b/Sources/Schemas/FallbackSmallestAiVoice.swift @@ -1,5 +1,6 @@ import Foundation +/// Fallback configuration for synthesizing assistant speech with Smallest AI, including voice and model selection, speed, chunking, and caching. public struct FallbackSmallestAiVoice: Codable, Hashable, Sendable { /// This is the flag to toggle voice caching for the assistant. public let cachingEnabled: Bool? diff --git a/Sources/Schemas/FallbackSonioxTranscriber.swift b/Sources/Schemas/FallbackSonioxTranscriber.swift index 7d067f9..ac277a9 100644 --- a/Sources/Schemas/FallbackSonioxTranscriber.swift +++ b/Sources/Schemas/FallbackSonioxTranscriber.swift @@ -1,5 +1,6 @@ import Foundation +/// Fallback configuration for transcribing speech with Soniox, including model, language detection, endpointing, and vocabulary. public struct FallbackSonioxTranscriber: Codable, Hashable, Sendable { /// The Soniox model to use for transcription. public let model: FallbackSonioxTranscriberModel? diff --git a/Sources/Schemas/FallbackSpeechmaticsTranscriber.swift b/Sources/Schemas/FallbackSpeechmaticsTranscriber.swift index a5fad24..34a9d26 100644 --- a/Sources/Schemas/FallbackSpeechmaticsTranscriber.swift +++ b/Sources/Schemas/FallbackSpeechmaticsTranscriber.swift @@ -1,8 +1,10 @@ import Foundation +/// Fallback configuration for transcribing speech with Speechmatics, including language, region, diarization, vocabulary, endpointing, and formatting. public struct FallbackSpeechmaticsTranscriber: Codable, Hashable, Sendable { /// This is the model that will be used for the transcription. public let model: FallbackSpeechmaticsTranscriberModel? + /// Language used for transcription. Set to `auto` to detect the language automatically. public let language: FallbackSpeechmaticsTranscriberLanguage? /// This is the operating point for the transcription. Choose between `standard` for faster turnaround with strong accuracy or `enhanced` for highest accuracy when precision is critical. /// @@ -20,6 +22,7 @@ public struct FallbackSpeechmaticsTranscriber: Codable, Hashable, Sendable { /// /// @default 3000 public let maxDelay: Double? + /// Words and phrases that Speechmatics should recognize more accurately, with optional phonetic alternatives. public let customVocabulary: [SpeechmaticsCustomVocabularyItem] /// This controls how numbers, dates, currencies, and other entities are formatted in the transcription output. /// diff --git a/Sources/Schemas/FallbackSpeechmaticsTranscriberLanguage.swift b/Sources/Schemas/FallbackSpeechmaticsTranscriberLanguage.swift index b3da226..27fe43b 100644 --- a/Sources/Schemas/FallbackSpeechmaticsTranscriberLanguage.swift +++ b/Sources/Schemas/FallbackSpeechmaticsTranscriberLanguage.swift @@ -1,5 +1,6 @@ import Foundation +/// Language used for transcription. Set to `auto` to detect the language automatically. public enum FallbackSpeechmaticsTranscriberLanguage: String, Codable, Hashable, CaseIterable, Sendable { case auto case ar diff --git a/Sources/Schemas/FallbackTalkscriberTranscriber.swift b/Sources/Schemas/FallbackTalkscriberTranscriber.swift index 868a15a..b07749f 100644 --- a/Sources/Schemas/FallbackTalkscriberTranscriber.swift +++ b/Sources/Schemas/FallbackTalkscriberTranscriber.swift @@ -1,5 +1,6 @@ import Foundation +/// Fallback configuration for transcribing speech with Talkscriber, including model and language. public struct FallbackTalkscriberTranscriber: Codable, Hashable, Sendable { /// This is the model that will be used for the transcription. public let model: FallbackTalkscriberTranscriberModel? diff --git a/Sources/Schemas/FallbackTavusVoice.swift b/Sources/Schemas/FallbackTavusVoice.swift index b229204..83d330e 100644 --- a/Sources/Schemas/FallbackTavusVoice.swift +++ b/Sources/Schemas/FallbackTavusVoice.swift @@ -1,5 +1,6 @@ import Foundation +/// Fallback configuration for using Tavus as the assistant's voice provider, including persona, callback, context, greeting, conversation properties, chunking, and caching. public struct FallbackTavusVoice: Codable, Hashable, Sendable { /// This is the flag to toggle voice caching for the assistant. public let cachingEnabled: Bool? diff --git a/Sources/Schemas/FallbackTranscriberPlan.swift b/Sources/Schemas/FallbackTranscriberPlan.swift index 397858c..ef3ecbf 100644 --- a/Sources/Schemas/FallbackTranscriberPlan.swift +++ b/Sources/Schemas/FallbackTranscriberPlan.swift @@ -1,6 +1,8 @@ import Foundation +/// Lists backup transcriber configurations that can be used if the primary transcriber fails. public struct FallbackTranscriberPlan: Codable, Hashable, Sendable { + /// Transcriber configurations available when the primary transcriber fails. public let transcribers: [FallbackTranscriberPlanTranscribersItem] /// Additional properties that are not explicitly defined in the schema public let additionalProperties: [String: JSONValue] diff --git a/Sources/Schemas/FallbackVapiVoice.swift b/Sources/Schemas/FallbackVapiVoice.swift index 92952d7..9c8ea07 100644 --- a/Sources/Schemas/FallbackVapiVoice.swift +++ b/Sources/Schemas/FallbackVapiVoice.swift @@ -1,5 +1,6 @@ import Foundation +/// Fallback configuration for synthesizing assistant speech with Vapi, including voice selection, speed, pronunciation dictionary, chunking, and caching. public struct FallbackVapiVoice: Codable, Hashable, Sendable { /// This is the flag to toggle voice caching for the assistant. public let cachingEnabled: Bool? diff --git a/Sources/Schemas/FallbackWellSaidVoice.swift b/Sources/Schemas/FallbackWellSaidVoice.swift index a785314..03bd8af 100644 --- a/Sources/Schemas/FallbackWellSaidVoice.swift +++ b/Sources/Schemas/FallbackWellSaidVoice.swift @@ -1,5 +1,6 @@ import Foundation +/// Fallback configuration for synthesizing assistant speech with WellSaid, including voice and model selection, Speech Synthesis Markup Language support, voice libraries, chunking, and caching. public struct FallbackWellSaidVoice: Codable, Hashable, Sendable { /// This is the flag to toggle voice caching for the assistant. public let cachingEnabled: Bool? diff --git a/Sources/Schemas/File.swift b/Sources/Schemas/File.swift index 935c9ec..73cfee0 100644 --- a/Sources/Schemas/File.swift +++ b/Sources/Schemas/File.swift @@ -1,20 +1,34 @@ import Foundation +/// An uploaded file record, including its processing status, storage details, extracted-text location, metadata, and lifecycle timestamps. public struct File: Codable, Hashable, Sendable { + /// The object type. This is always `file`. public let object: FileObject? + /// The current processing status of the uploaded file. public let status: FileStatus? /// This is the name of the file. This is just for your own reference. public let name: String? + /// The original name of the uploaded file. public let originalName: String? + /// The size of the uploaded file in bytes. public let bytes: Double? + /// The intended use assigned to the uploaded file. public let purpose: String? + /// The MIME type of the uploaded file. public let mimetype: String? + /// The object-storage key for the uploaded file. public let key: String? + /// The object-storage path for the uploaded file. public let path: String? + /// The object-storage bucket containing the uploaded file. public let bucket: String? + /// The URL used to access the uploaded file. public let url: String? + /// The URL used to access text extracted from the file. public let parsedTextUrl: String? + /// The size of the extracted text in bytes. public let parsedTextBytes: Double? + /// Additional metadata associated with the uploaded file. public let metadata: [String: JSONValue]? /// This is the unique identifier for the file. public let id: String diff --git a/Sources/Schemas/FileObject.swift b/Sources/Schemas/FileObject.swift index b442eb3..233d79b 100644 --- a/Sources/Schemas/FileObject.swift +++ b/Sources/Schemas/FileObject.swift @@ -1,5 +1,6 @@ import Foundation +/// The object type. This is always `file`. public enum FileObject: String, Codable, Hashable, CaseIterable, Sendable { case file } \ No newline at end of file diff --git a/Sources/Schemas/FileStatus.swift b/Sources/Schemas/FileStatus.swift index e795e5e..61ce031 100644 --- a/Sources/Schemas/FileStatus.swift +++ b/Sources/Schemas/FileStatus.swift @@ -1,5 +1,6 @@ import Foundation +/// The current processing status of the uploaded file. public enum FileStatus: String, Codable, Hashable, CaseIterable, Sendable { case processing case done diff --git a/Sources/Schemas/FilterDateTypeColumnOnCallTable.swift b/Sources/Schemas/FilterDateTypeColumnOnCallTable.swift index 6b4ce59..6d45261 100644 --- a/Sources/Schemas/FilterDateTypeColumnOnCallTable.swift +++ b/Sources/Schemas/FilterDateTypeColumnOnCallTable.swift @@ -1,5 +1,6 @@ import Foundation +/// Filters call records by comparing a start or end timestamp with a date. public struct FilterDateTypeColumnOnCallTable: Codable, Hashable, Sendable { /// This is the column in the call table that will be filtered on. /// Date Type columns are columns where the rows store data as a date. diff --git a/Sources/Schemas/FilterNumberArrayTypeColumnOnCallTable.swift b/Sources/Schemas/FilterNumberArrayTypeColumnOnCallTable.swift index c433c16..72e0ca1 100644 --- a/Sources/Schemas/FilterNumberArrayTypeColumnOnCallTable.swift +++ b/Sources/Schemas/FilterNumberArrayTypeColumnOnCallTable.swift @@ -1,5 +1,6 @@ import Foundation +/// Filters numeric call fields using a list of values or an emptiness test. public struct FilterNumberArrayTypeColumnOnCallTable: Codable, Hashable, Sendable { /// This is the column in the call table that will be filtered on. /// Number Array Type columns are the same as Number Type columns, but provides the ability to filter on multiple values provided as an array. diff --git a/Sources/Schemas/FilterNumberTypeColumnOnCallTable.swift b/Sources/Schemas/FilterNumberTypeColumnOnCallTable.swift index 4b2f681..3447001 100644 --- a/Sources/Schemas/FilterNumberTypeColumnOnCallTable.swift +++ b/Sources/Schemas/FilterNumberTypeColumnOnCallTable.swift @@ -1,5 +1,6 @@ import Foundation +/// Filters call records by comparing a numeric field with a value. public struct FilterNumberTypeColumnOnCallTable: Codable, Hashable, Sendable { /// This is the column in the call table that will be filtered on. /// Number Type columns are columns where the rows store data as a number. diff --git a/Sources/Schemas/FilterStringArrayTypeColumnOnCallTable.swift b/Sources/Schemas/FilterStringArrayTypeColumnOnCallTable.swift index dc8f799..a4487e0 100644 --- a/Sources/Schemas/FilterStringArrayTypeColumnOnCallTable.swift +++ b/Sources/Schemas/FilterStringArrayTypeColumnOnCallTable.swift @@ -1,5 +1,6 @@ import Foundation +/// Filters string-valued call fields using a list of values or an emptiness test. public struct FilterStringArrayTypeColumnOnCallTable: Codable, Hashable, Sendable { /// This is the column in the call table that will be filtered on. /// String Array Type columns are the same as String Type columns, but provides the ability to filter on multiple values provided as an array. diff --git a/Sources/Schemas/FilterStringTypeColumnOnCallTable.swift b/Sources/Schemas/FilterStringTypeColumnOnCallTable.swift index 04bc52a..cc46e12 100644 --- a/Sources/Schemas/FilterStringTypeColumnOnCallTable.swift +++ b/Sources/Schemas/FilterStringTypeColumnOnCallTable.swift @@ -1,5 +1,6 @@ import Foundation +/// Filters call records by comparing or searching a string-valued field. public struct FilterStringTypeColumnOnCallTable: Codable, Hashable, Sendable { /// This is the column in the call table that will be filtered on. /// String Type columns are columns where the rows store data as a string. diff --git a/Sources/Schemas/FilterStructuredOutputColumnOnCallTable.swift b/Sources/Schemas/FilterStructuredOutputColumnOnCallTable.swift index aefacc2..a7d1dd9 100644 --- a/Sources/Schemas/FilterStructuredOutputColumnOnCallTable.swift +++ b/Sources/Schemas/FilterStructuredOutputColumnOnCallTable.swift @@ -1,5 +1,6 @@ import Foundation +/// Filters a structured-output value stored on a call using comparison, membership, containment, or emptiness operators. public struct FilterStructuredOutputColumnOnCallTable: Codable, Hashable, Sendable { /// This is the column in the call table that will be filtered on. /// Structured Output Type columns are only to filter on artifact.structuredOutputs[OutputID] column. diff --git a/Sources/Schemas/FormatPlan.swift b/Sources/Schemas/FormatPlan.swift index 1620759..9b9c821 100644 --- a/Sources/Schemas/FormatPlan.swift +++ b/Sources/Schemas/FormatPlan.swift @@ -1,5 +1,6 @@ import Foundation +/// Controls text normalization before voice synthesis, including built-in formatters, number handling, and custom replacements. public struct FormatPlan: Codable, Hashable, Sendable { /// This determines whether the chunk is formatted before being sent to the voice provider. This helps with enunciation. This includes phone numbers, emails and addresses. Default `true`. /// diff --git a/Sources/Schemas/FourierDenoisingPlan.swift b/Sources/Schemas/FourierDenoisingPlan.swift index e4e716d..31c1312 100644 --- a/Sources/Schemas/FourierDenoisingPlan.swift +++ b/Sources/Schemas/FourierDenoisingPlan.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for Fourier denoising, including media detection, thresholds, baseline calculation, and analysis window. public struct FourierDenoisingPlan: Codable, Hashable, Sendable { /// Whether Fourier denoising is enabled. Note that this is experimental and may not work as expected. public let enabled: Bool? diff --git a/Sources/Schemas/FunctionTool.swift b/Sources/Schemas/FunctionTool.swift index 5063c98..1e6191b 100644 --- a/Sources/Schemas/FunctionTool.swift +++ b/Sources/Schemas/FunctionTool.swift @@ -1,5 +1,6 @@ import Foundation +/// A reusable custom function tool that sends model-generated arguments to a configured server and returns the result to the assistant. public struct FunctionTool: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/GcpKey.swift b/Sources/Schemas/GcpKey.swift index 17ac5c9..215b8d3 100644 --- a/Sources/Schemas/GcpKey.swift +++ b/Sources/Schemas/GcpKey.swift @@ -1,5 +1,6 @@ import Foundation +/// Google Cloud service-account key used to authenticate access to Google Cloud resources. public struct GcpKey: Codable, Hashable, Sendable { /// This is the type of the key. Most likely, this is "service_account". public let type: String diff --git a/Sources/Schemas/GeminiMultimodalLivePrebuiltVoiceConfig.swift b/Sources/Schemas/GeminiMultimodalLivePrebuiltVoiceConfig.swift index a81b9cc..cabc67e 100644 --- a/Sources/Schemas/GeminiMultimodalLivePrebuiltVoiceConfig.swift +++ b/Sources/Schemas/GeminiMultimodalLivePrebuiltVoiceConfig.swift @@ -1,6 +1,8 @@ import Foundation +/// Selects a prebuilt voice for Gemini Multimodal Live audio output. public struct GeminiMultimodalLivePrebuiltVoiceConfig: Codable, Hashable, Sendable { + /// Prebuilt Gemini voice used for audio output. public let voiceName: GeminiMultimodalLivePrebuiltVoiceConfigVoiceName /// Additional properties that are not explicitly defined in the schema public let additionalProperties: [String: JSONValue] diff --git a/Sources/Schemas/GeminiMultimodalLivePrebuiltVoiceConfigVoiceName.swift b/Sources/Schemas/GeminiMultimodalLivePrebuiltVoiceConfigVoiceName.swift index e05ccfa..e5437e1 100644 --- a/Sources/Schemas/GeminiMultimodalLivePrebuiltVoiceConfigVoiceName.swift +++ b/Sources/Schemas/GeminiMultimodalLivePrebuiltVoiceConfigVoiceName.swift @@ -1,5 +1,6 @@ import Foundation +/// Prebuilt Gemini voice used for audio output. public enum GeminiMultimodalLivePrebuiltVoiceConfigVoiceName: String, Codable, Hashable, CaseIterable, Sendable { case puck = "Puck" case charon = "Charon" diff --git a/Sources/Schemas/GeminiMultimodalLiveSpeechConfig.swift b/Sources/Schemas/GeminiMultimodalLiveSpeechConfig.swift index 4c8780f..2f48b25 100644 --- a/Sources/Schemas/GeminiMultimodalLiveSpeechConfig.swift +++ b/Sources/Schemas/GeminiMultimodalLiveSpeechConfig.swift @@ -1,6 +1,8 @@ import Foundation +/// Speech-output configuration for Gemini Multimodal Live. public struct GeminiMultimodalLiveSpeechConfig: Codable, Hashable, Sendable { + /// Voice configuration used for Gemini Multimodal Live speech output. public let voiceConfig: GeminiMultimodalLiveVoiceConfig /// Additional properties that are not explicitly defined in the schema public let additionalProperties: [String: JSONValue] diff --git a/Sources/Schemas/GeminiMultimodalLiveVoiceConfig.swift b/Sources/Schemas/GeminiMultimodalLiveVoiceConfig.swift index 63ace78..d208df5 100644 --- a/Sources/Schemas/GeminiMultimodalLiveVoiceConfig.swift +++ b/Sources/Schemas/GeminiMultimodalLiveVoiceConfig.swift @@ -1,6 +1,8 @@ import Foundation +/// Voice selection configuration for Gemini Multimodal Live. public struct GeminiMultimodalLiveVoiceConfig: Codable, Hashable, Sendable { + /// Prebuilt voice used for Gemini Multimodal Live speech output. public let prebuiltVoiceConfig: GeminiMultimodalLivePrebuiltVoiceConfig /// Additional properties that are not explicitly defined in the schema public let additionalProperties: [String: JSONValue] diff --git a/Sources/Schemas/GhlToolMetadata.swift b/Sources/Schemas/GhlToolMetadata.swift index dee74bc..562ecf8 100644 --- a/Sources/Schemas/GhlToolMetadata.swift +++ b/Sources/Schemas/GhlToolMetadata.swift @@ -1,7 +1,10 @@ import Foundation +/// GHL workflow and location identifiers attached to a tool. public struct GhlToolMetadata: Codable, Hashable, Sendable { + /// GHL workflow identifier associated with the tool. public let workflowId: String? + /// GHL location identifier associated with the tool. public let locationId: String? /// Additional properties that are not explicitly defined in the schema public let additionalProperties: [String: JSONValue] diff --git a/Sources/Schemas/GladiaCustomVocabularyConfigDto.swift b/Sources/Schemas/GladiaCustomVocabularyConfigDto.swift index b5021cb..2993771 100644 --- a/Sources/Schemas/GladiaCustomVocabularyConfigDto.swift +++ b/Sources/Schemas/GladiaCustomVocabularyConfigDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Custom vocabulary configuration for Gladia transcription, including vocabulary items and default recognition intensity. public struct GladiaCustomVocabularyConfigDto: Codable, Hashable, Sendable { /// Array of vocabulary items (strings or objects with value, pronunciations, intensity, language) public let vocabulary: [GladiaCustomVocabularyConfigDtoVocabularyItem] diff --git a/Sources/Schemas/GladiaTranscriber.swift b/Sources/Schemas/GladiaTranscriber.swift index c5d2a3c..c961ea7 100644 --- a/Sources/Schemas/GladiaTranscriber.swift +++ b/Sources/Schemas/GladiaTranscriber.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for transcribing speech during assistant conversations with Gladia, including language behavior, audio processing, endpointing, vocabulary, region, and fallback settings. public struct GladiaTranscriber: Codable, Hashable, Sendable { /// This is the Gladia model that will be used. Default is 'fast' public let model: GladiaTranscriberModel? diff --git a/Sources/Schemas/GladiaVocabularyItemDto.swift b/Sources/Schemas/GladiaVocabularyItemDto.swift index 9da1afd..b61a1a0 100644 --- a/Sources/Schemas/GladiaVocabularyItemDto.swift +++ b/Sources/Schemas/GladiaVocabularyItemDto.swift @@ -1,5 +1,6 @@ import Foundation +/// A Gladia custom vocabulary word or phrase with optional pronunciations, intensity, and language. public struct GladiaVocabularyItemDto: Codable, Hashable, Sendable { /// The vocabulary word or phrase public let value: String diff --git a/Sources/Schemas/GlobalNodePlan.swift b/Sources/Schemas/GlobalNodePlan.swift index 182e2d5..a3503ba 100644 --- a/Sources/Schemas/GlobalNodePlan.swift +++ b/Sources/Schemas/GlobalNodePlan.swift @@ -1,5 +1,6 @@ import Foundation +/// Controls whether a conversation node can be entered globally and the condition evaluated before that node runs. public struct GlobalNodePlan: Codable, Hashable, Sendable { /// This is the flag to determine if this node is a global node /// diff --git a/Sources/Schemas/GoHighLevelCalendarAvailabilityTool.swift b/Sources/Schemas/GoHighLevelCalendarAvailabilityTool.swift index fa8447b..e7258a2 100644 --- a/Sources/Schemas/GoHighLevelCalendarAvailabilityTool.swift +++ b/Sources/Schemas/GoHighLevelCalendarAvailabilityTool.swift @@ -1,5 +1,6 @@ import Foundation +/// A reusable tool that checks calendar availability in a connected GoHighLevel account. public struct GoHighLevelCalendarAvailabilityTool: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/GoHighLevelCalendarEventCreateTool.swift b/Sources/Schemas/GoHighLevelCalendarEventCreateTool.swift index 7615b27..15c8fd1 100644 --- a/Sources/Schemas/GoHighLevelCalendarEventCreateTool.swift +++ b/Sources/Schemas/GoHighLevelCalendarEventCreateTool.swift @@ -1,5 +1,6 @@ import Foundation +/// A reusable tool that adds calendar events to a connected GoHighLevel account. public struct GoHighLevelCalendarEventCreateTool: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/GoHighLevelContactCreateTool.swift b/Sources/Schemas/GoHighLevelContactCreateTool.swift index a91bc8a..c7ce91c 100644 --- a/Sources/Schemas/GoHighLevelContactCreateTool.swift +++ b/Sources/Schemas/GoHighLevelContactCreateTool.swift @@ -1,5 +1,6 @@ import Foundation +/// A reusable tool that adds contacts to a connected GoHighLevel account. public struct GoHighLevelContactCreateTool: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/GoHighLevelContactGetTool.swift b/Sources/Schemas/GoHighLevelContactGetTool.swift index 525d1f8..ede4247 100644 --- a/Sources/Schemas/GoHighLevelContactGetTool.swift +++ b/Sources/Schemas/GoHighLevelContactGetTool.swift @@ -1,5 +1,6 @@ import Foundation +/// A reusable tool that retrieves contacts from a connected GoHighLevel account. public struct GoHighLevelContactGetTool: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/GoogleCalendarCheckAvailabilityTool.swift b/Sources/Schemas/GoogleCalendarCheckAvailabilityTool.swift index 7359ce6..f752606 100644 --- a/Sources/Schemas/GoogleCalendarCheckAvailabilityTool.swift +++ b/Sources/Schemas/GoogleCalendarCheckAvailabilityTool.swift @@ -1,5 +1,6 @@ import Foundation +/// A reusable tool that checks availability in a connected Google Calendar. public struct GoogleCalendarCheckAvailabilityTool: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/GoogleCalendarCreateEventTool.swift b/Sources/Schemas/GoogleCalendarCreateEventTool.swift index 811d8a6..a7c9393 100644 --- a/Sources/Schemas/GoogleCalendarCreateEventTool.swift +++ b/Sources/Schemas/GoogleCalendarCreateEventTool.swift @@ -1,5 +1,6 @@ import Foundation +/// A reusable tool that adds events to a connected Google Calendar. public struct GoogleCalendarCreateEventTool: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/GoogleModel.swift b/Sources/Schemas/GoogleModel.swift index aa774f2..69e986d 100644 --- a/Sources/Schemas/GoogleModel.swift +++ b/Sources/Schemas/GoogleModel.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for generating assistant responses with Google, including model, prompts, tools, knowledge-base access, realtime settings, and generation settings. public struct GoogleModel: Codable, Hashable, Sendable { /// This is the starting state for the conversation. public let messages: [OpenAiMessage]? diff --git a/Sources/Schemas/GoogleRealtimeConfig.swift b/Sources/Schemas/GoogleRealtimeConfig.swift index 9d04d6e..3287b01 100644 --- a/Sources/Schemas/GoogleRealtimeConfig.swift +++ b/Sources/Schemas/GoogleRealtimeConfig.swift @@ -1,5 +1,6 @@ import Foundation +/// Realtime Gemini generation and speech-output settings, including sampling, repetition penalties, and voice configuration. public struct GoogleRealtimeConfig: Codable, Hashable, Sendable { /// This is the nucleus sampling parameter that controls the cumulative probability of tokens considered during text generation. /// Only applicable with the Gemini Flash 2.0 Multimodal Live API. diff --git a/Sources/Schemas/GoogleSheetsRowAppendTool.swift b/Sources/Schemas/GoogleSheetsRowAppendTool.swift index 30ff19d..47bdd21 100644 --- a/Sources/Schemas/GoogleSheetsRowAppendTool.swift +++ b/Sources/Schemas/GoogleSheetsRowAppendTool.swift @@ -1,5 +1,6 @@ import Foundation +/// A reusable tool that appends rows to a connected Google Sheet. public struct GoogleSheetsRowAppendTool: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/GoogleTranscriber.swift b/Sources/Schemas/GoogleTranscriber.swift index cf8309c..12012b7 100644 --- a/Sources/Schemas/GoogleTranscriber.swift +++ b/Sources/Schemas/GoogleTranscriber.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for transcribing speech during assistant conversations with Google, including model, language, and fallback settings. public struct GoogleTranscriber: Codable, Hashable, Sendable { /// This is the model that will be used for the transcription. public let model: GoogleTranscriberModel? diff --git a/Sources/Schemas/GoogleVoicemailDetectionPlan.swift b/Sources/Schemas/GoogleVoicemailDetectionPlan.swift index ace4ec8..bf6756c 100644 --- a/Sources/Schemas/GoogleVoicemailDetectionPlan.swift +++ b/Sources/Schemas/GoogleVoicemailDetectionPlan.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for detecting voicemail with Google, including detection type, maximum beep wait, and retry backoff. public struct GoogleVoicemailDetectionPlan: Codable, Hashable, Sendable { /// This is the maximum duration from the start of the call that we will wait for a voicemail beep, before speaking our message /// diff --git a/Sources/Schemas/GroqModel.swift b/Sources/Schemas/GroqModel.swift index 9ca1078..2a3f002 100644 --- a/Sources/Schemas/GroqModel.swift +++ b/Sources/Schemas/GroqModel.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for generating assistant responses with Groq, including model, prompts, tools, knowledge-base access, and generation settings. public struct GroqModel: Codable, Hashable, Sendable { /// This is the starting state for the conversation. public let messages: [OpenAiMessage]? diff --git a/Sources/Schemas/GroupCondition.swift b/Sources/Schemas/GroupCondition.swift index 9b8cf20..187d90a 100644 --- a/Sources/Schemas/GroupCondition.swift +++ b/Sources/Schemas/GroupCondition.swift @@ -1,5 +1,6 @@ import Foundation +/// Combines nested regular-expression, Liquid, or grouped conditions with an `AND` or `OR` operator. public struct GroupCondition: Codable, Hashable, Sendable { /// This is the logical operator for combining conditions in this group public let `operator`: GroupConditionOperator diff --git a/Sources/Schemas/HandoffDestinationAssistant.swift b/Sources/Schemas/HandoffDestinationAssistant.swift index 6e605c2..6f4cce9 100644 --- a/Sources/Schemas/HandoffDestinationAssistant.swift +++ b/Sources/Schemas/HandoffDestinationAssistant.swift @@ -1,6 +1,8 @@ import Foundation +/// Routes a handoff to a saved or transient assistant, with optional context engineering, variable extraction, and assistant overrides. public struct HandoffDestinationAssistant: Codable, Hashable, Sendable { + /// Selects an assistant as the handoff destination. public let type: HandoffDestinationAssistantType /// This is the plan for manipulating the message context before handing off the call to the next assistant. public let contextEngineeringPlan: HandoffDestinationAssistantContextEngineeringPlan? diff --git a/Sources/Schemas/HandoffDestinationAssistantType.swift b/Sources/Schemas/HandoffDestinationAssistantType.swift index 875f2e6..fe2154d 100644 --- a/Sources/Schemas/HandoffDestinationAssistantType.swift +++ b/Sources/Schemas/HandoffDestinationAssistantType.swift @@ -1,5 +1,6 @@ import Foundation +/// Selects an assistant as the handoff destination. public enum HandoffDestinationAssistantType: String, Codable, Hashable, CaseIterable, Sendable { case assistant } \ No newline at end of file diff --git a/Sources/Schemas/HandoffDestinationDynamic.swift b/Sources/Schemas/HandoffDestinationDynamic.swift index 6d4879c..e1e5cda 100644 --- a/Sources/Schemas/HandoffDestinationDynamic.swift +++ b/Sources/Schemas/HandoffDestinationDynamic.swift @@ -1,5 +1,6 @@ import Foundation +/// Uses a webhook response to select the handoff destination at runtime. public struct HandoffDestinationDynamic: Codable, Hashable, Sendable { /// This is where Vapi will send the handoff-destination-request webhook in a dynamic handoff. /// diff --git a/Sources/Schemas/HandoffDestinationSquad.swift b/Sources/Schemas/HandoffDestinationSquad.swift index 8cfc2a8..cd02658 100644 --- a/Sources/Schemas/HandoffDestinationSquad.swift +++ b/Sources/Schemas/HandoffDestinationSquad.swift @@ -1,5 +1,6 @@ import Foundation +/// Routes a handoff to a saved or transient squad, with optional entry assistant, context engineering, variable extraction, and overrides. public struct HandoffDestinationSquad: Codable, Hashable, Sendable { /// This is the plan for manipulating the message context before handing off the call to the squad. public let contextEngineeringPlan: HandoffDestinationSquadContextEngineeringPlan? diff --git a/Sources/Schemas/HandoffTool.swift b/Sources/Schemas/HandoffTool.swift index 5abb478..113c8fb 100644 --- a/Sources/Schemas/HandoffTool.swift +++ b/Sources/Schemas/HandoffTool.swift @@ -1,5 +1,6 @@ import Foundation +/// A reusable tool that hands a conversation to another assistant, squad, or dynamically selected destination. public struct HandoffTool: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/HmacAuthenticationPlan.swift b/Sources/Schemas/HmacAuthenticationPlan.swift index e368d50..8543723 100644 --- a/Sources/Schemas/HmacAuthenticationPlan.swift +++ b/Sources/Schemas/HmacAuthenticationPlan.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for signing outbound requests with an HMAC secret, including algorithm, headers, payload format, and signature encoding. public struct HmacAuthenticationPlan: Codable, Hashable, Sendable { /// This is the HMAC secret key used to sign requests. public let secretKey: String diff --git a/Sources/Schemas/HumeVoice.swift b/Sources/Schemas/HumeVoice.swift index a759f0c..9b6902e 100644 --- a/Sources/Schemas/HumeVoice.swift +++ b/Sources/Schemas/HumeVoice.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for synthesizing assistant speech with Hume, including model and voice selection, custom voice metadata, chunking, caching, and fallback settings. public struct HumeVoice: Codable, Hashable, Sendable { /// This is the flag to toggle voice caching for the assistant. public let cachingEnabled: Bool? diff --git a/Sources/Schemas/ImportTwilioPhoneNumberDto.swift b/Sources/Schemas/ImportTwilioPhoneNumberDto.swift index 1d8d02d..02daacc 100644 --- a/Sources/Schemas/ImportTwilioPhoneNumberDto.swift +++ b/Sources/Schemas/ImportTwilioPhoneNumberDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for importing a Twilio phone number into Vapi, including Twilio credentials, routing target, fallback destination, hooks, SMS, and server settings. public struct ImportTwilioPhoneNumberDto: Codable, Hashable, Sendable { /// This is the fallback destination an inbound call will be transferred to if: /// 1. `assistantId` is not set diff --git a/Sources/Schemas/InflectionAiModel.swift b/Sources/Schemas/InflectionAiModel.swift index dfbbe30..cdaf151 100644 --- a/Sources/Schemas/InflectionAiModel.swift +++ b/Sources/Schemas/InflectionAiModel.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for generating assistant responses with Inflection AI, including model, prompts, tools, knowledge-base access, and generation settings. public struct InflectionAiModel: Codable, Hashable, Sendable { /// This is the starting state for the conversation. public let messages: [OpenAiMessage]? diff --git a/Sources/Schemas/Insight.swift b/Sources/Schemas/Insight.swift index 9c43f92..1458ff8 100644 --- a/Sources/Schemas/Insight.swift +++ b/Sources/Schemas/Insight.swift @@ -1,5 +1,6 @@ import Foundation +/// A saved insight returned by the API, including its visualization type, identity, organization, and lifecycle timestamps. public struct Insight: Codable, Hashable, Sendable { /// This is the name of the Insight. public let name: String? diff --git a/Sources/Schemas/InsightFormula.swift b/Sources/Schemas/InsightFormula.swift index 4bff1d2..70987e2 100644 --- a/Sources/Schemas/InsightFormula.swift +++ b/Sources/Schemas/InsightFormula.swift @@ -1,5 +1,6 @@ import Foundation +/// A formula used to calculate an insight from its query results, with an optional display name. public struct InsightFormula: Codable, Hashable, Sendable { /// This is the name of the formula. /// It will be used to label the formula in the insight board on the UI. diff --git a/Sources/Schemas/InsightPaginatedResponse.swift b/Sources/Schemas/InsightPaginatedResponse.swift index 8ac673c..611645d 100644 --- a/Sources/Schemas/InsightPaginatedResponse.swift +++ b/Sources/Schemas/InsightPaginatedResponse.swift @@ -1,7 +1,10 @@ import Foundation +/// A paginated collection of saved reporting insights and metadata describing the result set. public struct InsightPaginatedResponse: Codable, Hashable, Sendable { + /// The reporting insights returned for the current page. public let results: [Insight] + /// Pagination metadata for the insight result set. public let metadata: PaginationMeta /// Additional properties that are not explicitly defined in the schema public let additionalProperties: [String: JSONValue] diff --git a/Sources/Schemas/InsightRunFormatPlan.swift b/Sources/Schemas/InsightRunFormatPlan.swift index 5c85e06..2be2520 100644 --- a/Sources/Schemas/InsightRunFormatPlan.swift +++ b/Sources/Schemas/InsightRunFormatPlan.swift @@ -1,5 +1,6 @@ import Foundation +/// Selects whether an insight run returns raw data or Recharts-formatted data. public struct InsightRunFormatPlan: Codable, Hashable, Sendable { /// This is the format of the data to return. /// If not provided, defaults to "raw". diff --git a/Sources/Schemas/InsightRunResponse.swift b/Sources/Schemas/InsightRunResponse.swift index d419c26..10ff38a 100644 --- a/Sources/Schemas/InsightRunResponse.swift +++ b/Sources/Schemas/InsightRunResponse.swift @@ -1,10 +1,16 @@ import Foundation +/// Metadata identifying a saved insight run and its lifecycle timestamps. public struct InsightRunResponse: Codable, Hashable, Sendable { + /// The unique identifier for the insight run. public let id: String + /// The unique identifier for the insight that was run. public let insightId: String + /// The unique identifier for the organization that owns the run. public let orgId: String + /// The ISO 8601 timestamp when the insight run was created. public let createdAt: Date + /// The ISO 8601 timestamp when the insight run was last updated. public let updatedAt: Date /// Additional properties that are not explicitly defined in the schema public let additionalProperties: [String: JSONValue] diff --git a/Sources/Schemas/InsightTimeRange.swift b/Sources/Schemas/InsightTimeRange.swift index 7549164..38caa2c 100644 --- a/Sources/Schemas/InsightTimeRange.swift +++ b/Sources/Schemas/InsightTimeRange.swift @@ -1,5 +1,6 @@ import Foundation +/// Start, end, and timezone used to limit an insight query by time. public struct InsightTimeRange: Codable, Hashable, Sendable { /// This is the start date for the time range. /// diff --git a/Sources/Schemas/InsightTimeRangeWithStep.swift b/Sources/Schemas/InsightTimeRangeWithStep.swift index 821470a..b82e799 100644 --- a/Sources/Schemas/InsightTimeRangeWithStep.swift +++ b/Sources/Schemas/InsightTimeRangeWithStep.swift @@ -1,5 +1,6 @@ import Foundation +/// Start, end, timezone, and aggregation step used for a time-series insight query. public struct InsightTimeRangeWithStep: Codable, Hashable, Sendable { /// This is the group by step for aggregation. /// diff --git a/Sources/Schemas/InworldVoice.swift b/Sources/Schemas/InworldVoice.swift index 9847c75..470e435 100644 --- a/Sources/Schemas/InworldVoice.swift +++ b/Sources/Schemas/InworldVoice.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for synthesizing assistant speech with Inworld, including voice and model selection, language, temperature, speaking rate, chunking, caching, and fallback settings. public struct InworldVoice: Codable, Hashable, Sendable { /// This is the flag to toggle voice caching for the assistant. public let cachingEnabled: Bool? diff --git a/Sources/Schemas/JsonQueryOnCallTableWithNumberTypeColumn.swift b/Sources/Schemas/JsonQueryOnCallTableWithNumberTypeColumn.swift index e4cdc16..bb4c98f 100644 --- a/Sources/Schemas/JsonQueryOnCallTableWithNumberTypeColumn.swift +++ b/Sources/Schemas/JsonQueryOnCallTableWithNumberTypeColumn.swift @@ -1,5 +1,6 @@ import Foundation +/// VapiQL JSON query that aggregates a numeric call-table column with optional call filters. public struct JsonQueryOnCallTableWithNumberTypeColumn: Codable, Hashable, Sendable { /// This is the type of query. Only allowed type is "vapiql-json". public let type: JsonQueryOnCallTableWithNumberTypeColumnType diff --git a/Sources/Schemas/JsonQueryOnCallTableWithStringTypeColumn.swift b/Sources/Schemas/JsonQueryOnCallTableWithStringTypeColumn.swift index 5c53e33..c6463a9 100644 --- a/Sources/Schemas/JsonQueryOnCallTableWithStringTypeColumn.swift +++ b/Sources/Schemas/JsonQueryOnCallTableWithStringTypeColumn.swift @@ -1,5 +1,6 @@ import Foundation +/// VapiQL JSON query that counts values from a string-valued call-table column with optional call filters. public struct JsonQueryOnCallTableWithStringTypeColumn: Codable, Hashable, Sendable { /// This is the type of query. Only allowed type is "vapiql-json". public let type: JsonQueryOnCallTableWithStringTypeColumnType diff --git a/Sources/Schemas/JsonQueryOnCallTableWithStructuredOutputColumn.swift b/Sources/Schemas/JsonQueryOnCallTableWithStructuredOutputColumn.swift index 2d2589e..625c95d 100644 --- a/Sources/Schemas/JsonQueryOnCallTableWithStructuredOutputColumn.swift +++ b/Sources/Schemas/JsonQueryOnCallTableWithStructuredOutputColumn.swift @@ -1,5 +1,6 @@ import Foundation +/// VapiQL JSON query that aggregates or counts a structured-output value stored on call records. public struct JsonQueryOnCallTableWithStructuredOutputColumn: Codable, Hashable, Sendable { /// This is the type of query. Only allowed type is "vapiql-json". public let type: JsonQueryOnCallTableWithStructuredOutputColumnType diff --git a/Sources/Schemas/JsonQueryOnEventsTable.swift b/Sources/Schemas/JsonQueryOnEventsTable.swift index f233096..56d34c0 100644 --- a/Sources/Schemas/JsonQueryOnEventsTable.swift +++ b/Sources/Schemas/JsonQueryOnEventsTable.swift @@ -1,5 +1,6 @@ import Foundation +/// VapiQL JSON query that counts or calculates the percentage of matching events using optional typed event-data filters. public struct JsonQueryOnEventsTable: Codable, Hashable, Sendable { /// This is the type of query. Only allowed type is "vapiql-json". public let type: JsonQueryOnEventsTableType diff --git a/Sources/Schemas/JsonSchema.swift b/Sources/Schemas/JsonSchema.swift index 4eac588..dd62ea0 100644 --- a/Sources/Schemas/JsonSchema.swift +++ b/Sources/Schemas/JsonSchema.swift @@ -1,5 +1,6 @@ import Foundation +/// JSON Schema definition used to describe structured data for extraction, validation, or model output. public struct JsonSchema: Codable, Hashable, Sendable { /// This is the type of output you'd like. /// diff --git a/Sources/Schemas/KeypadInputPlan.swift b/Sources/Schemas/KeypadInputPlan.swift index 8612c24..af04fcb 100644 --- a/Sources/Schemas/KeypadInputPlan.swift +++ b/Sources/Schemas/KeypadInputPlan.swift @@ -1,5 +1,6 @@ import Foundation +/// Controls collection of dual-tone multi-frequency (DTMF) keypad input, including enablement, processing timeout, and delimiters. public struct KeypadInputPlan: Codable, Hashable, Sendable { /// This keeps track of whether the user has enabled keypad input. /// By default, it is off. diff --git a/Sources/Schemas/KnowledgeBase.swift b/Sources/Schemas/KnowledgeBase.swift index 427da95..0de357e 100644 --- a/Sources/Schemas/KnowledgeBase.swift +++ b/Sources/Schemas/KnowledgeBase.swift @@ -1,5 +1,6 @@ import Foundation +/// A knowledge-base configuration, including its provider, model, description, and associated files. public struct KnowledgeBase: Codable, Hashable, Sendable { /// The name of the knowledge base public let name: String diff --git a/Sources/Schemas/KnowledgeBaseCost.swift b/Sources/Schemas/KnowledgeBaseCost.swift index 3e41ddf..718717a 100644 --- a/Sources/Schemas/KnowledgeBaseCost.swift +++ b/Sources/Schemas/KnowledgeBaseCost.swift @@ -1,5 +1,6 @@ import Foundation +/// Knowledge-base model cost, including model, token usage, and amount. public struct KnowledgeBaseCost: Codable, Hashable, Sendable { /// This is the model that was used for processing the knowledge base. public let model: [String: JSONValue] diff --git a/Sources/Schemas/LangfuseObservabilityPlan.swift b/Sources/Schemas/LangfuseObservabilityPlan.swift index 1913319..80988cd 100644 --- a/Sources/Schemas/LangfuseObservabilityPlan.swift +++ b/Sources/Schemas/LangfuseObservabilityPlan.swift @@ -1,6 +1,8 @@ import Foundation +/// Configuration for sending assistant call traces to Langfuse, including prompt version linkage, trace naming, tags, and metadata. public struct LangfuseObservabilityPlan: Codable, Hashable, Sendable { + /// Routes assistant call observability data to Langfuse. public let provider: LangfuseObservabilityPlanProvider /// The name of a Langfuse prompt to link generations to. This enables tracking which prompt version was used for each generation. https://langfuse.com/docs/prompt-management/features/link-to-traces public let promptName: String? diff --git a/Sources/Schemas/LangfuseObservabilityPlanProvider.swift b/Sources/Schemas/LangfuseObservabilityPlanProvider.swift index ede5024..17a8169 100644 --- a/Sources/Schemas/LangfuseObservabilityPlanProvider.swift +++ b/Sources/Schemas/LangfuseObservabilityPlanProvider.swift @@ -1,5 +1,6 @@ import Foundation +/// Routes assistant call observability data to Langfuse. public enum LangfuseObservabilityPlanProvider: String, Codable, Hashable, CaseIterable, Sendable { case langfuse } \ No newline at end of file diff --git a/Sources/Schemas/LineInsight.swift b/Sources/Schemas/LineInsight.swift index 09a1578..6a334c2 100644 --- a/Sources/Schemas/LineInsight.swift +++ b/Sources/Schemas/LineInsight.swift @@ -1,5 +1,6 @@ import Foundation +/// A saved line-chart insight containing its call-data queries, formulas, grouping, stepped time range, metadata, and lifecycle information. public struct LineInsight: Codable, Hashable, Sendable { /// This is the name of the Insight. public let name: String? @@ -21,6 +22,7 @@ public struct LineInsight: Codable, Hashable, Sendable { public let formulas: [InsightFormula]? /// This is the metadata for the insight. public let metadata: LineInsightMetadata? + /// The time range and interval used to aggregate the line-chart data. public let timeRange: InsightTimeRangeWithStep? /// This is the group by column for the insight when table is `call`. /// These are the columns to group the results by. diff --git a/Sources/Schemas/LineInsightMetadata.swift b/Sources/Schemas/LineInsightMetadata.swift index 434a309..e4d548b 100644 --- a/Sources/Schemas/LineInsightMetadata.swift +++ b/Sources/Schemas/LineInsightMetadata.swift @@ -1,10 +1,16 @@ import Foundation +/// Display settings for a line insight, including chart name, axis labels, and optional y-axis bounds. public struct LineInsightMetadata: Codable, Hashable, Sendable { + /// Label displayed on the chart's x-axis. public let xAxisLabel: String? + /// Label displayed on the chart's y-axis. public let yAxisLabel: String? + /// Minimum value displayed on the chart's y-axis. public let yAxisMin: Double? + /// Maximum value displayed on the chart's y-axis. public let yAxisMax: Double? + /// Display name for the insight chart. public let name: String? /// Additional properties that are not explicitly defined in the schema public let additionalProperties: [String: JSONValue] diff --git a/Sources/Schemas/LiquidCondition.swift b/Sources/Schemas/LiquidCondition.swift index bf96c73..c1f906f 100644 --- a/Sources/Schemas/LiquidCondition.swift +++ b/Sources/Schemas/LiquidCondition.swift @@ -1,5 +1,6 @@ import Foundation +/// Evaluates a Liquid template that must return `true` or `false`. public struct LiquidCondition: Codable, Hashable, Sendable { /// This is the Liquid template that must return exactly "true" or "false" as a string. /// The template is evaluated and the entire output must be either "true" or "false" - nothing else. diff --git a/Sources/Schemas/LivekitSmartEndpointingPlan.swift b/Sources/Schemas/LivekitSmartEndpointingPlan.swift index c89800e..f8fba05 100644 --- a/Sources/Schemas/LivekitSmartEndpointingPlan.swift +++ b/Sources/Schemas/LivekitSmartEndpointingPlan.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for using LiveKit smart endpointing, including provider selection and wait-function behavior. public struct LivekitSmartEndpointingPlan: Codable, Hashable, Sendable { /// This is the provider for the smart endpointing plan. public let provider: LivekitSmartEndpointingPlanProvider diff --git a/Sources/Schemas/LmntVoice.swift b/Sources/Schemas/LmntVoice.swift index 2499b91..953c46c 100644 --- a/Sources/Schemas/LmntVoice.swift +++ b/Sources/Schemas/LmntVoice.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for synthesizing assistant speech with LMNT, including voice selection, language, speed, chunking, caching, and fallback settings. public struct LmntVoice: Codable, Hashable, Sendable { /// This is the flag to toggle voice caching for the assistant. public let cachingEnabled: Bool? diff --git a/Sources/Schemas/McpTool.swift b/Sources/Schemas/McpTool.swift index ba23f00..4319806 100644 --- a/Sources/Schemas/McpTool.swift +++ b/Sources/Schemas/McpTool.swift @@ -1,5 +1,6 @@ import Foundation +/// A reusable tool that connects an assistant to a Model Context Protocol server and exposes its available tools. public struct McpTool: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// @@ -104,6 +105,7 @@ public struct McpTool: Codable, Hashable, Sendable { /// } /// ``` public let rejectionPlan: ToolRejectionPlan? + /// Connection metadata for the MCP server, including its communication protocol. public let metadata: McpToolMetadata? /// Additional properties that are not explicitly defined in the schema public let additionalProperties: [String: JSONValue] diff --git a/Sources/Schemas/McpToolMessages.swift b/Sources/Schemas/McpToolMessages.swift index 8850949..5662947 100644 --- a/Sources/Schemas/McpToolMessages.swift +++ b/Sources/Schemas/McpToolMessages.swift @@ -1,5 +1,6 @@ import Foundation +/// Per-tool message overrides for a tool discovered through an MCP server. public struct McpToolMessages: Codable, Hashable, Sendable { /// The name of the tool from the MCP server. public let name: String diff --git a/Sources/Schemas/McpToolMetadata.swift b/Sources/Schemas/McpToolMetadata.swift index 48d9291..84f6cf4 100644 --- a/Sources/Schemas/McpToolMetadata.swift +++ b/Sources/Schemas/McpToolMetadata.swift @@ -1,5 +1,6 @@ import Foundation +/// Protocol metadata used to communicate with an MCP server. public struct McpToolMetadata: Codable, Hashable, Sendable { /// This is the protocol used for MCP communication. Defaults to Streamable HTTP. public let `protocol`: McpToolMetadataProtocol? diff --git a/Sources/Schemas/MessageAddHookAction.swift b/Sources/Schemas/MessageAddHookAction.swift index 915ce4e..a1e9c90 100644 --- a/Sources/Schemas/MessageAddHookAction.swift +++ b/Sources/Schemas/MessageAddHookAction.swift @@ -1,5 +1,6 @@ import Foundation +/// A hook action that adds an OpenAI-format message to the conversation and can trigger an assistant response. public struct MessageAddHookAction: Codable, Hashable, Sendable { /// The message to add to the conversation in OpenAI format public let message: OpenAiMessage diff --git a/Sources/Schemas/MessageTarget.swift b/Sources/Schemas/MessageTarget.swift index 6837a36..b43dcba 100644 --- a/Sources/Schemas/MessageTarget.swift +++ b/Sources/Schemas/MessageTarget.swift @@ -1,5 +1,6 @@ import Foundation +/// Selects a conversation message by participant role and position for condition evaluation. public struct MessageTarget: Codable, Hashable, Sendable { /// This is the role of the message to target. /// diff --git a/Sources/Schemas/MinimaxLlmModel.swift b/Sources/Schemas/MinimaxLlmModel.swift index 45a265f..7ee5907 100644 --- a/Sources/Schemas/MinimaxLlmModel.swift +++ b/Sources/Schemas/MinimaxLlmModel.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for generating assistant responses with MiniMax, including model, prompts, tools, knowledge-base access, and generation settings. public struct MinimaxLlmModel: Codable, Hashable, Sendable { /// This is the starting state for the conversation. public let messages: [OpenAiMessage]? diff --git a/Sources/Schemas/MinimaxVoice.swift b/Sources/Schemas/MinimaxVoice.swift index 0f4d06a..f91d194 100644 --- a/Sources/Schemas/MinimaxVoice.swift +++ b/Sources/Schemas/MinimaxVoice.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for synthesizing assistant speech with MiniMax, including voice and model selection, emotion, pitch, speed, volume, region, language, text normalization, chunking, caching, and fallback settings. public struct MinimaxVoice: Codable, Hashable, Sendable { /// This is the flag to toggle voice caching for the assistant. public let cachingEnabled: Bool? diff --git a/Sources/Schemas/ModelCost.swift b/Sources/Schemas/ModelCost.swift index 2ced309..8abf8e5 100644 --- a/Sources/Schemas/ModelCost.swift +++ b/Sources/Schemas/ModelCost.swift @@ -1,5 +1,6 @@ import Foundation +/// Language-model cost for a call, including model, token usage, and amount. public struct ModelCost: Codable, Hashable, Sendable { /// This is the model that was used during the call. /// diff --git a/Sources/Schemas/Monitor.swift b/Sources/Schemas/Monitor.swift index 6d7c7df..eb8e14b 100644 --- a/Sources/Schemas/Monitor.swift +++ b/Sources/Schemas/Monitor.swift @@ -1,6 +1,8 @@ import Foundation +/// Live monitoring data for a call, including attached monitor results and listening and control URLs. public struct Monitor: Codable, Hashable, Sendable { + /// Results produced by monitors attached to the call. public let monitors: [MonitorResult]? /// This is the URL where the assistant's calls can be listened to in real-time. To enable, set `assistant.monitorPlan.listenEnabled` to `true`. public let listenUrl: String? diff --git a/Sources/Schemas/MonitorPlan.swift b/Sources/Schemas/MonitorPlan.swift index cc1c952..14ae5f1 100644 --- a/Sources/Schemas/MonitorPlan.swift +++ b/Sources/Schemas/MonitorPlan.swift @@ -1,5 +1,6 @@ import Foundation +/// Controls real-time listening and control for assistant calls, authentication requirements for monitor URLs, and attached monitors. public struct MonitorPlan: Codable, Hashable, Sendable { /// This determines whether the assistant's calls allow live listening. Defaults to true. /// @@ -27,11 +28,7 @@ public struct MonitorPlan: Codable, Hashable, Sendable { /// /// @default false public let controlAuthenticationEnabled: Bool? - /// This the set of monitor ids that are attached to the assistant. - /// The source of truth for the monitor ids is the assistant_monitor join table. - /// This field can be used for transient assistants and to update assistants with new monitor ids. - /// - /// @default [] + /// IDs of the monitors attached to the assistant. Use this field for transient assistants or to update the monitors attached to an existing assistant. Defaults to an empty array. public let monitorIds: [String]? /// Additional properties that are not explicitly defined in the schema public let additionalProperties: [String: JSONValue] diff --git a/Sources/Schemas/MonitorResult.swift b/Sources/Schemas/MonitorResult.swift index fd5fc25..af85ecf 100644 --- a/Sources/Schemas/MonitorResult.swift +++ b/Sources/Schemas/MonitorResult.swift @@ -1,7 +1,10 @@ import Foundation +/// Result of evaluating an attached monitor's filter for a call. public struct MonitorResult: Codable, Hashable, Sendable { + /// Unique identifier of the monitor that produced this result. public let monitorId: String + /// Whether the monitor's filter matched the call. public let filterPassed: Bool /// Additional properties that are not explicitly defined in the schema public let additionalProperties: [String: JSONValue] diff --git a/Sources/Schemas/Mono.swift b/Sources/Schemas/Mono.swift index 1eb466f..bda97cf 100644 --- a/Sources/Schemas/Mono.swift +++ b/Sources/Schemas/Mono.swift @@ -1,5 +1,6 @@ import Foundation +/// Mono recording URLs for the combined call and isolated assistant and customer audio. public struct Mono: Codable, Hashable, Sendable { /// This is the combined recording url for the call. To enable, set `assistant.artifactPlan.recordingEnabled`. public let combinedUrl: String? diff --git a/Sources/Schemas/NeuphonicVoice.swift b/Sources/Schemas/NeuphonicVoice.swift index d5a92b0..ccefcc2 100644 --- a/Sources/Schemas/NeuphonicVoice.swift +++ b/Sources/Schemas/NeuphonicVoice.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for synthesizing assistant speech with Neuphonic, including voice and model selection, language, speed, chunking, caching, and fallback settings. public struct NeuphonicVoice: Codable, Hashable, Sendable { /// This is the flag to toggle voice caching for the assistant. public let cachingEnabled: Bool? diff --git a/Sources/Schemas/NodeArtifact.swift b/Sources/Schemas/NodeArtifact.swift index 57f45e3..83b9099 100644 --- a/Sources/Schemas/NodeArtifact.swift +++ b/Sources/Schemas/NodeArtifact.swift @@ -1,5 +1,6 @@ import Foundation +/// Messages and variable values captured while a workflow node was active. public struct NodeArtifact: Codable, Hashable, Sendable { /// These are the messages that were spoken during the node. public let messages: [NodeArtifactMessagesItem]? diff --git a/Sources/Schemas/OAuth2AuthenticationPlan.swift b/Sources/Schemas/OAuth2AuthenticationPlan.swift index a2973b9..d90c37e 100644 --- a/Sources/Schemas/OAuth2AuthenticationPlan.swift +++ b/Sources/Schemas/OAuth2AuthenticationPlan.swift @@ -1,6 +1,8 @@ import Foundation +/// Client-credentials configuration for obtaining an OAuth 2.0 access token used to authenticate outbound requests. public struct OAuth2AuthenticationPlan: Codable, Hashable, Sendable { + /// Selects OAuth 2.0 authentication. public let type: OAuth2AuthenticationPlanType /// This is the OAuth2 URL. public let url: String diff --git a/Sources/Schemas/OAuth2AuthenticationPlanType.swift b/Sources/Schemas/OAuth2AuthenticationPlanType.swift index 2a7094b..37eaf70 100644 --- a/Sources/Schemas/OAuth2AuthenticationPlanType.swift +++ b/Sources/Schemas/OAuth2AuthenticationPlanType.swift @@ -1,5 +1,6 @@ import Foundation +/// Selects OAuth 2.0 authentication. public enum OAuth2AuthenticationPlanType: String, Codable, Hashable, CaseIterable, Sendable { case oauth2 } \ No newline at end of file diff --git a/Sources/Schemas/Oauth2AuthenticationSession.swift b/Sources/Schemas/Oauth2AuthenticationSession.swift index 7a8adf1..6d2479a 100644 --- a/Sources/Schemas/Oauth2AuthenticationSession.swift +++ b/Sources/Schemas/Oauth2AuthenticationSession.swift @@ -1,5 +1,6 @@ import Foundation +/// OAuth 2.0 session tokens and expiration used to authenticate integration requests. public struct Oauth2AuthenticationSession: Codable, Hashable, Sendable { /// This is the OAuth2 access token. public let accessToken: String? diff --git a/Sources/Schemas/OpenAiFunction.swift b/Sources/Schemas/OpenAiFunction.swift index 8ed6d74..0418c1e 100644 --- a/Sources/Schemas/OpenAiFunction.swift +++ b/Sources/Schemas/OpenAiFunction.swift @@ -1,5 +1,6 @@ import Foundation +/// Function definition exposed to a language model, including its name, purpose, parameter schema, and strict-schema behavior. public struct OpenAiFunction: Codable, Hashable, Sendable { /// This is a boolean that controls whether to enable strict schema adherence when generating the function call. If set to true, the model will follow the exact schema defined in the parameters field. Only a subset of JSON Schema is supported when strict is true. Learn more about Structured Outputs in the [OpenAI guide](https://openai.com/index/introducing-structured-outputs-in-the-api/). /// diff --git a/Sources/Schemas/OpenAiFunctionParameters.swift b/Sources/Schemas/OpenAiFunctionParameters.swift index 544f18e..d141092 100644 --- a/Sources/Schemas/OpenAiFunctionParameters.swift +++ b/Sources/Schemas/OpenAiFunctionParameters.swift @@ -1,5 +1,6 @@ import Foundation +/// JSON object schema defining the properties accepted by a function and which properties are required. public struct OpenAiFunctionParameters: Codable, Hashable, Sendable { /// This must be set to 'object'. It instructs the model to return a JSON object containing the function call properties. public let type: OpenAiFunctionParametersType diff --git a/Sources/Schemas/OpenAiMessage.swift b/Sources/Schemas/OpenAiMessage.swift index 4ef5927..9a9d435 100644 --- a/Sources/Schemas/OpenAiMessage.swift +++ b/Sources/Schemas/OpenAiMessage.swift @@ -1,7 +1,10 @@ import Foundation +/// A conversation message represented in OpenAI chat format. public struct OpenAiMessage: Codable, Hashable, Sendable { + /// Content of the conversation message. public let content: Nullable + /// Role associated with the conversation message. public let role: OpenAiMessageRole /// Additional properties that are not explicitly defined in the schema public let additionalProperties: [String: JSONValue] diff --git a/Sources/Schemas/OpenAiMessageRole.swift b/Sources/Schemas/OpenAiMessageRole.swift index e0a14e3..2d17ce6 100644 --- a/Sources/Schemas/OpenAiMessageRole.swift +++ b/Sources/Schemas/OpenAiMessageRole.swift @@ -1,5 +1,6 @@ import Foundation +/// Role associated with the conversation message. public enum OpenAiMessageRole: String, Codable, Hashable, CaseIterable, Sendable { case assistant case function diff --git a/Sources/Schemas/OpenAiModel.swift b/Sources/Schemas/OpenAiModel.swift index ff4facc..dd28a82 100644 --- a/Sources/Schemas/OpenAiModel.swift +++ b/Sources/Schemas/OpenAiModel.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for generating assistant responses with OpenAI, including model selection, fallback models, prompts, tools, prompt caching, and generation settings. public struct OpenAiModel: Codable, Hashable, Sendable { /// This is the starting state for the conversation. public let messages: [OpenAiMessage]? diff --git a/Sources/Schemas/OpenAiTranscriber.swift b/Sources/Schemas/OpenAiTranscriber.swift index a12d282..e7cafbf 100644 --- a/Sources/Schemas/OpenAiTranscriber.swift +++ b/Sources/Schemas/OpenAiTranscriber.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for transcribing speech during assistant conversations with OpenAI, including model, language, and fallback settings. public struct OpenAiTranscriber: Codable, Hashable, Sendable { /// This is the model that will be used for the transcription. public let model: OpenAiTranscriberModel diff --git a/Sources/Schemas/OpenAiVoice.swift b/Sources/Schemas/OpenAiVoice.swift index ac6ce34..c2617b5 100644 --- a/Sources/Schemas/OpenAiVoice.swift +++ b/Sources/Schemas/OpenAiVoice.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for synthesizing assistant speech with OpenAI, including voice and model selection, delivery instructions, speed, chunking, caching, and fallback settings. public struct OpenAiVoice: Codable, Hashable, Sendable { /// This is the flag to toggle voice caching for the assistant. public let cachingEnabled: Bool? diff --git a/Sources/Schemas/OpenAiVoicemailDetectionPlan.swift b/Sources/Schemas/OpenAiVoicemailDetectionPlan.swift index 561b696..180c84b 100644 --- a/Sources/Schemas/OpenAiVoicemailDetectionPlan.swift +++ b/Sources/Schemas/OpenAiVoicemailDetectionPlan.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for detecting voicemail with OpenAI, including detection type, maximum beep wait, and retry backoff. public struct OpenAiVoicemailDetectionPlan: Codable, Hashable, Sendable { /// This is the maximum duration from the start of the call that we will wait for a voicemail beep, before speaking our message /// diff --git a/Sources/Schemas/OpenRouterModel.swift b/Sources/Schemas/OpenRouterModel.swift index ff644cd..edc8092 100644 --- a/Sources/Schemas/OpenRouterModel.swift +++ b/Sources/Schemas/OpenRouterModel.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for generating assistant responses through OpenRouter, including routed model selection, prompts, tools, knowledge-base access, and generation settings. public struct OpenRouterModel: Codable, Hashable, Sendable { /// This is the starting state for the conversation. public let messages: [OpenAiMessage]? diff --git a/Sources/Schemas/PaginationMeta.swift b/Sources/Schemas/PaginationMeta.swift index a677d93..742f6dd 100644 --- a/Sources/Schemas/PaginationMeta.swift +++ b/Sources/Schemas/PaginationMeta.swift @@ -1,11 +1,18 @@ import Foundation +/// Pagination and retention metadata returned with a paginated list of phone numbers. public struct PaginationMeta: Codable, Hashable, Sendable { + /// The number of phone numbers returned per page. public let itemsPerPage: Double + /// The total number of phone numbers matching the request. public let totalItems: Double + /// The current page number. public let currentPage: Double + /// Whether additional matching phone numbers exist beyond the organization's data-retention window. public let itemsBeyondRetention: Bool? + /// The inclusive upper creation-time boundary applied to the result set. public let createdAtLe: Date? + /// The inclusive lower creation-time boundary applied to the result set. public let createdAtGe: Date? /// Additional properties that are not explicitly defined in the schema public let additionalProperties: [String: JSONValue] diff --git a/Sources/Schemas/PerformanceMetrics.swift b/Sources/Schemas/PerformanceMetrics.swift index 3034db0..17aeaf0 100644 --- a/Sources/Schemas/PerformanceMetrics.swift +++ b/Sources/Schemas/PerformanceMetrics.swift @@ -1,5 +1,6 @@ import Foundation +/// Call performance measurements, including per-turn and average provider, endpointing, transport, and interruption metrics. public struct PerformanceMetrics: Codable, Hashable, Sendable { /// These are the individual latencies for each turn. public let turnLatencies: [TurnLatency]? diff --git a/Sources/Schemas/PerplexityAiModel.swift b/Sources/Schemas/PerplexityAiModel.swift index cba855a..359006e 100644 --- a/Sources/Schemas/PerplexityAiModel.swift +++ b/Sources/Schemas/PerplexityAiModel.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for generating assistant responses with Perplexity AI, including model, prompts, tools, knowledge-base access, and generation settings. public struct PerplexityAiModel: Codable, Hashable, Sendable { /// This is the starting state for the conversation. public let messages: [OpenAiMessage]? diff --git a/Sources/Schemas/PhoneNumberCallEndingHookFilter.swift b/Sources/Schemas/PhoneNumberCallEndingHookFilter.swift index 3e66163..ad1c77c 100644 --- a/Sources/Schemas/PhoneNumberCallEndingHookFilter.swift +++ b/Sources/Schemas/PhoneNumberCallEndingHookFilter.swift @@ -1,5 +1,6 @@ import Foundation +/// Matches the call's ended reason against configured assistant-request failure reasons before an ending hook runs. public struct PhoneNumberCallEndingHookFilter: Codable, Hashable, Sendable { /// This is the type of filter - currently only "oneOf" is supported public let type: PhoneNumberCallEndingHookFilterType diff --git a/Sources/Schemas/PhoneNumberCallRingingHookFilter.swift b/Sources/Schemas/PhoneNumberCallRingingHookFilter.swift index d84f058..1cd19c4 100644 --- a/Sources/Schemas/PhoneNumberCallRingingHookFilter.swift +++ b/Sources/Schemas/PhoneNumberCallRingingHookFilter.swift @@ -1,5 +1,6 @@ import Foundation +/// Matches an incoming caller's phone number against one or more prefixes before a ringing hook runs. public struct PhoneNumberCallRingingHookFilter: Codable, Hashable, Sendable { /// This is the type of filter - matches when the specified field starts with any of the given prefixes public let type: PhoneNumberCallRingingHookFilterType diff --git a/Sources/Schemas/PhoneNumberHookCallEnding.swift b/Sources/Schemas/PhoneNumberHookCallEnding.swift index db7a94b..a1592b3 100644 --- a/Sources/Schemas/PhoneNumberHookCallEnding.swift +++ b/Sources/Schemas/PhoneNumberHookCallEnding.swift @@ -1,5 +1,6 @@ import Foundation +/// Runs configured transfer or message actions when a call ends with a matching assistant-request failure reason. public struct PhoneNumberHookCallEnding: Codable, Hashable, Sendable { /// Optional filters to decide when to trigger - restricted to assistant-request related ended reasons public let filters: [PhoneNumberCallEndingHookFilter]? diff --git a/Sources/Schemas/PhoneNumberHookCallRinging.swift b/Sources/Schemas/PhoneNumberHookCallRinging.swift index 0fcf7f9..b77bcac 100644 --- a/Sources/Schemas/PhoneNumberHookCallRinging.swift +++ b/Sources/Schemas/PhoneNumberHookCallRinging.swift @@ -1,5 +1,6 @@ import Foundation +/// Runs configured transfer or message actions when an incoming call rings and its caller-number prefix filters match. public struct PhoneNumberHookCallRinging: Codable, Hashable, Sendable { /// Optional filters to decide when to trigger the hook. Currently supports filtering by caller country code. public let filters: [PhoneNumberCallRingingHookFilter]? diff --git a/Sources/Schemas/PhoneNumberPaginatedResponse.swift b/Sources/Schemas/PhoneNumberPaginatedResponse.swift index 3a09e69..6f26c10 100644 --- a/Sources/Schemas/PhoneNumberPaginatedResponse.swift +++ b/Sources/Schemas/PhoneNumberPaginatedResponse.swift @@ -1,5 +1,6 @@ import Foundation +/// A paginated collection of phone numbers and metadata describing the result set. public struct PhoneNumberPaginatedResponse: Codable, Hashable, Sendable { /// A list of phone numbers, which can be of any provider type. public let results: [PhoneNumberPaginatedResponseResultsItem] diff --git a/Sources/Schemas/PieInsight.swift b/Sources/Schemas/PieInsight.swift index 16c99b5..8105110 100644 --- a/Sources/Schemas/PieInsight.swift +++ b/Sources/Schemas/PieInsight.swift @@ -1,5 +1,6 @@ import Foundation +/// A saved pie-chart insight containing its call-data queries, formulas, grouping, time range, and lifecycle information. public struct PieInsight: Codable, Hashable, Sendable { /// This is the name of the Insight. public let name: String? @@ -19,6 +20,7 @@ public struct PieInsight: Codable, Hashable, Sendable { /// /// You can also use the query names as the variable in the formula. public let formulas: [InsightFormula]? + /// The time range used to query the pie-chart data. public let timeRange: InsightTimeRange? /// This is the group by column for the insight when table is `call`. /// These are the columns to group the results by. diff --git a/Sources/Schemas/PlayHtVoice.swift b/Sources/Schemas/PlayHtVoice.swift index 787e02b..6287ffa 100644 --- a/Sources/Schemas/PlayHtVoice.swift +++ b/Sources/Schemas/PlayHtVoice.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for synthesizing assistant speech with PlayHT, including voice and model selection, language, emotion and style guidance, chunking, caching, and fallback settings. public struct PlayHtVoice: Codable, Hashable, Sendable { /// This is the flag to toggle voice caching for the assistant. public let cachingEnabled: Bool? diff --git a/Sources/Schemas/PromptInjectionSecurityFilter.swift b/Sources/Schemas/PromptInjectionSecurityFilter.swift index 840a341..39405ae 100644 --- a/Sources/Schemas/PromptInjectionSecurityFilter.swift +++ b/Sources/Schemas/PromptInjectionSecurityFilter.swift @@ -1,5 +1,6 @@ import Foundation +/// Filters potential prompt-injection patterns from transcripts. public struct PromptInjectionSecurityFilter: Codable, Hashable, Sendable { /// The type of security threat to filter. public let type: PromptInjectionSecurityFilterType diff --git a/Sources/Schemas/ProviderResource.swift b/Sources/Schemas/ProviderResource.swift index ef4730d..7092cd5 100644 --- a/Sources/Schemas/ProviderResource.swift +++ b/Sources/Schemas/ProviderResource.swift @@ -1,5 +1,6 @@ import Foundation +/// A provider-managed pronunciation-dictionary resource mirrored in Vapi, including its provider identifiers, resource data, and lifecycle information. public struct ProviderResource: Codable, Hashable, Sendable { /// This is the unique identifier for the provider resource. public let id: String diff --git a/Sources/Schemas/ProviderResourcePaginatedResponse.swift b/Sources/Schemas/ProviderResourcePaginatedResponse.swift index 0c6780c..5ea8efc 100644 --- a/Sources/Schemas/ProviderResourcePaginatedResponse.swift +++ b/Sources/Schemas/ProviderResourcePaginatedResponse.swift @@ -1,7 +1,10 @@ import Foundation +/// A paginated collection of provider resources and metadata describing the result set. public struct ProviderResourcePaginatedResponse: Codable, Hashable, Sendable { + /// The provider resources returned for the current page. public let results: [ProviderResource] + /// Pagination metadata for the provider-resource result set. public let metadata: PaginationMeta /// Additional properties that are not explicitly defined in the schema public let additionalProperties: [String: JSONValue] diff --git a/Sources/Schemas/PublicKeyEncryptionPlan.swift b/Sources/Schemas/PublicKeyEncryptionPlan.swift index 3de362f..2aece3e 100644 --- a/Sources/Schemas/PublicKeyEncryptionPlan.swift +++ b/Sources/Schemas/PublicKeyEncryptionPlan.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for encrypting sensitive outbound request data with a public key. public struct PublicKeyEncryptionPlan: Codable, Hashable, Sendable { /// The encryption algorithm to use. public let algorithm: PublicKeyEncryptionPlanAlgorithm diff --git a/Sources/Schemas/QueryTool.swift b/Sources/Schemas/QueryTool.swift index 8b6b22b..42fc54a 100644 --- a/Sources/Schemas/QueryTool.swift +++ b/Sources/Schemas/QueryTool.swift @@ -1,5 +1,6 @@ import Foundation +/// A reusable tool that searches configured knowledge bases and returns relevant content to the assistant. public struct QueryTool: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/RceSecurityFilter.swift b/Sources/Schemas/RceSecurityFilter.swift index 21a3e83..fbefbc3 100644 --- a/Sources/Schemas/RceSecurityFilter.swift +++ b/Sources/Schemas/RceSecurityFilter.swift @@ -1,5 +1,6 @@ import Foundation +/// Filters potential remote code execution (RCE) patterns from transcripts. public struct RceSecurityFilter: Codable, Hashable, Sendable { /// The type of security threat to filter. public let type: RceSecurityFilterType diff --git a/Sources/Schemas/Recording.swift b/Sources/Schemas/Recording.swift index f6ed312..fc1c2c1 100644 --- a/Sources/Schemas/Recording.swift +++ b/Sources/Schemas/Recording.swift @@ -1,5 +1,6 @@ import Foundation +/// Call recording locations, including stereo, video, and separated mono recording URLs. public struct Recording: Codable, Hashable, Sendable { /// This is the stereo recording url for the call. To enable, set `assistant.artifactPlan.recordingEnabled`. public let stereoUrl: String? diff --git a/Sources/Schemas/RecordingConsent.swift b/Sources/Schemas/RecordingConsent.swift index 12e6f01..9cbcacf 100644 --- a/Sources/Schemas/RecordingConsent.swift +++ b/Sources/Schemas/RecordingConsent.swift @@ -1,5 +1,6 @@ import Foundation +/// Result of the recording-consent flow, including consent type and the time consent was granted. public struct RecordingConsent: Codable, Hashable, Sendable { /// This is the type of recording consent. public let type: [String: JSONValue] diff --git a/Sources/Schemas/RecordingConsentPlanStayOnLine.swift b/Sources/Schemas/RecordingConsentPlanStayOnLine.swift index ffdf4c4..6dd7a26 100644 --- a/Sources/Schemas/RecordingConsentPlanStayOnLine.swift +++ b/Sources/Schemas/RecordingConsentPlanStayOnLine.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for requesting recording consent by treating continued presence on the call as consent, including the announcement voice and wait time. public struct RecordingConsentPlanStayOnLine: Codable, Hashable, Sendable { /// This is the message asking for consent to record the call. /// If the type is `stay-on-line`, the message should ask the user to hang up if they do not consent. diff --git a/Sources/Schemas/RecordingConsentPlanVerbal.swift b/Sources/Schemas/RecordingConsentPlanVerbal.swift index 1744df4..bfb92fa 100644 --- a/Sources/Schemas/RecordingConsentPlanVerbal.swift +++ b/Sources/Schemas/RecordingConsentPlanVerbal.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for requesting explicit verbal recording consent, including the announcement voice and action to take when the customer declines. public struct RecordingConsentPlanVerbal: Codable, Hashable, Sendable { /// This is the message asking for consent to record the call. /// If the type is `stay-on-line`, the message should ask the user to hang up if they do not consent. diff --git a/Sources/Schemas/RegexCondition.swift b/Sources/Schemas/RegexCondition.swift index 9c2f92a..10a5845 100644 --- a/Sources/Schemas/RegexCondition.swift +++ b/Sources/Schemas/RegexCondition.swift @@ -1,5 +1,6 @@ import Foundation +/// Evaluates whether targeted conversation-message content matches a regular expression. public struct RegexCondition: Codable, Hashable, Sendable { /// This is the regular expression pattern to match against message content. /// diff --git a/Sources/Schemas/RegexOption.swift b/Sources/Schemas/RegexOption.swift index a335396..fe086a1 100644 --- a/Sources/Schemas/RegexOption.swift +++ b/Sources/Schemas/RegexOption.swift @@ -1,5 +1,6 @@ import Foundation +/// Enables or disables one regular-expression matching option for a text replacement. public struct RegexOption: Codable, Hashable, Sendable { /// This is the type of the regex option. Options are: /// - `ignore-case`: Ignores the case of the text being matched. Add diff --git a/Sources/Schemas/RegexReplacement.swift b/Sources/Schemas/RegexReplacement.swift index 18cabee..9fbd021 100644 --- a/Sources/Schemas/RegexReplacement.swift +++ b/Sources/Schemas/RegexReplacement.swift @@ -1,5 +1,6 @@ import Foundation +/// Replaces text matching a regular expression before it is sent to a voice provider. public struct RegexReplacement: Codable, Hashable, Sendable { /// This is the regex pattern to replace. /// diff --git a/Sources/Schemas/RegexSecurityFilter.swift b/Sources/Schemas/RegexSecurityFilter.swift index cd6b963..292e907 100644 --- a/Sources/Schemas/RegexSecurityFilter.swift +++ b/Sources/Schemas/RegexSecurityFilter.swift @@ -1,5 +1,6 @@ import Foundation +/// Filters transcript content that matches a custom regular expression. public struct RegexSecurityFilter: Codable, Hashable, Sendable { /// The type of security threat to filter. public let type: RegexSecurityFilterType diff --git a/Sources/Schemas/RimeAiVoice.swift b/Sources/Schemas/RimeAiVoice.swift index c2080f9..e155f4d 100644 --- a/Sources/Schemas/RimeAiVoice.swift +++ b/Sources/Schemas/RimeAiVoice.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for synthesizing assistant speech with Rime AI, including voice and model selection, language, speed, pauses, phonemization, latency, chunking, caching, and fallback settings. public struct RimeAiVoice: Codable, Hashable, Sendable { /// This is the flag to toggle voice caching for the assistant. public let cachingEnabled: Bool? diff --git a/Sources/Schemas/SayHookAction.swift b/Sources/Schemas/SayHookAction.swift index 168f6fd..24c3229 100644 --- a/Sources/Schemas/SayHookAction.swift +++ b/Sources/Schemas/SayHookAction.swift @@ -1,5 +1,6 @@ import Foundation +/// A hook action that makes the assistant speak exact text or generate a response from a prompt. public struct SayHookAction: Codable, Hashable, Sendable { /// This is the prompt for the assistant to generate a response based on existing conversation. /// Can be a string or an array of chat messages. diff --git a/Sources/Schemas/SayPhoneNumberHookAction.swift b/Sources/Schemas/SayPhoneNumberHookAction.swift index 4db3c28..7519aad 100644 --- a/Sources/Schemas/SayPhoneNumberHookAction.swift +++ b/Sources/Schemas/SayPhoneNumberHookAction.swift @@ -1,5 +1,6 @@ import Foundation +/// A phone-number hook action that speaks an exact message to the caller. public struct SayPhoneNumberHookAction: Codable, Hashable, Sendable { /// This is the message to say public let exact: String diff --git a/Sources/Schemas/SbcConfiguration.swift b/Sources/Schemas/SbcConfiguration.swift index d9749df..81ea181 100644 --- a/Sources/Schemas/SbcConfiguration.swift +++ b/Sources/Schemas/SbcConfiguration.swift @@ -1,5 +1,6 @@ import Foundation +/// Routes bring-your-own SIP traffic through an on-premises session border controller instead of Vapi's managed controller. public struct SbcConfiguration: Codable, Hashable, Sendable { /// Additional properties that are not explicitly defined in the schema public let additionalProperties: [String: JSONValue] diff --git a/Sources/Schemas/SchedulePlan.swift b/Sources/Schemas/SchedulePlan.swift index 51f08d8..82c0938 100644 --- a/Sources/Schemas/SchedulePlan.swift +++ b/Sources/Schemas/SchedulePlan.swift @@ -1,5 +1,6 @@ import Foundation +/// Time window that controls the earliest and latest time a call may begin. public struct SchedulePlan: Codable, Hashable, Sendable { /// This is the ISO 8601 date-time string of the earliest time the call can be scheduled. public let earliestAt: Date diff --git a/Sources/Schemas/Scorecard.swift b/Sources/Schemas/Scorecard.swift index 8b7f36e..45d18e1 100644 --- a/Sources/Schemas/Scorecard.swift +++ b/Sources/Schemas/Scorecard.swift @@ -1,5 +1,6 @@ import Foundation +/// A saved scorecard containing its evaluation metrics, scoring conditions, assistant associations, descriptive metadata, and lifecycle information. public struct Scorecard: Codable, Hashable, Sendable { /// This is the unique identifier for the scorecard. public let id: String diff --git a/Sources/Schemas/ScorecardMetric.swift b/Sources/Schemas/ScorecardMetric.swift index d022d32..8ca080d 100644 --- a/Sources/Schemas/ScorecardMetric.swift +++ b/Sources/Schemas/ScorecardMetric.swift @@ -1,5 +1,6 @@ import Foundation +/// A scorecard metric that awards points when a structured output meets its configured conditions. public struct ScorecardMetric: Codable, Hashable, Sendable { /// This is the unique identifier for the structured output that will be used to evaluate the scorecard. /// The structured output must be of type number or boolean only for now. diff --git a/Sources/Schemas/ScorecardPaginatedResponse.swift b/Sources/Schemas/ScorecardPaginatedResponse.swift index e786579..0a09b88 100644 --- a/Sources/Schemas/ScorecardPaginatedResponse.swift +++ b/Sources/Schemas/ScorecardPaginatedResponse.swift @@ -1,7 +1,10 @@ import Foundation +/// A paginated collection of scorecards and metadata describing the result set. public struct ScorecardPaginatedResponse: Codable, Hashable, Sendable { + /// The scorecards returned for the current page. public let results: [Scorecard] + /// Pagination metadata for the scorecard result set. public let metadata: PaginationMeta /// Additional properties that are not explicitly defined in the schema public let additionalProperties: [String: JSONValue] diff --git a/Sources/Schemas/SecurityFilterBase.swift b/Sources/Schemas/SecurityFilterBase.swift index 5001423..9a612ca 100644 --- a/Sources/Schemas/SecurityFilterBase.swift +++ b/Sources/Schemas/SecurityFilterBase.swift @@ -1,5 +1,6 @@ import Foundation +/// Base configuration for a security filter applied to transcripts before model processing. public struct SecurityFilterBase: Codable, Hashable, Sendable { /// Additional properties that are not explicitly defined in the schema public let additionalProperties: [String: JSONValue] diff --git a/Sources/Schemas/SecurityFilterPlan.swift b/Sources/Schemas/SecurityFilterPlan.swift index ae6e5f0..62b627c 100644 --- a/Sources/Schemas/SecurityFilterPlan.swift +++ b/Sources/Schemas/SecurityFilterPlan.swift @@ -1,5 +1,6 @@ import Foundation +/// Controls filtering of transcripts for security threats before content is sent to the assistant's language model, including filter selection, handling mode, and replacement text. public struct SecurityFilterPlan: Codable, Hashable, Sendable { /// Whether the security filter is enabled. /// @default false diff --git a/Sources/Schemas/Server.swift b/Sources/Schemas/Server.swift index 362e159..18be5f6 100644 --- a/Sources/Schemas/Server.swift +++ b/Sources/Schemas/Server.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for requests Vapi sends to a customer server, including URL, authentication, headers, timeout, encryption, static IP addresses, and retry behavior. public struct Server: Codable, Hashable, Sendable { /// This is the timeout in seconds for the request. Defaults to 20 seconds. /// diff --git a/Sources/Schemas/SesameVoice.swift b/Sources/Schemas/SesameVoice.swift index 22a4ddf..56e933d 100644 --- a/Sources/Schemas/SesameVoice.swift +++ b/Sources/Schemas/SesameVoice.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for synthesizing assistant speech with Sesame, including voice and model selection, chunking, caching, and fallback settings. public struct SesameVoice: Codable, Hashable, Sendable { /// This is the flag to toggle voice caching for the assistant. public let cachingEnabled: Bool? diff --git a/Sources/Schemas/SipAuthentication.swift b/Sources/Schemas/SipAuthentication.swift index 83b864d..3a57c0b 100644 --- a/Sources/Schemas/SipAuthentication.swift +++ b/Sources/Schemas/SipAuthentication.swift @@ -1,5 +1,6 @@ import Foundation +/// Realm, username, and password used to authenticate SIP requests. public struct SipAuthentication: Codable, Hashable, Sendable { /// This will be expected in the `realm` field of the `authorization` header of the SIP INVITE. Defaults to sip.vapi.ai. public let realm: String? diff --git a/Sources/Schemas/SipRequestTool.swift b/Sources/Schemas/SipRequestTool.swift index 9cf4bc4..b131e18 100644 --- a/Sources/Schemas/SipRequestTool.swift +++ b/Sources/Schemas/SipRequestTool.swift @@ -1,5 +1,6 @@ import Foundation +/// A reusable tool that sends SIP `INFO`, `MESSAGE`, or `NOTIFY` requests with configured headers and body. public struct SipRequestTool: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/SipTrunkGateway.swift b/Sources/Schemas/SipTrunkGateway.swift index d08b52b..152d16f 100644 --- a/Sources/Schemas/SipTrunkGateway.swift +++ b/Sources/Schemas/SipTrunkGateway.swift @@ -1,5 +1,6 @@ import Foundation +/// Network and routing settings for a SIP trunk gateway, including address, port, netmask, inbound and outbound use, signaling protocol, and OPTIONS health checks. public struct SipTrunkGateway: Codable, Hashable, Sendable { /// This is the address of the gateway. It can be an IPv4 address like 1.1.1.1 or a fully qualified domain name like my-sip-trunk.pstn.twilio.com. public let ip: String diff --git a/Sources/Schemas/SipTrunkOutboundAuthenticationPlan.swift b/Sources/Schemas/SipTrunkOutboundAuthenticationPlan.swift index 53df62b..6c63387 100644 --- a/Sources/Schemas/SipTrunkOutboundAuthenticationPlan.swift +++ b/Sources/Schemas/SipTrunkOutboundAuthenticationPlan.swift @@ -1,8 +1,10 @@ import Foundation +/// Credentials and optional SIP REGISTER settings used to authenticate outbound calls with a SIP trunk. public struct SipTrunkOutboundAuthenticationPlan: Codable, Hashable, Sendable { /// This is not returned in the API. public let authPassword: String? + /// Username used to authenticate outbound SIP requests. public let authUsername: String? /// This can be used to configure if SIP register is required by the SIP trunk. If not provided, no SIP registration will be attempted. public let sipRegisterPlan: SipTrunkOutboundSipRegisterPlan? diff --git a/Sources/Schemas/SipTrunkOutboundSipRegisterPlan.swift b/Sources/Schemas/SipTrunkOutboundSipRegisterPlan.swift index 2eb0c7c..057c13b 100644 --- a/Sources/Schemas/SipTrunkOutboundSipRegisterPlan.swift +++ b/Sources/Schemas/SipTrunkOutboundSipRegisterPlan.swift @@ -1,8 +1,12 @@ import Foundation +/// Registration settings used when the SIP trunk requires SIP REGISTER. public struct SipTrunkOutboundSipRegisterPlan: Codable, Hashable, Sendable { + /// SIP registrar domain used for registration. public let domain: String? + /// Username sent with the SIP REGISTER request. public let username: String? + /// Authentication realm used for SIP registration. public let realm: String? /// Additional properties that are not explicitly defined in the schema public let additionalProperties: [String: JSONValue] diff --git a/Sources/Schemas/SlackSendMessageTool.swift b/Sources/Schemas/SlackSendMessageTool.swift index 156117d..870bf01 100644 --- a/Sources/Schemas/SlackSendMessageTool.swift +++ b/Sources/Schemas/SlackSendMessageTool.swift @@ -1,5 +1,6 @@ import Foundation +/// A reusable tool that lets an assistant send a message to Slack. public struct SlackSendMessageTool: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/SmallestAiVoice.swift b/Sources/Schemas/SmallestAiVoice.swift index 2034581..6176f4f 100644 --- a/Sources/Schemas/SmallestAiVoice.swift +++ b/Sources/Schemas/SmallestAiVoice.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for synthesizing assistant speech with Smallest AI, including voice and model selection, speed, chunking, caching, and fallback settings. public struct SmallestAiVoice: Codable, Hashable, Sendable { /// This is the flag to toggle voice caching for the assistant. public let cachingEnabled: Bool? diff --git a/Sources/Schemas/SmartDenoisingPlan.swift b/Sources/Schemas/SmartDenoisingPlan.swift index 0e526ae..ed174e4 100644 --- a/Sources/Schemas/SmartDenoisingPlan.swift +++ b/Sources/Schemas/SmartDenoisingPlan.swift @@ -1,5 +1,6 @@ import Foundation +/// Controls whether Krisp smart denoising filters background speech and noise. public struct SmartDenoisingPlan: Codable, Hashable, Sendable { /// Whether smart denoising using Krisp is enabled. public let enabled: Bool? diff --git a/Sources/Schemas/SmsTool.swift b/Sources/Schemas/SmsTool.swift index fca45b6..86a2b44 100644 --- a/Sources/Schemas/SmsTool.swift +++ b/Sources/Schemas/SmsTool.swift @@ -1,5 +1,6 @@ import Foundation +/// A reusable tool that lets an assistant send an SMS message during a call. public struct SmsTool: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/SonioxTranscriber.swift b/Sources/Schemas/SonioxTranscriber.swift index 98fb8b1..4ab46a6 100644 --- a/Sources/Schemas/SonioxTranscriber.swift +++ b/Sources/Schemas/SonioxTranscriber.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for transcribing speech during assistant conversations with Soniox, including model, language detection, endpointing, vocabulary, and fallback settings. public struct SonioxTranscriber: Codable, Hashable, Sendable { /// The Soniox model to use for transcription. public let model: SonioxTranscriberModel? diff --git a/Sources/Schemas/SpeechmaticsCustomVocabularyItem.swift b/Sources/Schemas/SpeechmaticsCustomVocabularyItem.swift index f24b4bc..d22f60e 100644 --- a/Sources/Schemas/SpeechmaticsCustomVocabularyItem.swift +++ b/Sources/Schemas/SpeechmaticsCustomVocabularyItem.swift @@ -1,5 +1,6 @@ import Foundation +/// A word or phrase to prioritize during Speechmatics transcription, with optional phonetic alternatives. public struct SpeechmaticsCustomVocabularyItem: Codable, Hashable, Sendable { /// The word or phrase to add to the custom vocabulary. public let content: String diff --git a/Sources/Schemas/SpeechmaticsTranscriber.swift b/Sources/Schemas/SpeechmaticsTranscriber.swift index a66e6c8..b764cb3 100644 --- a/Sources/Schemas/SpeechmaticsTranscriber.swift +++ b/Sources/Schemas/SpeechmaticsTranscriber.swift @@ -1,8 +1,10 @@ import Foundation +/// Configuration for transcribing speech during assistant conversations with Speechmatics, including language, region, diarization, vocabulary, endpointing, formatting, and fallback settings. public struct SpeechmaticsTranscriber: Codable, Hashable, Sendable { /// This is the model that will be used for the transcription. public let model: SpeechmaticsTranscriberModel? + /// Language used for transcription. Set to `auto` to detect the language automatically. public let language: SpeechmaticsTranscriberLanguage? /// This is the operating point for the transcription. Choose between `standard` for faster turnaround with strong accuracy or `enhanced` for highest accuracy when precision is critical. /// @@ -20,6 +22,7 @@ public struct SpeechmaticsTranscriber: Codable, Hashable, Sendable { /// /// @default 3000 public let maxDelay: Double? + /// Words and phrases that Speechmatics should recognize more accurately, with optional phonetic alternatives. public let customVocabulary: [SpeechmaticsCustomVocabularyItem] /// This controls how numbers, dates, currencies, and other entities are formatted in the transcription output. /// diff --git a/Sources/Schemas/SpeechmaticsTranscriberLanguage.swift b/Sources/Schemas/SpeechmaticsTranscriberLanguage.swift index e88597e..2802315 100644 --- a/Sources/Schemas/SpeechmaticsTranscriberLanguage.swift +++ b/Sources/Schemas/SpeechmaticsTranscriberLanguage.swift @@ -1,5 +1,6 @@ import Foundation +/// Language used for transcription. Set to `auto` to detect the language automatically. public enum SpeechmaticsTranscriberLanguage: String, Codable, Hashable, CaseIterable, Sendable { case auto case ar diff --git a/Sources/Schemas/SpkiPemPublicKeyConfig.swift b/Sources/Schemas/SpkiPemPublicKeyConfig.swift index e40e10e..c39df06 100644 --- a/Sources/Schemas/SpkiPemPublicKeyConfig.swift +++ b/Sources/Schemas/SpkiPemPublicKeyConfig.swift @@ -1,5 +1,6 @@ import Foundation +/// An SPKI public key in PEM format used to encrypt sensitive request data. public struct SpkiPemPublicKeyConfig: Codable, Hashable, Sendable { /// Optional name of the key for identification purposes. public let name: String? diff --git a/Sources/Schemas/SqlInjectionSecurityFilter.swift b/Sources/Schemas/SqlInjectionSecurityFilter.swift index f9e63c0..845348c 100644 --- a/Sources/Schemas/SqlInjectionSecurityFilter.swift +++ b/Sources/Schemas/SqlInjectionSecurityFilter.swift @@ -1,5 +1,6 @@ import Foundation +/// Filters potential SQL injection patterns from transcripts. public struct SqlInjectionSecurityFilter: Codable, Hashable, Sendable { /// The type of security threat to filter. public let type: SqlInjectionSecurityFilterType diff --git a/Sources/Schemas/Squad.swift b/Sources/Schemas/Squad.swift index edb3fd7..dd1a37c 100644 --- a/Sources/Schemas/Squad.swift +++ b/Sources/Schemas/Squad.swift @@ -1,5 +1,6 @@ import Foundation +/// A saved squad configuration that coordinates a group of assistants during a conversation. The first member starts the call, and member destinations control transfers between assistants. public struct Squad: Codable, Hashable, Sendable { /// This is the name of the squad. public let name: String? diff --git a/Sources/Schemas/SquadMemberDto.swift b/Sources/Schemas/SquadMemberDto.swift index 3fb1205..898b027 100644 --- a/Sources/Schemas/SquadMemberDto.swift +++ b/Sources/Schemas/SquadMemberDto.swift @@ -1,6 +1,8 @@ import Foundation +/// An assistant member of a squad. Reference a saved assistant or provide a transient assistant, then configure member-specific overrides and destinations for transfers. public struct SquadMemberDto: Codable, Hashable, Sendable { + /// Assistants this squad member can route the conversation to through a transfer or handoff. public let assistantDestinations: [SquadMemberDtoAssistantDestinationsItem]? /// This is the assistant that will be used for the call. To use a transient assistant, use `assistant` instead. public let assistantId: Nullable? diff --git a/Sources/Schemas/SsrfSecurityFilter.swift b/Sources/Schemas/SsrfSecurityFilter.swift index ba6472e..5241550 100644 --- a/Sources/Schemas/SsrfSecurityFilter.swift +++ b/Sources/Schemas/SsrfSecurityFilter.swift @@ -1,5 +1,6 @@ import Foundation +/// Filters potential server-side request forgery (SSRF) patterns from transcripts. public struct SsrfSecurityFilter: Codable, Hashable, Sendable { /// The type of security threat to filter. public let type: SsrfSecurityFilterType diff --git a/Sources/Schemas/StartSpeakingPlan.swift b/Sources/Schemas/StartSpeakingPlan.swift index f20d0db..97138e3 100644 --- a/Sources/Schemas/StartSpeakingPlan.swift +++ b/Sources/Schemas/StartSpeakingPlan.swift @@ -1,5 +1,6 @@ import Foundation +/// Controls when the assistant begins speaking after customer speech, including the minimum wait, endpointing strategy, and custom endpointing rules. public struct StartSpeakingPlan: Codable, Hashable, Sendable { /// This is how long assistant waits before speaking. Defaults to 0.4. /// diff --git a/Sources/Schemas/StopSpeakingPlan.swift b/Sources/Schemas/StopSpeakingPlan.swift index d71ed1b..963d88a 100644 --- a/Sources/Schemas/StopSpeakingPlan.swift +++ b/Sources/Schemas/StopSpeakingPlan.swift @@ -1,5 +1,6 @@ import Foundation +/// Controls when the assistant stops speaking after a customer interruption, including word and voice thresholds, restart delay, and phrase exceptions. public struct StopSpeakingPlan: Codable, Hashable, Sendable { /// This is the number of words that the customer has to say before the assistant will stop talking. /// diff --git a/Sources/Schemas/StructuredDataMultiPlan.swift b/Sources/Schemas/StructuredDataMultiPlan.swift index 30839a6..20d64fa 100644 --- a/Sources/Schemas/StructuredDataMultiPlan.swift +++ b/Sources/Schemas/StructuredDataMultiPlan.swift @@ -1,5 +1,6 @@ import Foundation +/// Associates a catalog key with a structured data extraction plan. public struct StructuredDataMultiPlan: Codable, Hashable, Sendable { /// This is the key of the structured data plan in the catalog. public let key: String diff --git a/Sources/Schemas/StructuredDataPlan.swift b/Sources/Schemas/StructuredDataPlan.swift index 0d24ad3..45f39bb 100644 --- a/Sources/Schemas/StructuredDataPlan.swift +++ b/Sources/Schemas/StructuredDataPlan.swift @@ -1,5 +1,6 @@ import Foundation +/// Controls extraction of post-call structured data, including prompt messages, JSON schema, enablement, and request timeout. public struct StructuredDataPlan: Codable, Hashable, Sendable { /// These are the messages used to generate the structured data. /// diff --git a/Sources/Schemas/StructuredOutput.swift b/Sources/Schemas/StructuredOutput.swift index 52a2763..e141a24 100644 --- a/Sources/Schemas/StructuredOutput.swift +++ b/Sources/Schemas/StructuredOutput.swift @@ -1,5 +1,6 @@ import Foundation +/// A saved structured-output definition containing its extraction schema, execution method, model or regular expression, linked resources, and lifecycle metadata. public struct StructuredOutput: Codable, Hashable, Sendable { /// This is the type of structured output. /// diff --git a/Sources/Schemas/StructuredOutputPaginatedResponse.swift b/Sources/Schemas/StructuredOutputPaginatedResponse.swift index 69e176c..7209e2a 100644 --- a/Sources/Schemas/StructuredOutputPaginatedResponse.swift +++ b/Sources/Schemas/StructuredOutputPaginatedResponse.swift @@ -1,7 +1,10 @@ import Foundation +/// A paginated collection of structured-output definitions and metadata describing the result set. public struct StructuredOutputPaginatedResponse: Codable, Hashable, Sendable { + /// The structured-output definitions returned for the current page. public let results: [StructuredOutput] + /// Pagination metadata for the structured-output result set. public let metadata: PaginationMeta /// Additional properties that are not explicitly defined in the schema public let additionalProperties: [String: JSONValue] diff --git a/Sources/Schemas/SubscriptionLimits.swift b/Sources/Schemas/SubscriptionLimits.swift index ddf34e7..091d39c 100644 --- a/Sources/Schemas/SubscriptionLimits.swift +++ b/Sources/Schemas/SubscriptionLimits.swift @@ -1,5 +1,6 @@ import Foundation +/// Organization concurrency limits and remaining concurrent call capacity. public struct SubscriptionLimits: Codable, Hashable, Sendable { /// True if this call was blocked by the Call Concurrency limit public let concurrencyBlocked: Bool? diff --git a/Sources/Schemas/SuccessEvaluationPlan.swift b/Sources/Schemas/SuccessEvaluationPlan.swift index daf83a5..fdd76f5 100644 --- a/Sources/Schemas/SuccessEvaluationPlan.swift +++ b/Sources/Schemas/SuccessEvaluationPlan.swift @@ -1,5 +1,6 @@ import Foundation +/// Controls post-call success evaluation, including the rubric, prompt messages, enablement, and request timeout. public struct SuccessEvaluationPlan: Codable, Hashable, Sendable { /// This enforces the rubric of the evaluation. The output is stored in `call.analysis.successEvaluation`. /// diff --git a/Sources/Schemas/SummaryPlan.swift b/Sources/Schemas/SummaryPlan.swift index 9fa4e68..5d38461 100644 --- a/Sources/Schemas/SummaryPlan.swift +++ b/Sources/Schemas/SummaryPlan.swift @@ -1,5 +1,6 @@ import Foundation +/// Controls generation of a post-call summary, including prompt messages, enablement, and request timeout. public struct SummaryPlan: Codable, Hashable, Sendable { /// These are the messages used to generate the summary. /// diff --git a/Sources/Schemas/SupabaseBucketPlan.swift b/Sources/Schemas/SupabaseBucketPlan.swift index 5966320..6a6c78f 100644 --- a/Sources/Schemas/SupabaseBucketPlan.swift +++ b/Sources/Schemas/SupabaseBucketPlan.swift @@ -1,5 +1,6 @@ import Foundation +/// Supabase S3-compatible bucket configuration for call artifacts, including region, endpoint, access keys, bucket name, and path. public struct SupabaseBucketPlan: Codable, Hashable, Sendable { /// This is the S3 Region. It should look like us-east-1 /// It should be one of the supabase regions defined in the SUPABASE_REGION enum diff --git a/Sources/Schemas/SystemMessage.swift b/Sources/Schemas/SystemMessage.swift index bd1308e..702f2a2 100644 --- a/Sources/Schemas/SystemMessage.swift +++ b/Sources/Schemas/SystemMessage.swift @@ -1,5 +1,6 @@ import Foundation +/// A system-authored entry in the call message history, including its content and timing. public struct SystemMessage: Codable, Hashable, Sendable { /// The role of the system in the conversation. public let role: String diff --git a/Sources/Schemas/TalkscriberTranscriber.swift b/Sources/Schemas/TalkscriberTranscriber.swift index a40f027..dd0b590 100644 --- a/Sources/Schemas/TalkscriberTranscriber.swift +++ b/Sources/Schemas/TalkscriberTranscriber.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for transcribing speech during assistant conversations with Talkscriber, including model, language, and fallback settings. public struct TalkscriberTranscriber: Codable, Hashable, Sendable { /// This is the model that will be used for the transcription. public let model: TalkscriberTranscriberModel? diff --git a/Sources/Schemas/TavusConversationProperties.swift b/Sources/Schemas/TavusConversationProperties.swift index eaac036..893180f 100644 --- a/Sources/Schemas/TavusConversationProperties.swift +++ b/Sources/Schemas/TavusConversationProperties.swift @@ -1,5 +1,6 @@ import Foundation +/// Tavus conversation behavior and media settings, including duration, participant timeouts, recording, transcription, background, language, and recording storage. public struct TavusConversationProperties: Codable, Hashable, Sendable { /// The maximum duration of the call in seconds. The default `maxCallDuration` is 3600 seconds (1 hour). /// Once the time limit specified by this parameter has been reached, the conversation will automatically shut down. diff --git a/Sources/Schemas/TavusVoice.swift b/Sources/Schemas/TavusVoice.swift index 5690254..ce15aaf 100644 --- a/Sources/Schemas/TavusVoice.swift +++ b/Sources/Schemas/TavusVoice.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for using Tavus as the assistant's voice provider, including persona, callback, context, greeting, conversation properties, chunking, caching, and fallback settings. public struct TavusVoice: Codable, Hashable, Sendable { /// This is the flag to toggle voice caching for the assistant. public let cachingEnabled: Bool? diff --git a/Sources/Schemas/TelnyxPhoneNumber.swift b/Sources/Schemas/TelnyxPhoneNumber.swift index 5089e0d..4a73444 100644 --- a/Sources/Schemas/TelnyxPhoneNumber.swift +++ b/Sources/Schemas/TelnyxPhoneNumber.swift @@ -1,5 +1,6 @@ import Foundation +/// A Telnyx phone number connected to Vapi, including its credential, routing, hooks, server settings, and lifecycle metadata. public struct TelnyxPhoneNumber: Codable, Hashable, Sendable { /// This is the fallback destination an inbound call will be transferred to if: /// 1. `assistantId` is not set diff --git a/Sources/Schemas/TextContent.swift b/Sources/Schemas/TextContent.swift index d496209..45e509d 100644 --- a/Sources/Schemas/TextContent.swift +++ b/Sources/Schemas/TextContent.swift @@ -1,8 +1,12 @@ import Foundation +/// Localized text content used as a language-specific message variant. public struct TextContent: Codable, Hashable, Sendable { + /// Selects text as the content type. public let type: TextContentType + /// Text spoken or displayed for this content variant. public let text: String + /// Language code associated with this text variant. public let language: TextContentLanguage /// Additional properties that are not explicitly defined in the schema public let additionalProperties: [String: JSONValue] diff --git a/Sources/Schemas/TextContentLanguage.swift b/Sources/Schemas/TextContentLanguage.swift index e332b14..fb39ed9 100644 --- a/Sources/Schemas/TextContentLanguage.swift +++ b/Sources/Schemas/TextContentLanguage.swift @@ -1,5 +1,6 @@ import Foundation +/// Language code associated with this text variant. public enum TextContentLanguage: String, Codable, Hashable, CaseIterable, Sendable { case aa case ab diff --git a/Sources/Schemas/TextContentType.swift b/Sources/Schemas/TextContentType.swift index e3a7ed4..15450d1 100644 --- a/Sources/Schemas/TextContentType.swift +++ b/Sources/Schemas/TextContentType.swift @@ -1,5 +1,6 @@ import Foundation +/// Selects text as the content type. public enum TextContentType: String, Codable, Hashable, CaseIterable, Sendable { case text } \ No newline at end of file diff --git a/Sources/Schemas/TextEditorTool.swift b/Sources/Schemas/TextEditorTool.swift index 01befe7..fe4d8ec 100644 --- a/Sources/Schemas/TextEditorTool.swift +++ b/Sources/Schemas/TextEditorTool.swift @@ -1,5 +1,6 @@ import Foundation +/// A reusable tool that reads and edits text files in a configured environment. public struct TextEditorTool: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/TextInsight.swift b/Sources/Schemas/TextInsight.swift index c264161..0febc75 100644 --- a/Sources/Schemas/TextInsight.swift +++ b/Sources/Schemas/TextInsight.swift @@ -1,5 +1,6 @@ import Foundation +/// A saved text-value insight containing its call-data queries, formula, time range, and lifecycle information. public struct TextInsight: Codable, Hashable, Sendable { /// This is the name of the Insight. public let name: String? @@ -19,6 +20,7 @@ public struct TextInsight: Codable, Hashable, Sendable { /// /// You can also use the query names as the variable in the formula. public let formula: [String: JSONValue]? + /// The time range used to query the text-value data. public let timeRange: InsightTimeRange? /// These are the queries to run to generate the insight. /// For Text Insights, we only allow a single query, or require a formula if multiple queries are provided diff --git a/Sources/Schemas/TimeRange.swift b/Sources/Schemas/TimeRange.swift index afaa42a..78932b4 100644 --- a/Sources/Schemas/TimeRange.swift +++ b/Sources/Schemas/TimeRange.swift @@ -1,5 +1,6 @@ import Foundation +/// Start, end, timezone, and time step used for analytics aggregation. public struct TimeRange: Codable, Hashable, Sendable { /// This is the time step for aggregations. /// diff --git a/Sources/Schemas/TogetherAiModel.swift b/Sources/Schemas/TogetherAiModel.swift index ed1dcf6..40f698f 100644 --- a/Sources/Schemas/TogetherAiModel.swift +++ b/Sources/Schemas/TogetherAiModel.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for generating assistant responses with Together AI, including model, prompts, tools, knowledge-base access, and generation settings. public struct TogetherAiModel: Codable, Hashable, Sendable { /// This is the starting state for the conversation. public let messages: [OpenAiMessage]? diff --git a/Sources/Schemas/ToolCall.swift b/Sources/Schemas/ToolCall.swift index 5767b59..49ed36c 100644 --- a/Sources/Schemas/ToolCall.swift +++ b/Sources/Schemas/ToolCall.swift @@ -1,5 +1,6 @@ import Foundation +/// A tool invocation requested by the assistant, including its identifier, type, and function details. public struct ToolCall: Codable, Hashable, Sendable { /// This is the ID of the tool call public let id: String diff --git a/Sources/Schemas/ToolCallFunction.swift b/Sources/Schemas/ToolCallFunction.swift index 5568427..c80be04 100644 --- a/Sources/Schemas/ToolCallFunction.swift +++ b/Sources/Schemas/ToolCallFunction.swift @@ -1,5 +1,6 @@ import Foundation +/// The function name and serialized arguments associated with a tool call. public struct ToolCallFunction: Codable, Hashable, Sendable { /// This is the arguments to call the function with public let arguments: String diff --git a/Sources/Schemas/ToolCallHookAction.swift b/Sources/Schemas/ToolCallHookAction.swift index ab36880..9a317ec 100644 --- a/Sources/Schemas/ToolCallHookAction.swift +++ b/Sources/Schemas/ToolCallHookAction.swift @@ -1,5 +1,6 @@ import Foundation +/// A hook action that invokes an inline tool or an existing tool when the hook triggers. public struct ToolCallHookAction: Codable, Hashable, Sendable { /// This is the type of action - must be "tool" public let type: ToolCallHookActionType diff --git a/Sources/Schemas/ToolCallMessage.swift b/Sources/Schemas/ToolCallMessage.swift index 7aff5ee..db89dc3 100644 --- a/Sources/Schemas/ToolCallMessage.swift +++ b/Sources/Schemas/ToolCallMessage.swift @@ -1,5 +1,6 @@ import Foundation +/// An entry in the call message history that records one or more tool calls requested during the conversation. public struct ToolCallMessage: Codable, Hashable, Sendable { /// The role of the tool call in the conversation. public let role: String diff --git a/Sources/Schemas/ToolCallResultMessage.swift b/Sources/Schemas/ToolCallResultMessage.swift index a6b6b38..f1222cd 100644 --- a/Sources/Schemas/ToolCallResultMessage.swift +++ b/Sources/Schemas/ToolCallResultMessage.swift @@ -1,5 +1,6 @@ import Foundation +/// An entry in the call message history that records the result and metadata for a completed tool call. public struct ToolCallResultMessage: Codable, Hashable, Sendable { /// The role of the tool call result in the conversation. public let role: String diff --git a/Sources/Schemas/ToolMessage.swift b/Sources/Schemas/ToolMessage.swift index ddfbc80..7c1bb3c 100644 --- a/Sources/Schemas/ToolMessage.swift +++ b/Sources/Schemas/ToolMessage.swift @@ -1,5 +1,6 @@ import Foundation +/// A tool-result message associated with a specific tool call. public struct ToolMessage: Codable, Hashable, Sendable { /// This is the role of the message author public let role: ToolMessageRole diff --git a/Sources/Schemas/ToolMessageComplete.swift b/Sources/Schemas/ToolMessageComplete.swift index 2a15b58..d6ba022 100644 --- a/Sources/Schemas/ToolMessageComplete.swift +++ b/Sources/Schemas/ToolMessageComplete.swift @@ -1,5 +1,6 @@ import Foundation +/// Message spoken when a tool call completes, with optional language variants, argument conditions, role, and end-call behavior. public struct ToolMessageComplete: Codable, Hashable, Sendable { /// This is an alternative to the `content` property. It allows to specify variants of the same content, one per language. /// diff --git a/Sources/Schemas/ToolMessageDelayed.swift b/Sources/Schemas/ToolMessageDelayed.swift index fd3d5d7..c61115a 100644 --- a/Sources/Schemas/ToolMessageDelayed.swift +++ b/Sources/Schemas/ToolMessageDelayed.swift @@ -1,5 +1,6 @@ import Foundation +/// Message spoken when a tool call exceeds a configured response delay, with optional language variants and argument conditions. public struct ToolMessageDelayed: Codable, Hashable, Sendable { /// This is an alternative to the `content` property. It allows to specify variants of the same content, one per language. /// diff --git a/Sources/Schemas/ToolMessageFailed.swift b/Sources/Schemas/ToolMessageFailed.swift index 20677b3..6e68413 100644 --- a/Sources/Schemas/ToolMessageFailed.swift +++ b/Sources/Schemas/ToolMessageFailed.swift @@ -1,5 +1,6 @@ import Foundation +/// Message spoken when a tool call fails, with optional language variants, argument conditions, and end-call behavior. public struct ToolMessageFailed: Codable, Hashable, Sendable { /// This is an alternative to the `content` property. It allows to specify variants of the same content, one per language. /// diff --git a/Sources/Schemas/ToolMessageStart.swift b/Sources/Schemas/ToolMessageStart.swift index c865637..fa124f2 100644 --- a/Sources/Schemas/ToolMessageStart.swift +++ b/Sources/Schemas/ToolMessageStart.swift @@ -1,5 +1,6 @@ import Foundation +/// Message spoken when a tool call starts, with optional language variants, argument conditions, and blocking behavior. public struct ToolMessageStart: Codable, Hashable, Sendable { /// This is an alternative to the `content` property. It allows to specify variants of the same content, one per language. /// diff --git a/Sources/Schemas/ToolNode.swift b/Sources/Schemas/ToolNode.swift index b5a85f1..de0114f 100644 --- a/Sources/Schemas/ToolNode.swift +++ b/Sources/Schemas/ToolNode.swift @@ -1,10 +1,12 @@ import Foundation +/// A workflow node that invokes an inline tool or an existing saved tool. public struct ToolNode: Codable, Hashable, Sendable { /// This is the tool to call. To use an existing tool, send `toolId` instead. public let tool: ToolNodeTool? /// This is the tool to call. To use a transient tool, send `tool` instead. public let toolId: String? + /// Unique name used to identify this workflow node. public let name: String /// This is whether or not the node is the start of the workflow. public let isStart: Bool? diff --git a/Sources/Schemas/ToolParameter.swift b/Sources/Schemas/ToolParameter.swift index 71ae9ab..186c707 100644 --- a/Sources/Schemas/ToolParameter.swift +++ b/Sources/Schemas/ToolParameter.swift @@ -1,5 +1,6 @@ import Foundation +/// Static key-value parameter added to a tool request, with Liquid template support for string values. public struct ToolParameter: Codable, Hashable, Sendable { /// This is the key of the parameter. public let key: String diff --git a/Sources/Schemas/ToolRejectionPlan.swift b/Sources/Schemas/ToolRejectionPlan.swift index 57800a1..3562f02 100644 --- a/Sources/Schemas/ToolRejectionPlan.swift +++ b/Sources/Schemas/ToolRejectionPlan.swift @@ -1,5 +1,6 @@ import Foundation +/// Conditions evaluated to determine whether a requested tool call should be rejected. public struct ToolRejectionPlan: Codable, Hashable, Sendable { /// This is the list of conditions that must be evaluated. /// diff --git a/Sources/Schemas/TranscriberCost.swift b/Sources/Schemas/TranscriberCost.swift index fff17b1..7730cce 100644 --- a/Sources/Schemas/TranscriberCost.swift +++ b/Sources/Schemas/TranscriberCost.swift @@ -1,5 +1,6 @@ import Foundation +/// Speech-to-text cost for a call, including transcriber, billable minutes, and amount. public struct TranscriberCost: Codable, Hashable, Sendable { /// This is the transcriber that was used during the call. /// diff --git a/Sources/Schemas/TranscriptPlan.swift b/Sources/Schemas/TranscriptPlan.swift index 7aa1d1a..f3d97dc 100644 --- a/Sources/Schemas/TranscriptPlan.swift +++ b/Sources/Schemas/TranscriptPlan.swift @@ -1,5 +1,6 @@ import Foundation +/// Controls whether the call transcript is stored and the speaker names used in the transcript. public struct TranscriptPlan: Codable, Hashable, Sendable { /// This determines whether the transcript is stored in `call.artifact.transcript`. Defaults to true. /// diff --git a/Sources/Schemas/TranscriptionEndpointingPlan.swift b/Sources/Schemas/TranscriptionEndpointingPlan.swift index 67aaf1d..6c4e2c1 100644 --- a/Sources/Schemas/TranscriptionEndpointingPlan.swift +++ b/Sources/Schemas/TranscriptionEndpointingPlan.swift @@ -1,5 +1,6 @@ import Foundation +/// Controls endpointing delays based on whether customer speech ends with punctuation, without punctuation, or with a number. public struct TranscriptionEndpointingPlan: Codable, Hashable, Sendable { /// The minimum number of seconds to wait after transcription ending with punctuation before sending a request to the model. Defaults to 0.1. /// diff --git a/Sources/Schemas/TransferCallTool.swift b/Sources/Schemas/TransferCallTool.swift index a61242a..1b27713 100644 --- a/Sources/Schemas/TransferCallTool.swift +++ b/Sources/Schemas/TransferCallTool.swift @@ -1,5 +1,6 @@ import Foundation +/// A reusable tool that transfers the active call to one of its configured destinations. public struct TransferCallTool: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/TransferDestinationAssistant.swift b/Sources/Schemas/TransferDestinationAssistant.swift index 0fb162f..dda6986 100644 --- a/Sources/Schemas/TransferDestinationAssistant.swift +++ b/Sources/Schemas/TransferDestinationAssistant.swift @@ -1,5 +1,6 @@ import Foundation +/// Transfers a call to another assistant by name, with an optional message and assistant-transfer mode. public struct TransferDestinationAssistant: Codable, Hashable, Sendable { /// This is spoken to the customer before connecting them to the destination. /// @@ -9,6 +10,7 @@ public struct TransferDestinationAssistant: Codable, Hashable, Sendable { /// /// This accepts a string or a ToolMessageStart class. Latter is useful if you want to specify multiple messages for different languages through the `contents` field. public let message: TransferDestinationAssistantMessage? + /// Selects another assistant as the transfer destination. public let type: TransferDestinationAssistantType /// This is the mode to use for the transfer. Defaults to `rolling-history`. /// diff --git a/Sources/Schemas/TransferDestinationAssistantType.swift b/Sources/Schemas/TransferDestinationAssistantType.swift index 1c85e0c..6149b82 100644 --- a/Sources/Schemas/TransferDestinationAssistantType.swift +++ b/Sources/Schemas/TransferDestinationAssistantType.swift @@ -1,5 +1,6 @@ import Foundation +/// Selects another assistant as the transfer destination. public enum TransferDestinationAssistantType: String, Codable, Hashable, CaseIterable, Sendable { case assistant } \ No newline at end of file diff --git a/Sources/Schemas/TransferDestinationNumber.swift b/Sources/Schemas/TransferDestinationNumber.swift index 2cee8be..4d297cd 100644 --- a/Sources/Schemas/TransferDestinationNumber.swift +++ b/Sources/Schemas/TransferDestinationNumber.swift @@ -1,5 +1,6 @@ import Foundation +/// Transfers a call to a phone number, with optional extension, caller ID, message, transfer plan, and number validation. public struct TransferDestinationNumber: Codable, Hashable, Sendable { /// This is spoken to the customer before connecting them to the destination. /// diff --git a/Sources/Schemas/TransferDestinationSip.swift b/Sources/Schemas/TransferDestinationSip.swift index 6609b51..3a9ec97 100644 --- a/Sources/Schemas/TransferDestinationSip.swift +++ b/Sources/Schemas/TransferDestinationSip.swift @@ -1,5 +1,6 @@ import Foundation +/// Transfers a call to a SIP URI, with optional caller ID, headers, message, and transfer plan. public struct TransferDestinationSip: Codable, Hashable, Sendable { /// This is spoken to the customer before connecting them to the destination. /// diff --git a/Sources/Schemas/TransferFallbackPlan.swift b/Sources/Schemas/TransferFallbackPlan.swift index a17e0c8..c0d24f7 100644 --- a/Sources/Schemas/TransferFallbackPlan.swift +++ b/Sources/Schemas/TransferFallbackPlan.swift @@ -1,5 +1,6 @@ import Foundation +/// Controls the message and end-call behavior used when a call transfer fails. public struct TransferFallbackPlan: Codable, Hashable, Sendable { /// This is the message the assistant will deliver to the customer if the transfer fails. public let message: TransferFallbackPlanMessage diff --git a/Sources/Schemas/TransferPhoneNumberHookAction.swift b/Sources/Schemas/TransferPhoneNumberHookAction.swift index d86f3a4..688c2b6 100644 --- a/Sources/Schemas/TransferPhoneNumberHookAction.swift +++ b/Sources/Schemas/TransferPhoneNumberHookAction.swift @@ -1,5 +1,6 @@ import Foundation +/// A phone-number hook action that transfers the call to a phone number or SIP destination. public struct TransferPhoneNumberHookAction: Codable, Hashable, Sendable { /// This is the destination details for the transfer - can be a phone number or SIP URI public let destination: TransferPhoneNumberHookActionDestination? diff --git a/Sources/Schemas/TransferPlan.swift b/Sources/Schemas/TransferPlan.swift index ee3a424..a392a65 100644 --- a/Sources/Schemas/TransferPlan.swift +++ b/Sources/Schemas/TransferPlan.swift @@ -1,5 +1,6 @@ import Foundation +/// Controls how a call transfer is executed, including blind and warm transfer modes, dialing and SIP behavior, hold audio, context, summary, and failure handling. public struct TransferPlan: Codable, Hashable, Sendable { /// This configures how transfer is executed and the experience of the destination party receiving the call. /// diff --git a/Sources/Schemas/TransportConfigurationTwilio.swift b/Sources/Schemas/TransportConfigurationTwilio.swift index e865043..8f31406 100644 --- a/Sources/Schemas/TransportConfigurationTwilio.swift +++ b/Sources/Schemas/TransportConfigurationTwilio.swift @@ -1,6 +1,8 @@ import Foundation +/// Configuration passed to Twilio for assistant calls, including ring timeout and Twilio recording behavior. public struct TransportConfigurationTwilio: Codable, Hashable, Sendable { + /// Selects Twilio as the call transport provider. public let provider: TransportConfigurationTwilioProvider /// The integer number of seconds that we should allow the phone to ring before assuming there is no answer. /// The default is `60` seconds and the maximum is `600` seconds. diff --git a/Sources/Schemas/TransportConfigurationTwilioProvider.swift b/Sources/Schemas/TransportConfigurationTwilioProvider.swift index 87268ae..f3990b2 100644 --- a/Sources/Schemas/TransportConfigurationTwilioProvider.swift +++ b/Sources/Schemas/TransportConfigurationTwilioProvider.swift @@ -1,5 +1,6 @@ import Foundation +/// Selects Twilio as the call transport provider. public enum TransportConfigurationTwilioProvider: String, Codable, Hashable, CaseIterable, Sendable { case twilio } \ No newline at end of file diff --git a/Sources/Schemas/TransportCost.swift b/Sources/Schemas/TransportCost.swift index e11e340..cf8da9c 100644 --- a/Sources/Schemas/TransportCost.swift +++ b/Sources/Schemas/TransportCost.swift @@ -1,6 +1,8 @@ import Foundation +/// Telephony transport cost for a call, including provider, billable minutes, and amount. public struct TransportCost: Codable, Hashable, Sendable { + /// Telephony or transport provider that generated the cost. public let provider: TransportCostProvider? /// This is the minutes of `transport` usage. This should match `call.endedAt` - `call.startedAt`. public let minutes: Double diff --git a/Sources/Schemas/TransportCostProvider.swift b/Sources/Schemas/TransportCostProvider.swift index 09da754..b988b90 100644 --- a/Sources/Schemas/TransportCostProvider.swift +++ b/Sources/Schemas/TransportCostProvider.swift @@ -1,5 +1,6 @@ import Foundation +/// Telephony or transport provider that generated the cost. public enum TransportCostProvider: String, Codable, Hashable, CaseIterable, Sendable { case daily case vapiWebsocket = "vapi.websocket" diff --git a/Sources/Schemas/TurnLatency.swift b/Sources/Schemas/TurnLatency.swift index 8d72af6..4b825ad 100644 --- a/Sources/Schemas/TurnLatency.swift +++ b/Sources/Schemas/TurnLatency.swift @@ -1,5 +1,6 @@ import Foundation +/// Model, voice, transcription, endpointing, and total latency measurements for a conversation turn. public struct TurnLatency: Codable, Hashable, Sendable { /// This is the model latency for the first token. public let modelLatency: Double? diff --git a/Sources/Schemas/TwilioPhoneNumber.swift b/Sources/Schemas/TwilioPhoneNumber.swift index dec2064..835ebf7 100644 --- a/Sources/Schemas/TwilioPhoneNumber.swift +++ b/Sources/Schemas/TwilioPhoneNumber.swift @@ -1,5 +1,6 @@ import Foundation +/// A Twilio phone number connected to Vapi, including its Twilio account details, SMS configuration, routing, hooks, server settings, and lifecycle metadata. public struct TwilioPhoneNumber: Codable, Hashable, Sendable { /// This is the fallback destination an inbound call will be transferred to if: /// 1. `assistantId` is not set diff --git a/Sources/Schemas/TwilioVoicemailDetectionPlan.swift b/Sources/Schemas/TwilioVoicemailDetectionPlan.swift index 1bec2f2..c1fc472 100644 --- a/Sources/Schemas/TwilioVoicemailDetectionPlan.swift +++ b/Sources/Schemas/TwilioVoicemailDetectionPlan.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for Twilio answering-machine detection, including recognized outcomes, enablement, timeout, speech thresholds, and silence timeout. public struct TwilioVoicemailDetectionPlan: Codable, Hashable, Sendable { /// This is the provider to use for voicemail detection. public let provider: TwilioVoicemailDetectionPlanProvider diff --git a/Sources/Schemas/UpdateApiRequestToolDto.swift b/Sources/Schemas/UpdateApiRequestToolDto.swift index ffbf372..4b7d09f 100644 --- a/Sources/Schemas/UpdateApiRequestToolDto.swift +++ b/Sources/Schemas/UpdateApiRequestToolDto.swift @@ -1,10 +1,12 @@ import Foundation +/// Fields used to update an API-request tool, including its URL, HTTP method, authentication, request data, retries, and response handling. public struct UpdateApiRequestToolDto: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// /// For some tools, this is auto-filled based on special fields like `tool.destinations`. For others like the function tool, these can be custom configured. public let messages: [UpdateApiRequestToolDtoMessagesItem]? + /// The HTTP method used for the API request. public let method: UpdateApiRequestToolDtoMethod? /// This is the timeout in seconds for the request. Defaults to 20 seconds. /// diff --git a/Sources/Schemas/UpdateApiRequestToolDtoMethod.swift b/Sources/Schemas/UpdateApiRequestToolDtoMethod.swift index f1c9897..3ebe160 100644 --- a/Sources/Schemas/UpdateApiRequestToolDtoMethod.swift +++ b/Sources/Schemas/UpdateApiRequestToolDtoMethod.swift @@ -1,5 +1,6 @@ import Foundation +/// The HTTP method used for the API request. public enum UpdateApiRequestToolDtoMethod: String, Codable, Hashable, CaseIterable, Sendable { case post = "POST" case get = "GET" diff --git a/Sources/Schemas/UpdateBarInsightFromCallTableDto.swift b/Sources/Schemas/UpdateBarInsightFromCallTableDto.swift index 636636b..9b1e24c 100644 --- a/Sources/Schemas/UpdateBarInsightFromCallTableDto.swift +++ b/Sources/Schemas/UpdateBarInsightFromCallTableDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Fields used to update a bar-chart insight, including its queries, formulas, grouping, time range, metadata, and name. public struct UpdateBarInsightFromCallTableDto: Codable, Hashable, Sendable { /// This is the name of the Insight. public let name: String? @@ -21,6 +22,7 @@ public struct UpdateBarInsightFromCallTableDto: Codable, Hashable, Sendable { public let formulas: [InsightFormula]? /// This is the metadata for the insight. public let metadata: BarInsightMetadata? + /// The time range and interval used to aggregate the bar-chart data. public let timeRange: InsightTimeRangeWithStep? /// This is the group by column for the insight when table is `call`. /// These are the columns to group the results by. diff --git a/Sources/Schemas/UpdateBashToolDto.swift b/Sources/Schemas/UpdateBashToolDto.swift index fafeeba..1dcc7d5 100644 --- a/Sources/Schemas/UpdateBashToolDto.swift +++ b/Sources/Schemas/UpdateBashToolDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Fields used to update a Bash tool, including its name, environment subtype, server, messages, and rejection plan. public struct UpdateBashToolDto: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/UpdateByoPhoneNumberDto.swift b/Sources/Schemas/UpdateByoPhoneNumberDto.swift index 324bb51..3fcb936 100644 --- a/Sources/Schemas/UpdateByoPhoneNumberDto.swift +++ b/Sources/Schemas/UpdateByoPhoneNumberDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Fields used to update a bring-your-own phone number, including its credential, number, routing, hooks, and server settings. public struct UpdateByoPhoneNumberDto: Codable, Hashable, Sendable { /// This is the fallback destination an inbound call will be transferred to if: /// 1. `assistantId` is not set diff --git a/Sources/Schemas/UpdateComputerToolDto.swift b/Sources/Schemas/UpdateComputerToolDto.swift index 7ba4621..c0b8f6e 100644 --- a/Sources/Schemas/UpdateComputerToolDto.swift +++ b/Sources/Schemas/UpdateComputerToolDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Fields used to update a computer tool, including its display settings, environment subtype, server, messages, and rejection plan. public struct UpdateComputerToolDto: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/UpdateDtmfToolDto.swift b/Sources/Schemas/UpdateDtmfToolDto.swift index 8798a2a..b45c51b 100644 --- a/Sources/Schemas/UpdateDtmfToolDto.swift +++ b/Sources/Schemas/UpdateDtmfToolDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Fields used to update a DTMF tool, including its spoken messages, rejection plan, and SIP INFO behavior. public struct UpdateDtmfToolDto: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/UpdateEndCallToolDto.swift b/Sources/Schemas/UpdateEndCallToolDto.swift index a8bbdf2..ca33f46 100644 --- a/Sources/Schemas/UpdateEndCallToolDto.swift +++ b/Sources/Schemas/UpdateEndCallToolDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Fields used to update an end-call tool, including its spoken messages and rejection plan. public struct UpdateEndCallToolDto: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/UpdateFunctionToolDto.swift b/Sources/Schemas/UpdateFunctionToolDto.swift index 039a5ae..2220732 100644 --- a/Sources/Schemas/UpdateFunctionToolDto.swift +++ b/Sources/Schemas/UpdateFunctionToolDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Fields used to update a custom function tool, including its function definition, server, parameters, messages, and execution behavior. public struct UpdateFunctionToolDto: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/UpdateGoHighLevelCalendarAvailabilityToolDto.swift b/Sources/Schemas/UpdateGoHighLevelCalendarAvailabilityToolDto.swift index 5db191c..6a9955d 100644 --- a/Sources/Schemas/UpdateGoHighLevelCalendarAvailabilityToolDto.swift +++ b/Sources/Schemas/UpdateGoHighLevelCalendarAvailabilityToolDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Fields used to update a GoHighLevel calendar-availability tool, including its spoken messages and rejection plan. public struct UpdateGoHighLevelCalendarAvailabilityToolDto: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/UpdateGoHighLevelCalendarEventCreateToolDto.swift b/Sources/Schemas/UpdateGoHighLevelCalendarEventCreateToolDto.swift index 5003b66..2b5ad53 100644 --- a/Sources/Schemas/UpdateGoHighLevelCalendarEventCreateToolDto.swift +++ b/Sources/Schemas/UpdateGoHighLevelCalendarEventCreateToolDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Fields used to update a GoHighLevel calendar-event tool, including its spoken messages and rejection plan. public struct UpdateGoHighLevelCalendarEventCreateToolDto: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/UpdateGoHighLevelContactCreateToolDto.swift b/Sources/Schemas/UpdateGoHighLevelContactCreateToolDto.swift index 940f882..d2f0789 100644 --- a/Sources/Schemas/UpdateGoHighLevelContactCreateToolDto.swift +++ b/Sources/Schemas/UpdateGoHighLevelContactCreateToolDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Fields used to update a GoHighLevel contact-creation tool, including its spoken messages and rejection plan. public struct UpdateGoHighLevelContactCreateToolDto: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/UpdateGoHighLevelContactGetToolDto.swift b/Sources/Schemas/UpdateGoHighLevelContactGetToolDto.swift index 654a321..8b734b9 100644 --- a/Sources/Schemas/UpdateGoHighLevelContactGetToolDto.swift +++ b/Sources/Schemas/UpdateGoHighLevelContactGetToolDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Fields used to update a GoHighLevel contact-retrieval tool, including its spoken messages and rejection plan. public struct UpdateGoHighLevelContactGetToolDto: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/UpdateGoogleCalendarCheckAvailabilityToolDto.swift b/Sources/Schemas/UpdateGoogleCalendarCheckAvailabilityToolDto.swift index d4ec10f..b21b9bf 100644 --- a/Sources/Schemas/UpdateGoogleCalendarCheckAvailabilityToolDto.swift +++ b/Sources/Schemas/UpdateGoogleCalendarCheckAvailabilityToolDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Fields used to update a Google Calendar availability tool, including its spoken messages and rejection plan. public struct UpdateGoogleCalendarCheckAvailabilityToolDto: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/UpdateGoogleCalendarCreateEventToolDto.swift b/Sources/Schemas/UpdateGoogleCalendarCreateEventToolDto.swift index 478bdba..44e8cea 100644 --- a/Sources/Schemas/UpdateGoogleCalendarCreateEventToolDto.swift +++ b/Sources/Schemas/UpdateGoogleCalendarCreateEventToolDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Fields used to update a Google Calendar event-creation tool, including its spoken messages and rejection plan. public struct UpdateGoogleCalendarCreateEventToolDto: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/UpdateGoogleSheetsRowAppendToolDto.swift b/Sources/Schemas/UpdateGoogleSheetsRowAppendToolDto.swift index 37059c7..be21e6b 100644 --- a/Sources/Schemas/UpdateGoogleSheetsRowAppendToolDto.swift +++ b/Sources/Schemas/UpdateGoogleSheetsRowAppendToolDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Fields used to update a Google Sheets row-append tool, including its spoken messages and rejection plan. public struct UpdateGoogleSheetsRowAppendToolDto: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/UpdateHandoffToolDto.swift b/Sources/Schemas/UpdateHandoffToolDto.swift index fa1d54a..4150155 100644 --- a/Sources/Schemas/UpdateHandoffToolDto.swift +++ b/Sources/Schemas/UpdateHandoffToolDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Fields used to update a handoff tool, including its destinations, function definition, default result, messages, and rejection plan. public struct UpdateHandoffToolDto: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/UpdateLineInsightFromCallTableDto.swift b/Sources/Schemas/UpdateLineInsightFromCallTableDto.swift index 112e116..e08d699 100644 --- a/Sources/Schemas/UpdateLineInsightFromCallTableDto.swift +++ b/Sources/Schemas/UpdateLineInsightFromCallTableDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Fields used to update a line-chart insight, including its queries, formulas, grouping, time range, metadata, and name. public struct UpdateLineInsightFromCallTableDto: Codable, Hashable, Sendable { /// This is the name of the Insight. public let name: String? @@ -21,6 +22,7 @@ public struct UpdateLineInsightFromCallTableDto: Codable, Hashable, Sendable { public let formulas: [InsightFormula]? /// This is the metadata for the insight. public let metadata: LineInsightMetadata? + /// The time range and interval used to aggregate the line-chart data. public let timeRange: InsightTimeRangeWithStep? /// This is the group by column for the insight when table is `call`. /// These are the columns to group the results by. diff --git a/Sources/Schemas/UpdateMcpToolDto.swift b/Sources/Schemas/UpdateMcpToolDto.swift index af31e55..5f5d908 100644 --- a/Sources/Schemas/UpdateMcpToolDto.swift +++ b/Sources/Schemas/UpdateMcpToolDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Fields used to update an MCP tool, including its server, connection metadata, exposed tool messages, and rejection plan. public struct UpdateMcpToolDto: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// @@ -96,6 +97,7 @@ public struct UpdateMcpToolDto: Codable, Hashable, Sendable { /// } /// ``` public let rejectionPlan: ToolRejectionPlan? + /// Connection metadata for the MCP server, including its communication protocol. public let metadata: McpToolMetadata? /// Additional properties that are not explicitly defined in the schema public let additionalProperties: [String: JSONValue] diff --git a/Sources/Schemas/UpdatePieInsightFromCallTableDto.swift b/Sources/Schemas/UpdatePieInsightFromCallTableDto.swift index a767437..becd996 100644 --- a/Sources/Schemas/UpdatePieInsightFromCallTableDto.swift +++ b/Sources/Schemas/UpdatePieInsightFromCallTableDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Fields used to update a pie-chart insight, including its queries, formulas, grouping, time range, and name. public struct UpdatePieInsightFromCallTableDto: Codable, Hashable, Sendable { /// This is the name of the Insight. public let name: String? @@ -19,6 +20,7 @@ public struct UpdatePieInsightFromCallTableDto: Codable, Hashable, Sendable { /// /// You can also use the query names as the variable in the formula. public let formulas: [InsightFormula]? + /// The time range used to query the pie-chart data. public let timeRange: InsightTimeRange? /// This is the group by column for the insight when table is `call`. /// These are the columns to group the results by. diff --git a/Sources/Schemas/UpdateQueryToolDto.swift b/Sources/Schemas/UpdateQueryToolDto.swift index efe8c0d..ce8899b 100644 --- a/Sources/Schemas/UpdateQueryToolDto.swift +++ b/Sources/Schemas/UpdateQueryToolDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Fields used to update a query tool, including its knowledge bases, spoken messages, and rejection plan. public struct UpdateQueryToolDto: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/UpdateSipRequestToolDto.swift b/Sources/Schemas/UpdateSipRequestToolDto.swift index c150e2d..16b1ee1 100644 --- a/Sources/Schemas/UpdateSipRequestToolDto.swift +++ b/Sources/Schemas/UpdateSipRequestToolDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Fields used to update a SIP-request tool, including its method, headers, body, spoken messages, and rejection plan. public struct UpdateSipRequestToolDto: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/UpdateSlackSendMessageToolDto.swift b/Sources/Schemas/UpdateSlackSendMessageToolDto.swift index d0913d9..5e2d318 100644 --- a/Sources/Schemas/UpdateSlackSendMessageToolDto.swift +++ b/Sources/Schemas/UpdateSlackSendMessageToolDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Fields used to update a Slack message tool, including its spoken messages and rejection plan. public struct UpdateSlackSendMessageToolDto: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/UpdateSmsToolDto.swift b/Sources/Schemas/UpdateSmsToolDto.swift index edef672..436655f 100644 --- a/Sources/Schemas/UpdateSmsToolDto.swift +++ b/Sources/Schemas/UpdateSmsToolDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Fields used to update an SMS tool, including its spoken messages and rejection plan. public struct UpdateSmsToolDto: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/UpdateTelnyxPhoneNumberDto.swift b/Sources/Schemas/UpdateTelnyxPhoneNumberDto.swift index 9c9f901..8fe3de1 100644 --- a/Sources/Schemas/UpdateTelnyxPhoneNumberDto.swift +++ b/Sources/Schemas/UpdateTelnyxPhoneNumberDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Fields used to update a Telnyx phone number, including its credential, number, routing, hooks, and server settings. public struct UpdateTelnyxPhoneNumberDto: Codable, Hashable, Sendable { /// This is the fallback destination an inbound call will be transferred to if: /// 1. `assistantId` is not set diff --git a/Sources/Schemas/UpdateTextEditorToolDto.swift b/Sources/Schemas/UpdateTextEditorToolDto.swift index 4474ce5..e6b3b7b 100644 --- a/Sources/Schemas/UpdateTextEditorToolDto.swift +++ b/Sources/Schemas/UpdateTextEditorToolDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Fields used to update a text-editor tool, including its name, environment subtype, server, messages, and rejection plan. public struct UpdateTextEditorToolDto: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/UpdateTextInsightFromCallTableDto.swift b/Sources/Schemas/UpdateTextInsightFromCallTableDto.swift index 6ff269d..483d9f4 100644 --- a/Sources/Schemas/UpdateTextInsightFromCallTableDto.swift +++ b/Sources/Schemas/UpdateTextInsightFromCallTableDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Fields used to update a text-value insight, including its queries, formula, time range, and name. public struct UpdateTextInsightFromCallTableDto: Codable, Hashable, Sendable { /// This is the name of the Insight. public let name: String? @@ -19,6 +20,7 @@ public struct UpdateTextInsightFromCallTableDto: Codable, Hashable, Sendable { /// /// You can also use the query names as the variable in the formula. public let formula: [String: JSONValue]? + /// The time range used to query the text-value data. public let timeRange: InsightTimeRange? /// These are the queries to run to generate the insight. /// For Text Insights, we only allow a single query, or require a formula if multiple queries are provided diff --git a/Sources/Schemas/UpdateTransferCallToolDto.swift b/Sources/Schemas/UpdateTransferCallToolDto.swift index 25007b5..0bb4a28 100644 --- a/Sources/Schemas/UpdateTransferCallToolDto.swift +++ b/Sources/Schemas/UpdateTransferCallToolDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Fields used to update a call-transfer tool, including its destinations, spoken messages, and rejection plan. public struct UpdateTransferCallToolDto: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/UpdateTwilioPhoneNumberDto.swift b/Sources/Schemas/UpdateTwilioPhoneNumberDto.swift index a833b79..d4bcae5 100644 --- a/Sources/Schemas/UpdateTwilioPhoneNumberDto.swift +++ b/Sources/Schemas/UpdateTwilioPhoneNumberDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Fields used to update a Twilio phone number, including its account credentials, SMS configuration, routing, hooks, and server settings. public struct UpdateTwilioPhoneNumberDto: Codable, Hashable, Sendable { /// This is the fallback destination an inbound call will be transferred to if: /// 1. `assistantId` is not set diff --git a/Sources/Schemas/UpdateVapiPhoneNumberDto.swift b/Sources/Schemas/UpdateVapiPhoneNumberDto.swift index c2c4fd6..73e711b 100644 --- a/Sources/Schemas/UpdateVapiPhoneNumberDto.swift +++ b/Sources/Schemas/UpdateVapiPhoneNumberDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Fields used to update a Vapi-managed phone number or SIP URI, including its authentication, routing, hooks, and server settings. public struct UpdateVapiPhoneNumberDto: Codable, Hashable, Sendable { /// This is the fallback destination an inbound call will be transferred to if: /// 1. `assistantId` is not set diff --git a/Sources/Schemas/UpdateVoicemailToolDto.swift b/Sources/Schemas/UpdateVoicemailToolDto.swift index c9cfca4..924d312 100644 --- a/Sources/Schemas/UpdateVoicemailToolDto.swift +++ b/Sources/Schemas/UpdateVoicemailToolDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Fields used to update a voicemail-detection tool, including beep detection, spoken messages, and rejection plan. public struct UpdateVoicemailToolDto: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/UpdateVonagePhoneNumberDto.swift b/Sources/Schemas/UpdateVonagePhoneNumberDto.swift index f7cfa8e..aa0c8ec 100644 --- a/Sources/Schemas/UpdateVonagePhoneNumberDto.swift +++ b/Sources/Schemas/UpdateVonagePhoneNumberDto.swift @@ -1,5 +1,6 @@ import Foundation +/// Fields used to update a Vonage phone number, including its credential, number, routing, hooks, and server settings. public struct UpdateVonagePhoneNumberDto: Codable, Hashable, Sendable { /// This is the fallback destination an inbound call will be transferred to if: /// 1. `assistantId` is not set diff --git a/Sources/Schemas/UserMessage.swift b/Sources/Schemas/UserMessage.swift index f2fd6d1..77a56ba 100644 --- a/Sources/Schemas/UserMessage.swift +++ b/Sources/Schemas/UserMessage.swift @@ -1,5 +1,6 @@ import Foundation +/// A user-authored entry in the call message history, including content, timing, security-filter results, and optional speaker metadata. public struct UserMessage: Codable, Hashable, Sendable { /// The role of the user in the conversation. public let role: String diff --git a/Sources/Schemas/VapiCost.swift b/Sources/Schemas/VapiCost.swift index b0b3a4a..6886070 100644 --- a/Sources/Schemas/VapiCost.swift +++ b/Sources/Schemas/VapiCost.swift @@ -1,5 +1,6 @@ import Foundation +/// Vapi platform cost for a call, including cost subtype, billable minutes, and amount. public struct VapiCost: Codable, Hashable, Sendable { /// This is the sub type of the cost. public let subType: VapiCostSubType diff --git a/Sources/Schemas/VapiPhoneNumber.swift b/Sources/Schemas/VapiPhoneNumber.swift index 78567ea..78568d8 100644 --- a/Sources/Schemas/VapiPhoneNumber.swift +++ b/Sources/Schemas/VapiPhoneNumber.swift @@ -1,5 +1,6 @@ import Foundation +/// A Vapi-managed phone number or SIP URI, including its authentication, routing, hooks, server settings, and lifecycle metadata. public struct VapiPhoneNumber: Codable, Hashable, Sendable { /// This is the fallback destination an inbound call will be transferred to if: /// 1. `assistantId` is not set diff --git a/Sources/Schemas/VapiPronunciationDictionaryLocator.swift b/Sources/Schemas/VapiPronunciationDictionaryLocator.swift index 09bc4c6..ccf0203 100644 --- a/Sources/Schemas/VapiPronunciationDictionaryLocator.swift +++ b/Sources/Schemas/VapiPronunciationDictionaryLocator.swift @@ -1,5 +1,6 @@ import Foundation +/// Identifies a pronunciation dictionary and optional version used for voice synthesis. public struct VapiPronunciationDictionaryLocator: Codable, Hashable, Sendable { /// The pronunciation dictionary ID public let pronunciationDictId: String diff --git a/Sources/Schemas/VapiSmartEndpointingPlan.swift b/Sources/Schemas/VapiSmartEndpointingPlan.swift index 64a3c30..b4e39c4 100644 --- a/Sources/Schemas/VapiSmartEndpointingPlan.swift +++ b/Sources/Schemas/VapiSmartEndpointingPlan.swift @@ -1,5 +1,6 @@ import Foundation +/// Selects Vapi smart endpointing to determine when customer speech is complete. public struct VapiSmartEndpointingPlan: Codable, Hashable, Sendable { /// This is the provider for the smart endpointing plan. public let provider: VapiSmartEndpointingPlanProvider diff --git a/Sources/Schemas/VapiVoice.swift b/Sources/Schemas/VapiVoice.swift index 38b2c85..cad658a 100644 --- a/Sources/Schemas/VapiVoice.swift +++ b/Sources/Schemas/VapiVoice.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for synthesizing assistant speech with Vapi, including voice selection, speed, pronunciation dictionary, chunking, caching, and fallback settings. public struct VapiVoice: Codable, Hashable, Sendable { /// This is the flag to toggle voice caching for the assistant. public let cachingEnabled: Bool? diff --git a/Sources/Schemas/VapiVoicemailDetectionPlan.swift b/Sources/Schemas/VapiVoicemailDetectionPlan.swift index be40955..6454c46 100644 --- a/Sources/Schemas/VapiVoicemailDetectionPlan.swift +++ b/Sources/Schemas/VapiVoicemailDetectionPlan.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for detecting voicemail with Vapi, including detection type, maximum beep wait, and retry backoff. public struct VapiVoicemailDetectionPlan: Codable, Hashable, Sendable { /// This is the maximum duration from the start of the call that we will wait for a voicemail beep, before speaking our message /// diff --git a/Sources/Schemas/VariableExtractionAlias.swift b/Sources/Schemas/VariableExtractionAlias.swift index d6a0944..a60d17b 100644 --- a/Sources/Schemas/VariableExtractionAlias.swift +++ b/Sources/Schemas/VariableExtractionAlias.swift @@ -1,5 +1,6 @@ import Foundation +/// Defines an additional Liquid-based variable from values extracted during a call. public struct VariableExtractionAlias: Codable, Hashable, Sendable { /// This is the key of the variable. /// diff --git a/Sources/Schemas/VariableExtractionPlan.swift b/Sources/Schemas/VariableExtractionPlan.swift index d972a28..0ec29a7 100644 --- a/Sources/Schemas/VariableExtractionPlan.swift +++ b/Sources/Schemas/VariableExtractionPlan.swift @@ -1,5 +1,6 @@ import Foundation +/// Defines structured variables to extract and optional aliases made available during and after a call. public struct VariableExtractionPlan: Codable, Hashable, Sendable { /// This is the schema to extract. /// diff --git a/Sources/Schemas/VariableValueGroupBy.swift b/Sources/Schemas/VariableValueGroupBy.swift index ba760dd..7c495ee 100644 --- a/Sources/Schemas/VariableValueGroupBy.swift +++ b/Sources/Schemas/VariableValueGroupBy.swift @@ -1,5 +1,6 @@ import Foundation +/// Groups analytics results by a selected assistant variable-value key. public struct VariableValueGroupBy: Codable, Hashable, Sendable { /// This is the key of the variable value to group by. public let key: String diff --git a/Sources/Schemas/VoiceCost.swift b/Sources/Schemas/VoiceCost.swift index f76c2a6..213b01a 100644 --- a/Sources/Schemas/VoiceCost.swift +++ b/Sources/Schemas/VoiceCost.swift @@ -1,5 +1,6 @@ import Foundation +/// Voice-synthesis cost for a call, including voice, character usage, and amount. public struct VoiceCost: Codable, Hashable, Sendable { /// This is the voice that was used during the call. /// diff --git a/Sources/Schemas/VoicemailDetectionBackoffPlan.swift b/Sources/Schemas/VoicemailDetectionBackoffPlan.swift index 2542abc..792ece4 100644 --- a/Sources/Schemas/VoicemailDetectionBackoffPlan.swift +++ b/Sources/Schemas/VoicemailDetectionBackoffPlan.swift @@ -1,5 +1,6 @@ import Foundation +/// Controls voicemail-detection retry timing, including when retries start, retry frequency, and maximum attempts. public struct VoicemailDetectionBackoffPlan: Codable, Hashable, Sendable { /// This is the number of seconds to wait before starting the first retry attempt. public let startAtSeconds: Double? diff --git a/Sources/Schemas/VoicemailDetectionCost.swift b/Sources/Schemas/VoicemailDetectionCost.swift index 11d6c10..4483dea 100644 --- a/Sources/Schemas/VoicemailDetectionCost.swift +++ b/Sources/Schemas/VoicemailDetectionCost.swift @@ -1,5 +1,6 @@ import Foundation +/// Voicemail-detection model cost, including provider, model, multimodal token usage, and amount. public struct VoicemailDetectionCost: Codable, Hashable, Sendable { /// This is the model that was used to perform the analysis. public let model: [String: JSONValue] diff --git a/Sources/Schemas/VoicemailTool.swift b/Sources/Schemas/VoicemailTool.swift index 1ea83b3..0d20873 100644 --- a/Sources/Schemas/VoicemailTool.swift +++ b/Sources/Schemas/VoicemailTool.swift @@ -1,5 +1,6 @@ import Foundation +/// A reusable voicemail-detection tool with optional beep detection for supported calls. public struct VoicemailTool: Codable, Hashable, Sendable { /// These are the messages that will be spoken to the user as the tool is running. /// diff --git a/Sources/Schemas/VonagePhoneNumber.swift b/Sources/Schemas/VonagePhoneNumber.swift index e40cb3d..5fc22b4 100644 --- a/Sources/Schemas/VonagePhoneNumber.swift +++ b/Sources/Schemas/VonagePhoneNumber.swift @@ -1,5 +1,6 @@ import Foundation +/// A Vonage phone number connected to Vapi, including its credential, routing, hooks, server settings, and lifecycle metadata. public struct VonagePhoneNumber: Codable, Hashable, Sendable { /// This is the fallback destination an inbound call will be transferred to if: /// 1. `assistantId` is not set diff --git a/Sources/Schemas/WellSaidVoice.swift b/Sources/Schemas/WellSaidVoice.swift index dd9ade5..6f27150 100644 --- a/Sources/Schemas/WellSaidVoice.swift +++ b/Sources/Schemas/WellSaidVoice.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for synthesizing assistant speech with WellSaid, including voice and model selection, Speech Synthesis Markup Language support, voice libraries, chunking, caching, and fallback settings. public struct WellSaidVoice: Codable, Hashable, Sendable { /// This is the flag to toggle voice caching for the assistant. public let cachingEnabled: Bool? diff --git a/Sources/Schemas/WorkflowAnthropicBedrockModel.swift b/Sources/Schemas/WorkflowAnthropicBedrockModel.swift index 0bc28f3..680af90 100644 --- a/Sources/Schemas/WorkflowAnthropicBedrockModel.swift +++ b/Sources/Schemas/WorkflowAnthropicBedrockModel.swift @@ -1,5 +1,6 @@ import Foundation +/// Workflow model configuration for Anthropic through Amazon Bedrock, including model selection, thinking, temperature, and maximum output tokens. public struct WorkflowAnthropicBedrockModel: Codable, Hashable, Sendable { /// This is the specific model that will be used. public let model: WorkflowAnthropicBedrockModelModel diff --git a/Sources/Schemas/WorkflowAnthropicModel.swift b/Sources/Schemas/WorkflowAnthropicModel.swift index e84463c..5077d3b 100644 --- a/Sources/Schemas/WorkflowAnthropicModel.swift +++ b/Sources/Schemas/WorkflowAnthropicModel.swift @@ -1,5 +1,6 @@ import Foundation +/// Workflow model configuration for Anthropic, including model selection, thinking, temperature, and maximum output tokens. public struct WorkflowAnthropicModel: Codable, Hashable, Sendable { /// This is the specific model that will be used. public let model: WorkflowAnthropicModelModel diff --git a/Sources/Schemas/WorkflowCustomModel.swift b/Sources/Schemas/WorkflowCustomModel.swift index 0228bd8..ffa4110 100644 --- a/Sources/Schemas/WorkflowCustomModel.swift +++ b/Sources/Schemas/WorkflowCustomModel.swift @@ -1,5 +1,6 @@ import Foundation +/// Workflow model configuration for a custom language model endpoint, including URL, headers, metadata delivery, timeout, model, temperature, and maximum output tokens. public struct WorkflowCustomModel: Codable, Hashable, Sendable { /// This determines whether metadata is sent in requests to the custom provider. /// diff --git a/Sources/Schemas/WorkflowGoogleModel.swift b/Sources/Schemas/WorkflowGoogleModel.swift index ec87739..f753d32 100644 --- a/Sources/Schemas/WorkflowGoogleModel.swift +++ b/Sources/Schemas/WorkflowGoogleModel.swift @@ -1,5 +1,6 @@ import Foundation +/// Workflow model configuration for Google, including model selection, temperature, and maximum output tokens. public struct WorkflowGoogleModel: Codable, Hashable, Sendable { /// This is the name of the model. Ex. cognitivecomputations/dolphin-mixtral-8x7b public let model: WorkflowGoogleModelModel diff --git a/Sources/Schemas/WorkflowOpenAiModel.swift b/Sources/Schemas/WorkflowOpenAiModel.swift index bc924a7..9428e32 100644 --- a/Sources/Schemas/WorkflowOpenAiModel.swift +++ b/Sources/Schemas/WorkflowOpenAiModel.swift @@ -1,5 +1,6 @@ import Foundation +/// Workflow model configuration for OpenAI, including model selection, temperature, and maximum output tokens. public struct WorkflowOpenAiModel: Codable, Hashable, Sendable { /// This is the OpenAI model that will be used. /// diff --git a/Sources/Schemas/WorkflowOverrides.swift b/Sources/Schemas/WorkflowOverrides.swift index 798244d..149afbd 100644 --- a/Sources/Schemas/WorkflowOverrides.swift +++ b/Sources/Schemas/WorkflowOverrides.swift @@ -1,5 +1,6 @@ import Foundation +/// Per-call overrides for values used in workflow template variables. public struct WorkflowOverrides: Codable, Hashable, Sendable { /// These are values that will be used to replace the template variables in the workflow messages and other text-based fields. /// This uses LiquidJS syntax. https://liquidjs.com/tutorials/intro-to-liquid.html diff --git a/Sources/Schemas/XaiModel.swift b/Sources/Schemas/XaiModel.swift index f354653..f596eed 100644 --- a/Sources/Schemas/XaiModel.swift +++ b/Sources/Schemas/XaiModel.swift @@ -1,5 +1,6 @@ import Foundation +/// Configuration for generating assistant responses with xAI, including model, prompts, tools, knowledge-base access, and generation settings. public struct XaiModel: Codable, Hashable, Sendable { /// This is the starting state for the conversation. public let messages: [OpenAiMessage]? diff --git a/Sources/Schemas/XssSecurityFilter.swift b/Sources/Schemas/XssSecurityFilter.swift index fce6ecd..2ffaa26 100644 --- a/Sources/Schemas/XssSecurityFilter.swift +++ b/Sources/Schemas/XssSecurityFilter.swift @@ -1,5 +1,6 @@ import Foundation +/// Filters potential cross-site scripting (XSS) patterns from transcripts. public struct XssSecurityFilter: Codable, Hashable, Sendable { /// The type of security threat to filter. public let type: XssSecurityFilterType diff --git a/Sources/Version.swift b/Sources/Version.swift index 1b834a4..980ac07 100644 --- a/Sources/Version.swift +++ b/Sources/Version.swift @@ -1 +1 @@ -public let sdkVersion = "1.0.0" +public let sdkVersion = "1.0.1" diff --git a/changelog.md b/changelog.md index 47b003e..8c283e6 100644 --- a/changelog.md +++ b/changelog.md @@ -1,3 +1,5 @@ +## [1.0.1] - 2026-07-28 + ## 1.0.0 - 2026-06-24 ### Breaking Changes * **`CartesiaExperimentalControlsSpeedZero`** has been removed and replaced by **`CartesiaSpeedControlZero`**. Update any references to this type and rename pattern matches on `CartesiaSpeedControl.cartesiaExperimentalControlsSpeedZero` to `.cartesiaSpeedControlZero`.