@talqing/sdk 0.4.1 → 0.4.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/gen/index.d.ts +1 -1
- package/dist/cjs/gen/index.d.ts.map +1 -1
- package/dist/cjs/gen/sdk.gen.d.ts +231 -154
- package/dist/cjs/gen/sdk.gen.d.ts.map +1 -1
- package/dist/cjs/gen/sdk.gen.js +401 -243
- package/dist/cjs/gen/sdk.gen.js.map +1 -1
- package/dist/cjs/gen/types.gen.d.ts +688 -24
- package/dist/cjs/gen/types.gen.d.ts.map +1 -1
- package/dist/cjs/vocabulary.d.ts +5 -1
- package/dist/cjs/vocabulary.d.ts.map +1 -1
- package/dist/esm/gen/index.d.ts +1 -1
- package/dist/esm/gen/index.d.ts.map +1 -1
- package/dist/esm/gen/sdk.gen.d.ts +231 -154
- package/dist/esm/gen/sdk.gen.d.ts.map +1 -1
- package/dist/esm/gen/sdk.gen.js +397 -242
- package/dist/esm/gen/sdk.gen.js.map +1 -1
- package/dist/esm/gen/types.gen.d.ts +688 -24
- package/dist/esm/gen/types.gen.d.ts.map +1 -1
- package/dist/esm/vocabulary.d.ts +5 -1
- package/dist/esm/vocabulary.d.ts.map +1 -1
- package/package.json +1 -1
- package/src/gen/index.ts +1 -1
- package/src/gen/sdk.gen.ts +574 -393
- package/src/gen/types.gen.ts +730 -24
- package/src/vocabulary.ts +5 -0
package/src/gen/sdk.gen.ts
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
import { client } from './client.gen.js';
|
|
4
4
|
import { buildClientParams, type Client, type ClientMeta, type Options as Options2, type RequestResult, type ServerSentEventsResult, type TDataShape } from './client/index.js';
|
|
5
|
-
import type { AddRecipientsRequest, AddVoiceRequest, AgentsCreateErrors, AgentsCreateResults, AgentsDeleteErrors, AgentsDeleteResults, AgentsGetErrors, AgentsGetResults, AgentsListErrors, AgentsListResults, AgentsPublishErrors, AgentsPublishResults, AgentsUpdateErrors, AgentsUpdateResults, AgentsValidateErrors, AgentsValidateResults, AgentsVersionsGetErrors, AgentsVersionsGetResults, AgentsVersionsRollbackErrors, AgentsVersionsRollbackResults, AssignPhoneNumberRequest, BackfillAnalysisRequest, BillingCreditsCheckoutErrors, BillingCreditsCheckoutResults, BillingCreditsGetErrors, BillingCreditsGetResults, BillingCreditsLedgerErrors, BillingCreditsLedgerResults, BuildKBRequest, CallsAnalysisBackfillErrors, CallsAnalysisBackfillResults, CallsAnalysisPreviewErrors, CallsAnalysisPreviewResults, CallsBatchesCancelErrors, CallsBatchesCancelResults, CallsBatchesCreateErrors, CallsBatchesCreateResults, CallsBatchesGetErrors, CallsBatchesGetResults, CallsBatchesListErrors, CallsBatchesListResults, CallsBatchesPauseErrors, CallsBatchesPauseResults, CallsBatchesRecipientsAddErrors, CallsBatchesRecipientsAddResults, CallsBatchesRecipientsListErrors, CallsBatchesRecipientsListResults, CallsBatchesResumeErrors, CallsBatchesResumeResults, CallsBatchesUpdateErrors, CallsBatchesUpdateResults, CallsDeleteErrors, CallsDeleteResults, CallsGetErrors, CallsGetResults, CallsListErrors, CallsListResults, CallsOutboundErrors, CallsOutboundResults, CallsRecordingDeleteErrors, CallsRecordingDeleteResults, CallsRecordingGetErrors, CallsRecordingGetResults, CallsScreenRecordingGetErrors, CallsScreenRecordingGetResults, CallsStatsErrors, CallsStatsResults, CallsTokenErrors, CallsTokenResults, CatalogAvatarsListErrors, CatalogAvatarsListResults, CatalogGetErrors, CatalogGetResults, CatalogVoicesElevenlabsAddErrors, CatalogVoicesElevenlabsAddResults, CatalogVoicesElevenlabsSettingsErrors, CatalogVoicesElevenlabsSettingsResults, CatalogVoicesListErrors, CatalogVoicesListResults, ConversationsCreateErrors, ConversationsCreateResults, ConversationsEventsErrors, ConversationsEventsResult, ConversationsEventsResults, ConversationsGetErrors, ConversationsGetResults, ConversationsItemsListErrors, ConversationsItemsListResults, ConversationsListErrors, ConversationsListResults, ConversationsMessagesCreateErrors, ConversationsMessagesCreateResults, ConversationsSessionsListErrors, ConversationsSessionsListResults, ConversationsSnapshotErrors, ConversationsSnapshotResults, ConversationsUpdateErrors, ConversationsUpdateResults, CopilotAgentsSendErrors, CopilotAgentsSendResults, CopilotAgentsStreamErrors, CopilotAgentsStreamResult, CopilotAgentsStreamResults, CopilotKnowledgeSendErrors, CopilotKnowledgeSendResults, CopilotKnowledgeStreamErrors, CopilotKnowledgeStreamResult, CopilotKnowledgeStreamResults, CopilotTasksSendErrors, CopilotTasksSendResults, CopilotTasksStreamErrors, CopilotTasksStreamResult, CopilotTasksStreamResults, CopilotToolsSendErrors, CopilotToolsSendResults, CopilotToolsStreamErrors, CopilotToolsStreamResult, CopilotToolsStreamResults, CreateAgentRequest, CreateCallBatchRequest, CreateEmailBatchRequest, CreateEmailSendRequest, CreateIntegrationRequest, CreateIntegrationTriggerRequest, CreateKBRequest, CreateSecretRequest, CreateTaskRequest, CreateTelephonyAccountRequest, CreateTextConversationRequest, CreateToolRequest, CreateWebhookRequest, CreditCheckoutRequest, EmailBatchesCancelErrors, EmailBatchesCancelResults, EmailBatchesCreateErrors, EmailBatchesCreateResults, EmailBatchesGetErrors, EmailBatchesGetResults, EmailBatchesListErrors, EmailBatchesListResults, EmailBatchesPauseErrors, EmailBatchesPauseResults, EmailBatchesRecipientsListErrors, EmailBatchesRecipientsListResults, EmailBatchesRecipientsRedraftErrors, EmailBatchesRecipientsRedraftResults, EmailBatchesRecipientsRestoreErrors, EmailBatchesRecipientsRestoreResults, EmailBatchesRecipientsSkipErrors, EmailBatchesRecipientsSkipResults, EmailBatchesRecipientsUpdateErrors, EmailBatchesRecipientsUpdateResults, EmailBatchesResumeErrors, EmailBatchesResumeResults, EmailBatchesSendsCancelErrors, EmailBatchesSendsCancelResults, EmailBatchesSendsCreateErrors, EmailBatchesSendsCreateResults, EmailBatchesSendsGetErrors, EmailBatchesSendsGetResults, EmailBatchesSendsListErrors, EmailBatchesSendsListResults, EmailBatchesSendsPauseErrors, EmailBatchesSendsPauseResults, EmailBatchesSendsResumeErrors, EmailBatchesSendsResumeResults, EmailBatchesSendsUpdateErrors, EmailBatchesSendsUpdateResults, EmailBatchesUpdateErrors, EmailBatchesUpdateResults, EmailSendersListErrors, EmailSendersListResults, HealthErrors, HealthResults, ImportPhoneNumbersRequest, IntegrationsCatalogErrors, IntegrationsCatalogResults, IntegrationsCreateErrors, IntegrationsCreateResults, IntegrationsDeleteErrors, IntegrationsDeleteResults, IntegrationsGetErrors, IntegrationsGetResults, IntegrationsListErrors, IntegrationsListResults, IntegrationsMcpToolsListErrors, IntegrationsMcpToolsListResults, IntegrationsTriggersCreateErrors, IntegrationsTriggersCreateResults, IntegrationsTriggersDeleteErrors, IntegrationsTriggersDeleteResults, IntegrationsTriggersListErrors, IntegrationsTriggersListResults, IntegrationsTriggersUpdateErrors, IntegrationsTriggersUpdateResults, IntegrationsUpdateErrors, IntegrationsUpdateResults, KnowledgeBuildErrors, KnowledgeBuildResults, KnowledgeCreateErrors, KnowledgeCreateResults, KnowledgeDeleteErrors, KnowledgeDeleteResults, KnowledgeEventsErrors, KnowledgeEventsResult, KnowledgeEventsResults, KnowledgeGetErrors, KnowledgeGetResults, KnowledgeListErrors, KnowledgeListResults, KnowledgeNodesDeleteErrors, KnowledgeNodesDeleteResults, KnowledgeNodesGetErrors, KnowledgeNodesGetResults, KnowledgeNodesUpdateErrors, KnowledgeNodesUpdateResults, KnowledgePagesListErrors, KnowledgePagesListResults, KnowledgePromptErrors, KnowledgePromptResults, KnowledgeRegenerateTocErrors, KnowledgeRegenerateTocResults, ObservabilityGetErrors, ObservabilityGetResults, OutboundCallRequest, PatchCallBatchRequest, PatchConversationRequest, PatchEmailBatchRequest, PatchEmailRecipientRequest, PatchEmailSendRequest, PatchIntegrationRequest, PatchIntegrationTriggerRequest, PatchNodeRequest, PatchPhoneNumberRequest, PatchTaskRequest, PatchTelephonyAccountRequest, PatchToolRequest, PatchWebhookRequest, PreviewAnalysisRequest, ProviderKeysDeleteErrors, ProviderKeysDeleteResults, ProviderKeysListErrors, ProviderKeysListResults, ProviderKeysSetErrors, ProviderKeysSetResults, PublishToolRequest, RedraftRequest, RunTaskRequest, RunToolRequest, SchemasFunctionsGetErrors, SchemasFunctionsGetResults, SchemasGetErrors, SchemasGetResults, SecretsCreateErrors, SecretsCreateResults, SecretsDeleteErrors, SecretsDeleteResults, SecretsListErrors, SecretsListResults, SelectRecipientsRequest, SendMessageRequest, SetProviderKeyRequest, TasksCreateErrors, TasksCreateResults, TasksDeleteErrors, TasksDeleteResults, TasksGetErrors, TasksGetResults, TasksListErrors, TasksListResults, TasksPublishErrors, TasksPublishResults, TasksRunsCreateErrors, TasksRunsCreateResults, TasksRunsGetErrors, TasksRunsGetResults, TasksRunsListErrors, TasksRunsListResults, TasksUpdateErrors, TasksUpdateResults, TasksValidateErrors, TasksValidateResults, TasksVersionsGetErrors, TasksVersionsGetResults, TasksVersionsRollbackErrors, TasksVersionsRollbackResults, TelephonyAccountsCreateErrors, TelephonyAccountsCreateResults, TelephonyAccountsDeleteErrors, TelephonyAccountsDeleteResults, TelephonyAccountsGetErrors, TelephonyAccountsGetResults, TelephonyAccountsListErrors, TelephonyAccountsListResults, TelephonyAccountsProvisionErrors, TelephonyAccountsProvisionResults, TelephonyAccountsRemoteNumbersErrors, TelephonyAccountsRemoteNumbersResults, TelephonyAccountsUpdateErrors, TelephonyAccountsUpdateResults, TelephonyPhoneNumbersAssignErrors, TelephonyPhoneNumbersAssignResults, TelephonyPhoneNumbersGetErrors, TelephonyPhoneNumbersGetResults, TelephonyPhoneNumbersImportErrors, TelephonyPhoneNumbersImportResults, TelephonyPhoneNumbersListErrors, TelephonyPhoneNumbersListResults, TelephonyPhoneNumbersProvisionErrors, TelephonyPhoneNumbersProvisionResults, TelephonyPhoneNumbersUnassignErrors, TelephonyPhoneNumbersUnassignResults, TelephonyPhoneNumbersUpdateErrors, TelephonyPhoneNumbersUpdateResults, TelephonyProvidersListErrors, TelephonyProvidersListResults, TextMessageRequest, TokenRequest, ToolsCreateErrors, ToolsCreateResults, ToolsDeleteErrors, ToolsDeleteResults, ToolsGetErrors, ToolsGetResults, ToolsListErrors, ToolsListResults, ToolsPublishErrors, ToolsPublishResults, ToolsRunErrors, ToolsRunResults, ToolsUpdateErrors, ToolsUpdateResults, ToolsValidateErrors, ToolsValidateResults, ToolsVersionsGetErrors, ToolsVersionsGetResults, ToolsVersionsRollbackErrors, ToolsVersionsRollbackResults, UpdateAgentRequest, WebhooksCreateErrors, WebhooksCreateResults, WebhooksDeleteErrors, WebhooksDeleteResults, WebhooksDeliveriesErrors, WebhooksDeliveriesResults, WebhooksEventTypesErrors, WebhooksEventTypesResults, WebhooksListErrors, WebhooksListResults, WebhooksRotateSecretErrors, WebhooksRotateSecretResults, WebhooksTestErrors, WebhooksTestResults, WebhooksUpdateErrors, WebhooksUpdateResults } from './types.gen.js';
|
|
5
|
+
import type { AddRecipientsRequest, AddVoiceRequest, AgentsCreateErrors, AgentsCreateResults, AgentsDeleteErrors, AgentsDeleteResults, AgentsGetErrors, AgentsGetResults, AgentsListErrors, AgentsListResults, AgentsPublishErrors, AgentsPublishResults, AgentsUpdateErrors, AgentsUpdateResults, AgentsValidateErrors, AgentsValidateResults, AgentsVersionsGetErrors, AgentsVersionsGetResults, AgentsVersionsRollbackErrors, AgentsVersionsRollbackResults, AssignPhoneNumberRequest, BackfillAnalysisRequest, BillingCreditsCheckoutErrors, BillingCreditsCheckoutResults, BillingCreditsGetErrors, BillingCreditsGetResults, BillingCreditsLedgerErrors, BillingCreditsLedgerResults, BuildKBRequest, CallsAnalysisBackfillErrors, CallsAnalysisBackfillResults, CallsAnalysisPreviewErrors, CallsAnalysisPreviewResults, CallsBatchesCancelErrors, CallsBatchesCancelResults, CallsBatchesCreateErrors, CallsBatchesCreateResults, CallsBatchesGetErrors, CallsBatchesGetResults, CallsBatchesListErrors, CallsBatchesListResults, CallsBatchesPauseErrors, CallsBatchesPauseResults, CallsBatchesRecipientsAddErrors, CallsBatchesRecipientsAddResults, CallsBatchesRecipientsListErrors, CallsBatchesRecipientsListResults, CallsBatchesResumeErrors, CallsBatchesResumeResults, CallsBatchesUpdateErrors, CallsBatchesUpdateResults, CallsDeleteErrors, CallsDeleteResults, CallsGetErrors, CallsGetResults, CallsListErrors, CallsListResults, CallsOutboundErrors, CallsOutboundResults, CallsRecordingDeleteErrors, CallsRecordingDeleteResults, CallsRecordingGetErrors, CallsRecordingGetResults, CallsScreenRecordingGetErrors, CallsScreenRecordingGetResults, CallsStatsErrors, CallsStatsResults, CallsTokenErrors, CallsTokenResults, CatalogAvatarsListErrors, CatalogAvatarsListResults, CatalogGetErrors, CatalogGetResults, CatalogModelsSearchErrors, CatalogModelsSearchResults, CatalogVoicesElevenlabsAddErrors, CatalogVoicesElevenlabsAddResults, CatalogVoicesElevenlabsSettingsErrors, CatalogVoicesElevenlabsSettingsResults, CatalogVoicesListErrors, CatalogVoicesListResults, ConversationsCreateErrors, ConversationsCreateResults, ConversationsEventsErrors, ConversationsEventsResult, ConversationsEventsResults, ConversationsGetErrors, ConversationsGetResults, ConversationsItemsListErrors, ConversationsItemsListResults, ConversationsListErrors, ConversationsListResults, ConversationsMessagesCreateErrors, ConversationsMessagesCreateResults, ConversationsSessionsListErrors, ConversationsSessionsListResults, ConversationsSnapshotErrors, ConversationsSnapshotResults, ConversationsUpdateErrors, ConversationsUpdateResults, CopilotAgentsSendErrors, CopilotAgentsSendResults, CopilotAgentsStreamErrors, CopilotAgentsStreamResult, CopilotAgentsStreamResults, CopilotKnowledgeSendErrors, CopilotKnowledgeSendResults, CopilotKnowledgeStreamErrors, CopilotKnowledgeStreamResult, CopilotKnowledgeStreamResults, CopilotTasksSendErrors, CopilotTasksSendResults, CopilotTasksStreamErrors, CopilotTasksStreamResult, CopilotTasksStreamResults, CopilotToolsSendErrors, CopilotToolsSendResults, CopilotToolsStreamErrors, CopilotToolsStreamResult, CopilotToolsStreamResults, CreateAgentRequest, CreateCallBatchRequest, CreateEmailBatchRequest, CreateEmailSendRequest, CreateIntegrationRequest, CreateIntegrationTriggerRequest, CreateKBRequest, CreateSecretRequest, CreateStreamConnectionRequest, CreateTaskRequest, CreateTelephonyAccountRequest, CreateTextConversationRequest, CreateToolRequest, CreateWebhookRequest, CreditCheckoutRequest, EmailBatchesCancelErrors, EmailBatchesCancelResults, EmailBatchesCreateErrors, EmailBatchesCreateResults, EmailBatchesGetErrors, EmailBatchesGetResults, EmailBatchesListErrors, EmailBatchesListResults, EmailBatchesPauseErrors, EmailBatchesPauseResults, EmailBatchesRecipientsListErrors, EmailBatchesRecipientsListResults, EmailBatchesRecipientsRedraftErrors, EmailBatchesRecipientsRedraftResults, EmailBatchesRecipientsRestoreErrors, EmailBatchesRecipientsRestoreResults, EmailBatchesRecipientsSkipErrors, EmailBatchesRecipientsSkipResults, EmailBatchesRecipientsUpdateErrors, EmailBatchesRecipientsUpdateResults, EmailBatchesResumeErrors, EmailBatchesResumeResults, EmailBatchesSendsCancelErrors, EmailBatchesSendsCancelResults, EmailBatchesSendsCreateErrors, EmailBatchesSendsCreateResults, EmailBatchesSendsGetErrors, EmailBatchesSendsGetResults, EmailBatchesSendsListErrors, EmailBatchesSendsListResults, EmailBatchesSendsPauseErrors, EmailBatchesSendsPauseResults, EmailBatchesSendsResumeErrors, EmailBatchesSendsResumeResults, EmailBatchesSendsUpdateErrors, EmailBatchesSendsUpdateResults, EmailBatchesUpdateErrors, EmailBatchesUpdateResults, EmailSendersListErrors, EmailSendersListResults, HealthErrors, HealthResults, ImportPhoneNumbersRequest, IntegrationsCatalogErrors, IntegrationsCatalogResults, IntegrationsCreateErrors, IntegrationsCreateResults, IntegrationsDeleteErrors, IntegrationsDeleteResults, IntegrationsGetErrors, IntegrationsGetResults, IntegrationsListErrors, IntegrationsListResults, IntegrationsMcpToolsListErrors, IntegrationsMcpToolsListResults, IntegrationsTriggersCreateErrors, IntegrationsTriggersCreateResults, IntegrationsTriggersDeleteErrors, IntegrationsTriggersDeleteResults, IntegrationsTriggersListErrors, IntegrationsTriggersListResults, IntegrationsTriggersUpdateErrors, IntegrationsTriggersUpdateResults, IntegrationsUpdateErrors, IntegrationsUpdateResults, KnowledgeBuildErrors, KnowledgeBuildResults, KnowledgeCreateErrors, KnowledgeCreateResults, KnowledgeDeleteErrors, KnowledgeDeleteResults, KnowledgeEventsErrors, KnowledgeEventsResult, KnowledgeEventsResults, KnowledgeGetErrors, KnowledgeGetResults, KnowledgeListErrors, KnowledgeListResults, KnowledgeNodesDeleteErrors, KnowledgeNodesDeleteResults, KnowledgeNodesGetErrors, KnowledgeNodesGetResults, KnowledgeNodesUpdateErrors, KnowledgeNodesUpdateResults, KnowledgePagesListErrors, KnowledgePagesListResults, KnowledgePromptErrors, KnowledgePromptResults, KnowledgeRegenerateTocErrors, KnowledgeRegenerateTocResults, ObservabilityGetErrors, ObservabilityGetResults, OutboundCallRequest, PatchCallBatchRequest, PatchConversationRequest, PatchEmailBatchRequest, PatchEmailRecipientRequest, PatchEmailSendRequest, PatchIntegrationRequest, PatchIntegrationTriggerRequest, PatchNodeRequest, PatchPhoneNumberRequest, PatchStreamConnectionRequest, PatchTaskRequest, PatchTelephonyAccountRequest, PatchToolRequest, PatchWebhookRequest, PreviewAnalysisRequest, ProviderKeysDeleteErrors, ProviderKeysDeleteResults, ProviderKeysListErrors, ProviderKeysListResults, ProviderKeysSetErrors, ProviderKeysSetResults, PublishToolRequest, RedraftRequest, RunTaskRequest, RunToolRequest, SchemasFunctionsGetErrors, SchemasFunctionsGetResults, SchemasGetErrors, SchemasGetResults, SecretsCreateErrors, SecretsCreateResults, SecretsDeleteErrors, SecretsDeleteResults, SecretsListErrors, SecretsListResults, SelectRecipientsRequest, SendMessageRequest, SetProviderKeyRequest, TasksCreateErrors, TasksCreateResults, TasksDeleteErrors, TasksDeleteResults, TasksGetErrors, TasksGetResults, TasksListErrors, TasksListResults, TasksPublishErrors, TasksPublishResults, TasksRunsCreateErrors, TasksRunsCreateResults, TasksRunsGetErrors, TasksRunsGetResults, TasksRunsListErrors, TasksRunsListResults, TasksUpdateErrors, TasksUpdateResults, TasksValidateErrors, TasksValidateResults, TasksVersionsGetErrors, TasksVersionsGetResults, TasksVersionsRollbackErrors, TasksVersionsRollbackResults, TelephonyAccountsCreateErrors, TelephonyAccountsCreateResults, TelephonyAccountsDeleteErrors, TelephonyAccountsDeleteResults, TelephonyAccountsGetErrors, TelephonyAccountsGetResults, TelephonyAccountsListErrors, TelephonyAccountsListResults, TelephonyAccountsProvisionErrors, TelephonyAccountsProvisionResults, TelephonyAccountsRemoteNumbersErrors, TelephonyAccountsRemoteNumbersResults, TelephonyAccountsUpdateErrors, TelephonyAccountsUpdateResults, TelephonyPhoneNumbersAssignErrors, TelephonyPhoneNumbersAssignResults, TelephonyPhoneNumbersGetErrors, TelephonyPhoneNumbersGetResults, TelephonyPhoneNumbersImportErrors, TelephonyPhoneNumbersImportResults, TelephonyPhoneNumbersListErrors, TelephonyPhoneNumbersListResults, TelephonyPhoneNumbersProvisionErrors, TelephonyPhoneNumbersProvisionResults, TelephonyPhoneNumbersUnassignErrors, TelephonyPhoneNumbersUnassignResults, TelephonyPhoneNumbersUpdateErrors, TelephonyPhoneNumbersUpdateResults, TelephonyProvidersListErrors, TelephonyProvidersListResults, TelephonyStreamsCreateErrors, TelephonyStreamsCreateResults, TelephonyStreamsDeleteErrors, TelephonyStreamsDeleteResults, TelephonyStreamsGetErrors, TelephonyStreamsGetResults, TelephonyStreamsListErrors, TelephonyStreamsListResults, TelephonyStreamsUpdateErrors, TelephonyStreamsUpdateResults, TextMessageRequest, TokenRequest, ToolsCreateErrors, ToolsCreateResults, ToolsDeleteErrors, ToolsDeleteResults, ToolsGetErrors, ToolsGetResults, ToolsListErrors, ToolsListResults, ToolsPublishErrors, ToolsPublishResults, ToolsRunErrors, ToolsRunResults, ToolsUpdateErrors, ToolsUpdateResults, ToolsValidateErrors, ToolsValidateResults, ToolsVersionsGetErrors, ToolsVersionsGetResults, ToolsVersionsRollbackErrors, ToolsVersionsRollbackResults, UpdateAgentRequest, WebhooksCreateErrors, WebhooksCreateResults, WebhooksDeleteErrors, WebhooksDeleteResults, WebhooksDeliveriesErrors, WebhooksDeliveriesResults, WebhooksEventTypesErrors, WebhooksEventTypesResults, WebhooksListErrors, WebhooksListResults, WebhooksRotateSecretErrors, WebhooksRotateSecretResults, WebhooksTestErrors, WebhooksTestResults, WebhooksUpdateErrors, WebhooksUpdateResults } from './types.gen.js';
|
|
6
6
|
|
|
7
7
|
export type Options<TData extends TDataShape = TDataShape, ThrowOnError extends boolean = boolean, TResponse = unknown> = Options2<TData, ThrowOnError, TResponse> & {
|
|
8
8
|
/**
|
|
@@ -975,7 +975,7 @@ export class Calls extends HeyApiClient {
|
|
|
975
975
|
start?: string | null;
|
|
976
976
|
end?: string | null;
|
|
977
977
|
agent_id?: string | null;
|
|
978
|
-
type?: 'WEB' | 'SIP_INBOUND' | 'SIP_OUTBOUND' | null;
|
|
978
|
+
type?: 'WEB' | 'SIP_INBOUND' | 'SIP_OUTBOUND' | 'STREAM' | null;
|
|
979
979
|
status?: string | null;
|
|
980
980
|
outcome?: string | null;
|
|
981
981
|
contact_key?: string | null;
|
|
@@ -1252,6 +1252,41 @@ export class Avatars extends HeyApiClient {
|
|
|
1252
1252
|
}
|
|
1253
1253
|
}
|
|
1254
1254
|
|
|
1255
|
+
export class Models extends HeyApiClient {
|
|
1256
|
+
/**
|
|
1257
|
+
* Search Models
|
|
1258
|
+
*
|
|
1259
|
+
* Search the language models a provider offers too many of to list.
|
|
1260
|
+
*
|
|
1261
|
+
* `GET /catalog` carries every model except these. A provider marked
|
|
1262
|
+
* `browse: "search"` there — OpenRouter — reaches hundreds of models through
|
|
1263
|
+
* one key, so they are searched a page at a time instead. With no `q` the order
|
|
1264
|
+
* is real-world popularity. Everything returned is a valid `llm.model`.
|
|
1265
|
+
*/
|
|
1266
|
+
public search<ThrowOnError extends boolean = false>(parameters?: {
|
|
1267
|
+
q?: string;
|
|
1268
|
+
limit?: number;
|
|
1269
|
+
cursor?: string;
|
|
1270
|
+
}, options?: Options<never, ThrowOnError>): RequestResult<CatalogModelsSearchResults, CatalogModelsSearchErrors, ThrowOnError, 'data'> {
|
|
1271
|
+
const params = buildClientParams([parameters], [{ args: [
|
|
1272
|
+
{ in: 'query', key: 'q' },
|
|
1273
|
+
{ in: 'query', key: 'limit' },
|
|
1274
|
+
{ in: 'query', key: 'cursor' }
|
|
1275
|
+
] }]);
|
|
1276
|
+
return (options?.client ?? this.client).get<CatalogModelsSearchResults, CatalogModelsSearchErrors, ThrowOnError, 'data'>({
|
|
1277
|
+
responseStyle: 'data',
|
|
1278
|
+
security: [{ scheme: 'bearer', type: 'http' }, {
|
|
1279
|
+
in: 'cookie',
|
|
1280
|
+
name: 'talqing_session',
|
|
1281
|
+
type: 'apiKey'
|
|
1282
|
+
}],
|
|
1283
|
+
url: '/v1/catalog/models',
|
|
1284
|
+
...options,
|
|
1285
|
+
...params
|
|
1286
|
+
});
|
|
1287
|
+
}
|
|
1288
|
+
}
|
|
1289
|
+
|
|
1255
1290
|
export class Elevenlabs extends HeyApiClient {
|
|
1256
1291
|
/**
|
|
1257
1292
|
* Add Elevenlabs Voice
|
|
@@ -1383,6 +1418,10 @@ export class Catalog extends HeyApiClient {
|
|
|
1383
1418
|
* `realtime` lists the speech-to-speech models. One of those replaces `stt`,
|
|
1384
1419
|
* `llm` and `tts` together, so an agent sets either `realtime` or the three
|
|
1385
1420
|
* cascade slots, never both.
|
|
1421
|
+
*
|
|
1422
|
+
* One provider's models are NOT here: a `providers` entry whose `browse` is
|
|
1423
|
+
* `search` reaches hundreds of them through one key, and they are searched
|
|
1424
|
+
* through `GET /catalog/models` instead.
|
|
1386
1425
|
*/
|
|
1387
1426
|
public get<ThrowOnError extends boolean = false>(options?: Options<never, ThrowOnError>): RequestResult<CatalogGetResults, CatalogGetErrors, ThrowOnError, 'data'> {
|
|
1388
1427
|
return (options?.client ?? this.client).get<CatalogGetResults, CatalogGetErrors, ThrowOnError, 'data'>({
|
|
@@ -1402,6 +1441,11 @@ export class Catalog extends HeyApiClient {
|
|
|
1402
1441
|
return this._avatars ??= new Avatars({ client: this.client });
|
|
1403
1442
|
}
|
|
1404
1443
|
|
|
1444
|
+
private _models?: Models;
|
|
1445
|
+
get models(): Models {
|
|
1446
|
+
return this._models ??= new Models({ client: this.client });
|
|
1447
|
+
}
|
|
1448
|
+
|
|
1405
1449
|
private _voices?: Voices;
|
|
1406
1450
|
get voices(): Voices {
|
|
1407
1451
|
return this._voices ??= new Voices({ client: this.client });
|
|
@@ -2064,7 +2108,8 @@ export class Recipients2 extends HeyApiClient {
|
|
|
2064
2108
|
* every row it refuses. Rows already sent or queued are never redrafted.
|
|
2065
2109
|
*
|
|
2066
2110
|
* This revives a batch that had finished drafting, and a person's edited cells
|
|
2067
|
-
* survive unless you pass `clear_overrides
|
|
2111
|
+
* survive unless you pass `clear_overrides` — and are what the task is given.
|
|
2112
|
+
* Refused on a canceled batch, whose rows can never draft again.
|
|
2068
2113
|
*/
|
|
2069
2114
|
public redraft<ThrowOnError extends boolean = false>(parameters: {
|
|
2070
2115
|
batch_id: string;
|
|
@@ -2120,11 +2165,10 @@ export class Recipients2 extends HeyApiClient {
|
|
|
2120
2165
|
/**
|
|
2121
2166
|
* Skip Email Batch Recipients
|
|
2122
2167
|
*
|
|
2123
|
-
* Take
|
|
2168
|
+
* Take rows out of consideration. Reversible with `restore`.
|
|
2124
2169
|
*
|
|
2125
|
-
*
|
|
2126
|
-
*
|
|
2127
|
-
* `send` does not, because the rule is about irreversibility rather than bulk.
|
|
2170
|
+
* Accepts drafted rows and rows whose drafting failed. Takes either
|
|
2171
|
+
* `recipient_ids` or `selection: "all_eligible"`, which here means both.
|
|
2128
2172
|
*/
|
|
2129
2173
|
public skip<ThrowOnError extends boolean = false>(parameters: {
|
|
2130
2174
|
batch_id: string;
|
|
@@ -2221,8 +2265,8 @@ export class Sends extends HeyApiClient {
|
|
|
2221
2265
|
*
|
|
2222
2266
|
* One send: where its rows are, and when it next does something.
|
|
2223
2267
|
*
|
|
2224
|
-
* `
|
|
2225
|
-
*
|
|
2268
|
+
* `next_send_reason` says which gate is holding it — `start`, `window`,
|
|
2269
|
+
* `daily_cap`, `retry` or `gap`.
|
|
2226
2270
|
*/
|
|
2227
2271
|
public get<ThrowOnError extends boolean = false>(parameters: {
|
|
2228
2272
|
batch_id: string;
|
|
@@ -3519,67 +3563,50 @@ export class Secrets extends HeyApiClient {
|
|
|
3519
3563
|
}
|
|
3520
3564
|
}
|
|
3521
3565
|
|
|
3522
|
-
export class
|
|
3566
|
+
export class Streams extends HeyApiClient {
|
|
3523
3567
|
/**
|
|
3524
|
-
* List
|
|
3525
|
-
*
|
|
3526
|
-
* This task's runs, newest first, each with its output, trace and cost.
|
|
3568
|
+
* List Stream Connections
|
|
3527
3569
|
*
|
|
3528
|
-
*
|
|
3529
|
-
* a run of the draft.
|
|
3570
|
+
* List WebSocket media-stream connections a partner can dial.
|
|
3530
3571
|
*/
|
|
3531
|
-
public list<ThrowOnError extends boolean = false>(parameters
|
|
3532
|
-
task_id: string;
|
|
3572
|
+
public list<ThrowOnError extends boolean = false>(parameters?: {
|
|
3533
3573
|
limit?: number;
|
|
3534
3574
|
offset?: number;
|
|
3535
|
-
}, options?: Options<never, ThrowOnError>): RequestResult<
|
|
3536
|
-
const params = buildClientParams([parameters], [{ args: [
|
|
3537
|
-
|
|
3538
|
-
{ in: 'query', key: 'limit' },
|
|
3539
|
-
{ in: 'query', key: 'offset' }
|
|
3540
|
-
] }]);
|
|
3541
|
-
return (options?.client ?? this.client).get<TasksRunsListResults, TasksRunsListErrors, ThrowOnError, 'data'>({
|
|
3575
|
+
}, options?: Options<never, ThrowOnError>): RequestResult<TelephonyStreamsListResults, TelephonyStreamsListErrors, ThrowOnError, 'data'> {
|
|
3576
|
+
const params = buildClientParams([parameters], [{ args: [{ in: 'query', key: 'limit' }, { in: 'query', key: 'offset' }] }]);
|
|
3577
|
+
return (options?.client ?? this.client).get<TelephonyStreamsListResults, TelephonyStreamsListErrors, ThrowOnError, 'data'>({
|
|
3542
3578
|
responseStyle: 'data',
|
|
3543
3579
|
security: [{ scheme: 'bearer', type: 'http' }, {
|
|
3544
3580
|
in: 'cookie',
|
|
3545
3581
|
name: 'talqing_session',
|
|
3546
3582
|
type: 'apiKey'
|
|
3547
3583
|
}],
|
|
3548
|
-
url: '/v1/
|
|
3584
|
+
url: '/v1/streams',
|
|
3549
3585
|
...options,
|
|
3550
3586
|
...params
|
|
3551
3587
|
});
|
|
3552
3588
|
}
|
|
3553
3589
|
|
|
3554
3590
|
/**
|
|
3555
|
-
*
|
|
3556
|
-
*
|
|
3557
|
-
* Run the task once with the variables you supply, and wait for the result.
|
|
3591
|
+
* Create Stream Connection
|
|
3558
3592
|
*
|
|
3559
|
-
*
|
|
3560
|
-
* the MCP servers spend your credits, and the model spends your tokens. A task
|
|
3561
|
-
* that books a slot, charges a card or sends a message will do so.
|
|
3593
|
+
* Create a connection a streaming partner can dial.
|
|
3562
3594
|
*
|
|
3563
|
-
*
|
|
3564
|
-
*
|
|
3565
|
-
* — an unknown name is refused rather than dropped. The response is the whole
|
|
3566
|
-
* run: the structured `output`, a `trace` of every tool call, the steps used
|
|
3567
|
-
* and what the tokens cost. On failure `error.type` says whose problem it is.
|
|
3568
|
-
* Secrets are redacted.
|
|
3595
|
+
* One connection per agent per dialect: the URL names both, so a second would
|
|
3596
|
+
* only be the same URL again.
|
|
3569
3597
|
*/
|
|
3570
3598
|
public create<ThrowOnError extends boolean = false>(parameters: {
|
|
3571
|
-
|
|
3572
|
-
|
|
3573
|
-
|
|
3574
|
-
|
|
3575
|
-
return (options?.client ?? this.client).post<TasksRunsCreateResults, TasksRunsCreateErrors, ThrowOnError, 'data'>({
|
|
3599
|
+
createStreamConnectionRequest: CreateStreamConnectionRequest;
|
|
3600
|
+
}, options?: Options<never, ThrowOnError>): RequestResult<TelephonyStreamsCreateResults, TelephonyStreamsCreateErrors, ThrowOnError, 'data'> {
|
|
3601
|
+
const params = buildClientParams([parameters], [{ args: [{ key: 'createStreamConnectionRequest', map: 'body' }] }]);
|
|
3602
|
+
return (options?.client ?? this.client).post<TelephonyStreamsCreateResults, TelephonyStreamsCreateErrors, ThrowOnError, 'data'>({
|
|
3576
3603
|
responseStyle: 'data',
|
|
3577
3604
|
security: [{ scheme: 'bearer', type: 'http' }, {
|
|
3578
3605
|
in: 'cookie',
|
|
3579
3606
|
name: 'talqing_session',
|
|
3580
3607
|
type: 'apiKey'
|
|
3581
3608
|
}],
|
|
3582
|
-
url: '/v1/
|
|
3609
|
+
url: '/v1/streams',
|
|
3583
3610
|
...options,
|
|
3584
3611
|
...params,
|
|
3585
3612
|
headers: {
|
|
@@ -3591,143 +3618,134 @@ export class Runs extends HeyApiClient {
|
|
|
3591
3618
|
}
|
|
3592
3619
|
|
|
3593
3620
|
/**
|
|
3594
|
-
*
|
|
3621
|
+
* Delete Stream Connection
|
|
3595
3622
|
*
|
|
3596
|
-
*
|
|
3597
|
-
* what it cost.
|
|
3598
|
-
*
|
|
3599
|
-
* This is what answers "why did it write that" for a caller holding one run id
|
|
3600
|
-
* — an email batch's review table links each drafted row here. Secret values
|
|
3601
|
-
* are redacted from the trace, and a trace that was cut reports it.
|
|
3623
|
+
* Delete a stream connection. Calls it already carried are kept.
|
|
3602
3624
|
*/
|
|
3603
|
-
public
|
|
3604
|
-
|
|
3605
|
-
|
|
3606
|
-
|
|
3607
|
-
|
|
3608
|
-
return (options?.client ?? this.client).get<TasksRunsGetResults, TasksRunsGetErrors, ThrowOnError, 'data'>({
|
|
3625
|
+
public delete<ThrowOnError extends boolean = false>(parameters: {
|
|
3626
|
+
connection_id: string;
|
|
3627
|
+
}, options?: Options<never, ThrowOnError>): RequestResult<TelephonyStreamsDeleteResults, TelephonyStreamsDeleteErrors, ThrowOnError, 'data'> {
|
|
3628
|
+
const params = buildClientParams([parameters], [{ args: [{ in: 'path', key: 'connection_id' }] }]);
|
|
3629
|
+
return (options?.client ?? this.client).delete<TelephonyStreamsDeleteResults, TelephonyStreamsDeleteErrors, ThrowOnError, 'data'>({
|
|
3609
3630
|
responseStyle: 'data',
|
|
3610
3631
|
security: [{ scheme: 'bearer', type: 'http' }, {
|
|
3611
3632
|
in: 'cookie',
|
|
3612
3633
|
name: 'talqing_session',
|
|
3613
3634
|
type: 'apiKey'
|
|
3614
3635
|
}],
|
|
3615
|
-
url: '/v1/
|
|
3636
|
+
url: '/v1/streams/{connection_id}',
|
|
3616
3637
|
...options,
|
|
3617
3638
|
...params
|
|
3618
3639
|
});
|
|
3619
3640
|
}
|
|
3620
|
-
|
|
3621
|
-
|
|
3622
|
-
export class Versions2 extends HeyApiClient {
|
|
3641
|
+
|
|
3623
3642
|
/**
|
|
3624
|
-
* Get
|
|
3625
|
-
*
|
|
3626
|
-
* Fetch what one published version of a task actually contains.
|
|
3643
|
+
* Get Stream Connection
|
|
3627
3644
|
*
|
|
3628
|
-
*
|
|
3629
|
-
* frozen definition itself — prompt, model, output fields and the tool
|
|
3630
|
-
* versions it pinned, exactly as they were at that publish.
|
|
3645
|
+
* One stream connection, with the URL to hand the partner.
|
|
3631
3646
|
*/
|
|
3632
3647
|
public get<ThrowOnError extends boolean = false>(parameters: {
|
|
3633
|
-
|
|
3634
|
-
|
|
3635
|
-
|
|
3636
|
-
|
|
3637
|
-
return (options?.client ?? this.client).get<TasksVersionsGetResults, TasksVersionsGetErrors, ThrowOnError, 'data'>({
|
|
3648
|
+
connection_id: string;
|
|
3649
|
+
}, options?: Options<never, ThrowOnError>): RequestResult<TelephonyStreamsGetResults, TelephonyStreamsGetErrors, ThrowOnError, 'data'> {
|
|
3650
|
+
const params = buildClientParams([parameters], [{ args: [{ in: 'path', key: 'connection_id' }] }]);
|
|
3651
|
+
return (options?.client ?? this.client).get<TelephonyStreamsGetResults, TelephonyStreamsGetErrors, ThrowOnError, 'data'>({
|
|
3638
3652
|
responseStyle: 'data',
|
|
3639
3653
|
security: [{ scheme: 'bearer', type: 'http' }, {
|
|
3640
3654
|
in: 'cookie',
|
|
3641
3655
|
name: 'talqing_session',
|
|
3642
3656
|
type: 'apiKey'
|
|
3643
3657
|
}],
|
|
3644
|
-
url: '/v1/
|
|
3658
|
+
url: '/v1/streams/{connection_id}',
|
|
3645
3659
|
...options,
|
|
3646
3660
|
...params
|
|
3647
3661
|
});
|
|
3648
3662
|
}
|
|
3649
3663
|
|
|
3650
3664
|
/**
|
|
3651
|
-
*
|
|
3665
|
+
* Patch Stream Connection
|
|
3652
3666
|
*
|
|
3653
|
-
*
|
|
3667
|
+
* Rename a connection, point it at another agent, or disable it.
|
|
3654
3668
|
*
|
|
3655
|
-
*
|
|
3656
|
-
*
|
|
3657
|
-
* draft tracks each tool's latest published version, not the ones this version
|
|
3658
|
-
* pinned.
|
|
3669
|
+
* Disabling refuses new calls immediately and is the only way to stop a URL
|
|
3670
|
+
* answering; calls already running are untouched.
|
|
3659
3671
|
*/
|
|
3660
|
-
public
|
|
3661
|
-
|
|
3662
|
-
|
|
3663
|
-
}, options?: Options<never, ThrowOnError>): RequestResult<
|
|
3664
|
-
const params = buildClientParams([parameters], [{ args: [{ in: 'path', key: '
|
|
3665
|
-
return (options?.client ?? this.client).
|
|
3672
|
+
public update<ThrowOnError extends boolean = false>(parameters: {
|
|
3673
|
+
connection_id: string;
|
|
3674
|
+
patchStreamConnectionRequest: PatchStreamConnectionRequest;
|
|
3675
|
+
}, options?: Options<never, ThrowOnError>): RequestResult<TelephonyStreamsUpdateResults, TelephonyStreamsUpdateErrors, ThrowOnError, 'data'> {
|
|
3676
|
+
const params = buildClientParams([parameters], [{ args: [{ in: 'path', key: 'connection_id' }, { key: 'patchStreamConnectionRequest', map: 'body' }] }]);
|
|
3677
|
+
return (options?.client ?? this.client).patch<TelephonyStreamsUpdateResults, TelephonyStreamsUpdateErrors, ThrowOnError, 'data'>({
|
|
3666
3678
|
responseStyle: 'data',
|
|
3667
3679
|
security: [{ scheme: 'bearer', type: 'http' }, {
|
|
3668
3680
|
in: 'cookie',
|
|
3669
3681
|
name: 'talqing_session',
|
|
3670
3682
|
type: 'apiKey'
|
|
3671
3683
|
}],
|
|
3672
|
-
url: '/v1/
|
|
3684
|
+
url: '/v1/streams/{connection_id}',
|
|
3673
3685
|
...options,
|
|
3674
|
-
...params
|
|
3686
|
+
...params,
|
|
3687
|
+
headers: {
|
|
3688
|
+
'Content-Type': 'application/json',
|
|
3689
|
+
...options?.headers,
|
|
3690
|
+
...params.headers
|
|
3691
|
+
}
|
|
3675
3692
|
});
|
|
3676
3693
|
}
|
|
3677
3694
|
}
|
|
3678
3695
|
|
|
3679
|
-
export class
|
|
3696
|
+
export class Accounts extends HeyApiClient {
|
|
3680
3697
|
/**
|
|
3681
|
-
* List
|
|
3698
|
+
* List Telephony Accounts
|
|
3682
3699
|
*
|
|
3683
|
-
* List the workspace's
|
|
3700
|
+
* List the workspace's connected carrier accounts.
|
|
3684
3701
|
*
|
|
3685
|
-
* A
|
|
3686
|
-
*
|
|
3687
|
-
*
|
|
3688
|
-
*
|
|
3702
|
+
* A carrier account is the credential Talqing uses to reach a phone network;
|
|
3703
|
+
* phone numbers hang off one. `setup_complete` and `setup_steps` say whether
|
|
3704
|
+
* it is finished — including the steps that can only be done in the carrier's
|
|
3705
|
+
* own console.
|
|
3689
3706
|
*/
|
|
3690
3707
|
public list<ThrowOnError extends boolean = false>(parameters?: {
|
|
3691
3708
|
limit?: number;
|
|
3692
3709
|
offset?: number;
|
|
3693
|
-
}, options?: Options<never, ThrowOnError>): RequestResult<
|
|
3710
|
+
}, options?: Options<never, ThrowOnError>): RequestResult<TelephonyAccountsListResults, TelephonyAccountsListErrors, ThrowOnError, 'data'> {
|
|
3694
3711
|
const params = buildClientParams([parameters], [{ args: [{ in: 'query', key: 'limit' }, { in: 'query', key: 'offset' }] }]);
|
|
3695
|
-
return (options?.client ?? this.client).get<
|
|
3712
|
+
return (options?.client ?? this.client).get<TelephonyAccountsListResults, TelephonyAccountsListErrors, ThrowOnError, 'data'>({
|
|
3696
3713
|
responseStyle: 'data',
|
|
3697
3714
|
security: [{ scheme: 'bearer', type: 'http' }, {
|
|
3698
3715
|
in: 'cookie',
|
|
3699
3716
|
name: 'talqing_session',
|
|
3700
3717
|
type: 'apiKey'
|
|
3701
3718
|
}],
|
|
3702
|
-
url: '/v1/
|
|
3719
|
+
url: '/v1/telephony/accounts',
|
|
3703
3720
|
...options,
|
|
3704
3721
|
...params
|
|
3705
3722
|
});
|
|
3706
3723
|
}
|
|
3707
3724
|
|
|
3708
3725
|
/**
|
|
3709
|
-
* Create
|
|
3726
|
+
* Create Telephony Account
|
|
3710
3727
|
*
|
|
3711
|
-
*
|
|
3712
|
-
* and returns a typed result.
|
|
3728
|
+
* Connect a carrier account so the workspace can own phone numbers.
|
|
3713
3729
|
*
|
|
3714
|
-
* `
|
|
3715
|
-
*
|
|
3716
|
-
*
|
|
3717
|
-
*
|
|
3730
|
+
* `account_info` and `credentials` must carry exactly the keys that carrier's
|
|
3731
|
+
* `list_telephony_providers` entry declares. A credential may be plaintext —
|
|
3732
|
+
* stored as a workspace secret — or an existing reference.
|
|
3733
|
+
*
|
|
3734
|
+
* Creating only records the credential; call `provision_telephony_account`
|
|
3735
|
+
* next to build the SIP trunk.
|
|
3718
3736
|
*/
|
|
3719
3737
|
public create<ThrowOnError extends boolean = false>(parameters: {
|
|
3720
|
-
|
|
3721
|
-
}, options?: Options<never, ThrowOnError>): RequestResult<
|
|
3722
|
-
const params = buildClientParams([parameters], [{ args: [{ key: '
|
|
3723
|
-
return (options?.client ?? this.client).post<
|
|
3738
|
+
createTelephonyAccountRequest: CreateTelephonyAccountRequest;
|
|
3739
|
+
}, options?: Options<never, ThrowOnError>): RequestResult<TelephonyAccountsCreateResults, TelephonyAccountsCreateErrors, ThrowOnError, 'data'> {
|
|
3740
|
+
const params = buildClientParams([parameters], [{ args: [{ key: 'createTelephonyAccountRequest', map: 'body' }] }]);
|
|
3741
|
+
return (options?.client ?? this.client).post<TelephonyAccountsCreateResults, TelephonyAccountsCreateErrors, ThrowOnError, 'data'>({
|
|
3724
3742
|
responseStyle: 'data',
|
|
3725
3743
|
security: [{ scheme: 'bearer', type: 'http' }, {
|
|
3726
3744
|
in: 'cookie',
|
|
3727
3745
|
name: 'talqing_session',
|
|
3728
3746
|
type: 'apiKey'
|
|
3729
3747
|
}],
|
|
3730
|
-
url: '/v1/
|
|
3748
|
+
url: '/v1/telephony/accounts',
|
|
3731
3749
|
...options,
|
|
3732
3750
|
...params,
|
|
3733
3751
|
headers: {
|
|
@@ -3739,72 +3757,81 @@ export class Tasks2 extends HeyApiClient {
|
|
|
3739
3757
|
}
|
|
3740
3758
|
|
|
3741
3759
|
/**
|
|
3742
|
-
* Delete
|
|
3760
|
+
* Delete Telephony Account
|
|
3743
3761
|
*
|
|
3744
|
-
*
|
|
3745
|
-
*
|
|
3762
|
+
* Disconnect a carrier account permanently.
|
|
3763
|
+
*
|
|
3764
|
+
* Every phone number on it must be disabled first, so this can never silently
|
|
3765
|
+
* take live numbers off the air. Deleting also tears down the SIP trunk.
|
|
3746
3766
|
*/
|
|
3747
3767
|
public delete<ThrowOnError extends boolean = false>(parameters: {
|
|
3748
|
-
|
|
3749
|
-
}, options?: Options<never, ThrowOnError>): RequestResult<
|
|
3750
|
-
const params = buildClientParams([parameters], [{ args: [{ in: 'path', key: '
|
|
3751
|
-
return (options?.client ?? this.client).delete<
|
|
3768
|
+
account_id: string;
|
|
3769
|
+
}, options?: Options<never, ThrowOnError>): RequestResult<TelephonyAccountsDeleteResults, TelephonyAccountsDeleteErrors, ThrowOnError, 'data'> {
|
|
3770
|
+
const params = buildClientParams([parameters], [{ args: [{ in: 'path', key: 'account_id' }] }]);
|
|
3771
|
+
return (options?.client ?? this.client).delete<TelephonyAccountsDeleteResults, TelephonyAccountsDeleteErrors, ThrowOnError, 'data'>({
|
|
3752
3772
|
responseStyle: 'data',
|
|
3753
3773
|
security: [{ scheme: 'bearer', type: 'http' }, {
|
|
3754
3774
|
in: 'cookie',
|
|
3755
3775
|
name: 'talqing_session',
|
|
3756
3776
|
type: 'apiKey'
|
|
3757
3777
|
}],
|
|
3758
|
-
url: '/v1/
|
|
3778
|
+
url: '/v1/telephony/accounts/{account_id}',
|
|
3759
3779
|
...options,
|
|
3760
3780
|
...params
|
|
3761
3781
|
});
|
|
3762
3782
|
}
|
|
3763
3783
|
|
|
3764
3784
|
/**
|
|
3765
|
-
* Get
|
|
3785
|
+
* Get Telephony Account
|
|
3766
3786
|
*
|
|
3767
|
-
*
|
|
3787
|
+
* Read one carrier account, including what its setup still needs.
|
|
3788
|
+
*
|
|
3789
|
+
* `setup_steps` is the authoritative checklist — read it rather than trying
|
|
3790
|
+
* to re-derive setup state from `provider_state`. A step marked
|
|
3791
|
+
* `user_confirmable` cannot be checked over any API; it is done in the
|
|
3792
|
+
* carrier's console and confirmed with `patch_telephony_account`.
|
|
3768
3793
|
*/
|
|
3769
3794
|
public get<ThrowOnError extends boolean = false>(parameters: {
|
|
3770
|
-
|
|
3771
|
-
}, options?: Options<never, ThrowOnError>): RequestResult<
|
|
3772
|
-
const params = buildClientParams([parameters], [{ args: [{ in: 'path', key: '
|
|
3773
|
-
return (options?.client ?? this.client).get<
|
|
3795
|
+
account_id: string;
|
|
3796
|
+
}, options?: Options<never, ThrowOnError>): RequestResult<TelephonyAccountsGetResults, TelephonyAccountsGetErrors, ThrowOnError, 'data'> {
|
|
3797
|
+
const params = buildClientParams([parameters], [{ args: [{ in: 'path', key: 'account_id' }] }]);
|
|
3798
|
+
return (options?.client ?? this.client).get<TelephonyAccountsGetResults, TelephonyAccountsGetErrors, ThrowOnError, 'data'>({
|
|
3774
3799
|
responseStyle: 'data',
|
|
3775
3800
|
security: [{ scheme: 'bearer', type: 'http' }, {
|
|
3776
3801
|
in: 'cookie',
|
|
3777
3802
|
name: 'talqing_session',
|
|
3778
3803
|
type: 'apiKey'
|
|
3779
3804
|
}],
|
|
3780
|
-
url: '/v1/
|
|
3805
|
+
url: '/v1/telephony/accounts/{account_id}',
|
|
3781
3806
|
...options,
|
|
3782
3807
|
...params
|
|
3783
3808
|
});
|
|
3784
3809
|
}
|
|
3785
3810
|
|
|
3786
3811
|
/**
|
|
3787
|
-
*
|
|
3812
|
+
* Patch Telephony Account
|
|
3788
3813
|
*
|
|
3789
|
-
*
|
|
3814
|
+
* Update a carrier account: rename it, replace credentials, or disable it.
|
|
3790
3815
|
*
|
|
3791
|
-
*
|
|
3792
|
-
*
|
|
3793
|
-
*
|
|
3816
|
+
* Only the fields you send change. `status` accepts `disabled` to stop the
|
|
3817
|
+
* account and `connected` to re-enable it. Set `console_setup_confirmed` when
|
|
3818
|
+
* the user says they have finished the carrier-console steps — no API can
|
|
3819
|
+
* verify that work, and inbound calling on this account's numbers stays
|
|
3820
|
+
* blocked until they confirm.
|
|
3794
3821
|
*/
|
|
3795
3822
|
public update<ThrowOnError extends boolean = false>(parameters: {
|
|
3796
|
-
|
|
3797
|
-
|
|
3798
|
-
}, options?: Options<never, ThrowOnError>): RequestResult<
|
|
3799
|
-
const params = buildClientParams([parameters], [{ args: [{ in: 'path', key: '
|
|
3800
|
-
return (options?.client ?? this.client).patch<
|
|
3823
|
+
account_id: string;
|
|
3824
|
+
patchTelephonyAccountRequest: PatchTelephonyAccountRequest;
|
|
3825
|
+
}, options?: Options<never, ThrowOnError>): RequestResult<TelephonyAccountsUpdateResults, TelephonyAccountsUpdateErrors, ThrowOnError, 'data'> {
|
|
3826
|
+
const params = buildClientParams([parameters], [{ args: [{ in: 'path', key: 'account_id' }, { key: 'patchTelephonyAccountRequest', map: 'body' }] }]);
|
|
3827
|
+
return (options?.client ?? this.client).patch<TelephonyAccountsUpdateResults, TelephonyAccountsUpdateErrors, ThrowOnError, 'data'>({
|
|
3801
3828
|
responseStyle: 'data',
|
|
3802
3829
|
security: [{ scheme: 'bearer', type: 'http' }, {
|
|
3803
3830
|
in: 'cookie',
|
|
3804
3831
|
name: 'talqing_session',
|
|
3805
3832
|
type: 'apiKey'
|
|
3806
3833
|
}],
|
|
3807
|
-
url: '/v1/
|
|
3834
|
+
url: '/v1/telephony/accounts/{account_id}',
|
|
3808
3835
|
...options,
|
|
3809
3836
|
...params,
|
|
3810
3837
|
headers: {
|
|
@@ -3816,122 +3843,174 @@ export class Tasks2 extends HeyApiClient {
|
|
|
3816
3843
|
}
|
|
3817
3844
|
|
|
3818
3845
|
/**
|
|
3819
|
-
*
|
|
3846
|
+
* Provision Telephony Account
|
|
3820
3847
|
*
|
|
3821
|
-
*
|
|
3848
|
+
* Build (or repair) the SIP trunk between Talqing and the carrier.
|
|
3822
3849
|
*
|
|
3823
|
-
*
|
|
3824
|
-
*
|
|
3825
|
-
*
|
|
3850
|
+
* Run this after connecting an account, and again after replacing its
|
|
3851
|
+
* credentials. It is safe to repeat: it converges the carrier side to what
|
|
3852
|
+
* the account should have rather than creating a second trunk. The response's
|
|
3853
|
+
* `status` and `setup_steps` say what is working and what is left.
|
|
3826
3854
|
*/
|
|
3827
|
-
public
|
|
3828
|
-
|
|
3829
|
-
}, options?: Options<never, ThrowOnError>): RequestResult<
|
|
3830
|
-
const params = buildClientParams([parameters], [{ args: [{ in: 'path', key: '
|
|
3831
|
-
return (options?.client ?? this.client).post<
|
|
3855
|
+
public provision<ThrowOnError extends boolean = false>(parameters: {
|
|
3856
|
+
account_id: string;
|
|
3857
|
+
}, options?: Options<never, ThrowOnError>): RequestResult<TelephonyAccountsProvisionResults, TelephonyAccountsProvisionErrors, ThrowOnError, 'data'> {
|
|
3858
|
+
const params = buildClientParams([parameters], [{ args: [{ in: 'path', key: 'account_id' }] }]);
|
|
3859
|
+
return (options?.client ?? this.client).post<TelephonyAccountsProvisionResults, TelephonyAccountsProvisionErrors, ThrowOnError, 'data'>({
|
|
3832
3860
|
responseStyle: 'data',
|
|
3833
3861
|
security: [{ scheme: 'bearer', type: 'http' }, {
|
|
3834
3862
|
in: 'cookie',
|
|
3835
3863
|
name: 'talqing_session',
|
|
3836
3864
|
type: 'apiKey'
|
|
3837
3865
|
}],
|
|
3838
|
-
url: '/v1/
|
|
3866
|
+
url: '/v1/telephony/accounts/{account_id}/provision',
|
|
3839
3867
|
...options,
|
|
3840
3868
|
...params
|
|
3841
3869
|
});
|
|
3842
3870
|
}
|
|
3843
3871
|
|
|
3844
3872
|
/**
|
|
3845
|
-
*
|
|
3873
|
+
* List Remote Numbers
|
|
3846
3874
|
*
|
|
3847
|
-
*
|
|
3875
|
+
* List the numbers this account owns at the carrier, ready to import.
|
|
3848
3876
|
*
|
|
3849
|
-
*
|
|
3850
|
-
*
|
|
3851
|
-
*
|
|
3852
|
-
* this task. Returns errors (blocking) and warnings (advisory).
|
|
3877
|
+
* Read live from the carrier, so it also proves the credentials work.
|
|
3878
|
+
* `already_imported` marks the ones Talqing already has — pass the rest to
|
|
3879
|
+
* `import_phone_numbers`. Buying a number is done at the carrier, not here.
|
|
3853
3880
|
*/
|
|
3854
|
-
public
|
|
3855
|
-
|
|
3856
|
-
|
|
3857
|
-
|
|
3858
|
-
|
|
3881
|
+
public remoteNumbers<ThrowOnError extends boolean = false>(parameters: {
|
|
3882
|
+
account_id: string;
|
|
3883
|
+
limit?: number;
|
|
3884
|
+
offset?: number;
|
|
3885
|
+
}, options?: Options<never, ThrowOnError>): RequestResult<TelephonyAccountsRemoteNumbersResults, TelephonyAccountsRemoteNumbersErrors, ThrowOnError, 'data'> {
|
|
3886
|
+
const params = buildClientParams([parameters], [{ args: [
|
|
3887
|
+
{ in: 'path', key: 'account_id' },
|
|
3888
|
+
{ in: 'query', key: 'limit' },
|
|
3889
|
+
{ in: 'query', key: 'offset' }
|
|
3890
|
+
] }]);
|
|
3891
|
+
return (options?.client ?? this.client).get<TelephonyAccountsRemoteNumbersResults, TelephonyAccountsRemoteNumbersErrors, ThrowOnError, 'data'>({
|
|
3859
3892
|
responseStyle: 'data',
|
|
3860
3893
|
security: [{ scheme: 'bearer', type: 'http' }, {
|
|
3861
3894
|
in: 'cookie',
|
|
3862
3895
|
name: 'talqing_session',
|
|
3863
3896
|
type: 'apiKey'
|
|
3864
3897
|
}],
|
|
3865
|
-
url: '/v1/
|
|
3898
|
+
url: '/v1/telephony/accounts/{account_id}/remote-numbers',
|
|
3866
3899
|
...options,
|
|
3867
3900
|
...params
|
|
3868
3901
|
});
|
|
3869
3902
|
}
|
|
3870
|
-
|
|
3871
|
-
private _runs?: Runs;
|
|
3872
|
-
get runs(): Runs {
|
|
3873
|
-
return this._runs ??= new Runs({ client: this.client });
|
|
3874
|
-
}
|
|
3875
|
-
|
|
3876
|
-
private _versions?: Versions2;
|
|
3877
|
-
get versions(): Versions2 {
|
|
3878
|
-
return this._versions ??= new Versions2({ client: this.client });
|
|
3879
|
-
}
|
|
3880
3903
|
}
|
|
3881
3904
|
|
|
3882
|
-
export class
|
|
3905
|
+
export class PhoneNumbers extends HeyApiClient {
|
|
3883
3906
|
/**
|
|
3884
|
-
* List
|
|
3907
|
+
* List Phone Numbers
|
|
3885
3908
|
*
|
|
3886
|
-
* List the workspace's
|
|
3909
|
+
* List the workspace's phone numbers, optionally for one carrier account.
|
|
3887
3910
|
*
|
|
3888
|
-
*
|
|
3889
|
-
*
|
|
3890
|
-
*
|
|
3891
|
-
*
|
|
3911
|
+
* `readiness` is the field to report to a user — it collapses status,
|
|
3912
|
+
* capability and routing into the one answer they want: `live` (answering
|
|
3913
|
+
* inbound), `needs_agent`, `needs_carrier_setup`, `setting_up`, `error` or
|
|
3914
|
+
* `disabled`.
|
|
3892
3915
|
*/
|
|
3893
3916
|
public list<ThrowOnError extends boolean = false>(parameters?: {
|
|
3917
|
+
account_id?: string | null;
|
|
3894
3918
|
limit?: number;
|
|
3895
3919
|
offset?: number;
|
|
3896
|
-
}, options?: Options<never, ThrowOnError>): RequestResult<
|
|
3897
|
-
const params = buildClientParams([parameters], [{ args: [
|
|
3898
|
-
|
|
3920
|
+
}, options?: Options<never, ThrowOnError>): RequestResult<TelephonyPhoneNumbersListResults, TelephonyPhoneNumbersListErrors, ThrowOnError, 'data'> {
|
|
3921
|
+
const params = buildClientParams([parameters], [{ args: [
|
|
3922
|
+
{ in: 'query', key: 'account_id' },
|
|
3923
|
+
{ in: 'query', key: 'limit' },
|
|
3924
|
+
{ in: 'query', key: 'offset' }
|
|
3925
|
+
] }]);
|
|
3926
|
+
return (options?.client ?? this.client).get<TelephonyPhoneNumbersListResults, TelephonyPhoneNumbersListErrors, ThrowOnError, 'data'>({
|
|
3899
3927
|
responseStyle: 'data',
|
|
3900
3928
|
security: [{ scheme: 'bearer', type: 'http' }, {
|
|
3901
3929
|
in: 'cookie',
|
|
3902
3930
|
name: 'talqing_session',
|
|
3903
3931
|
type: 'apiKey'
|
|
3904
3932
|
}],
|
|
3905
|
-
url: '/v1/telephony/
|
|
3933
|
+
url: '/v1/telephony/phone-numbers',
|
|
3906
3934
|
...options,
|
|
3907
3935
|
...params
|
|
3908
3936
|
});
|
|
3909
3937
|
}
|
|
3910
3938
|
|
|
3911
3939
|
/**
|
|
3912
|
-
*
|
|
3940
|
+
* Import Phone Numbers
|
|
3913
3941
|
*
|
|
3914
|
-
*
|
|
3942
|
+
* Bring carrier-owned numbers into the workspace, provisioning each one.
|
|
3915
3943
|
*
|
|
3916
|
-
*
|
|
3917
|
-
* `
|
|
3918
|
-
*
|
|
3944
|
+
* Per number, not all-or-nothing: `items` carries one result per requested
|
|
3945
|
+
* E.164, so check every `ok` rather than assuming a 200 means all of them
|
|
3946
|
+
* landed. `provision` defaults to true, which is what makes a number usable.
|
|
3947
|
+
*/
|
|
3948
|
+
public import<ThrowOnError extends boolean = false>(parameters: {
|
|
3949
|
+
importPhoneNumbersRequest: ImportPhoneNumbersRequest;
|
|
3950
|
+
}, options?: Options<never, ThrowOnError>): RequestResult<TelephonyPhoneNumbersImportResults, TelephonyPhoneNumbersImportErrors, ThrowOnError, 'data'> {
|
|
3951
|
+
const params = buildClientParams([parameters], [{ args: [{ key: 'importPhoneNumbersRequest', map: 'body' }] }]);
|
|
3952
|
+
return (options?.client ?? this.client).post<TelephonyPhoneNumbersImportResults, TelephonyPhoneNumbersImportErrors, ThrowOnError, 'data'>({
|
|
3953
|
+
responseStyle: 'data',
|
|
3954
|
+
security: [{ scheme: 'bearer', type: 'http' }, {
|
|
3955
|
+
in: 'cookie',
|
|
3956
|
+
name: 'talqing_session',
|
|
3957
|
+
type: 'apiKey'
|
|
3958
|
+
}],
|
|
3959
|
+
url: '/v1/telephony/phone-numbers/import',
|
|
3960
|
+
...options,
|
|
3961
|
+
...params,
|
|
3962
|
+
headers: {
|
|
3963
|
+
'Content-Type': 'application/json',
|
|
3964
|
+
...options?.headers,
|
|
3965
|
+
...params.headers
|
|
3966
|
+
}
|
|
3967
|
+
});
|
|
3968
|
+
}
|
|
3969
|
+
|
|
3970
|
+
/**
|
|
3971
|
+
* Get Phone Number
|
|
3919
3972
|
*
|
|
3920
|
-
*
|
|
3921
|
-
* next to build the SIP trunk.
|
|
3973
|
+
* Read one phone number: its carrier, capabilities, agent and readiness.
|
|
3922
3974
|
*/
|
|
3923
|
-
public
|
|
3924
|
-
|
|
3925
|
-
}, options?: Options<never, ThrowOnError>): RequestResult<
|
|
3926
|
-
const params = buildClientParams([parameters], [{ args: [{
|
|
3927
|
-
return (options?.client ?? this.client).
|
|
3975
|
+
public get<ThrowOnError extends boolean = false>(parameters: {
|
|
3976
|
+
number_id: string;
|
|
3977
|
+
}, options?: Options<never, ThrowOnError>): RequestResult<TelephonyPhoneNumbersGetResults, TelephonyPhoneNumbersGetErrors, ThrowOnError, 'data'> {
|
|
3978
|
+
const params = buildClientParams([parameters], [{ args: [{ in: 'path', key: 'number_id' }] }]);
|
|
3979
|
+
return (options?.client ?? this.client).get<TelephonyPhoneNumbersGetResults, TelephonyPhoneNumbersGetErrors, ThrowOnError, 'data'>({
|
|
3928
3980
|
responseStyle: 'data',
|
|
3929
3981
|
security: [{ scheme: 'bearer', type: 'http' }, {
|
|
3930
3982
|
in: 'cookie',
|
|
3931
3983
|
name: 'talqing_session',
|
|
3932
3984
|
type: 'apiKey'
|
|
3933
3985
|
}],
|
|
3934
|
-
url: '/v1/telephony/
|
|
3986
|
+
url: '/v1/telephony/phone-numbers/{number_id}',
|
|
3987
|
+
...options,
|
|
3988
|
+
...params
|
|
3989
|
+
});
|
|
3990
|
+
}
|
|
3991
|
+
|
|
3992
|
+
/**
|
|
3993
|
+
* Patch Phone Number
|
|
3994
|
+
*
|
|
3995
|
+
* Relabel a number, change what it may do, or take it out of service.
|
|
3996
|
+
*
|
|
3997
|
+
* `can_inbound` and `can_outbound` gate the directions it will carry.
|
|
3998
|
+
* `status` accepts `disabled`, which tears down its LiveKit routing, and
|
|
3999
|
+
* `pending`, which re-opens a disabled number so it can be provisioned again.
|
|
4000
|
+
*/
|
|
4001
|
+
public update<ThrowOnError extends boolean = false>(parameters: {
|
|
4002
|
+
number_id: string;
|
|
4003
|
+
patchPhoneNumberRequest: PatchPhoneNumberRequest;
|
|
4004
|
+
}, options?: Options<never, ThrowOnError>): RequestResult<TelephonyPhoneNumbersUpdateResults, TelephonyPhoneNumbersUpdateErrors, ThrowOnError, 'data'> {
|
|
4005
|
+
const params = buildClientParams([parameters], [{ args: [{ in: 'path', key: 'number_id' }, { key: 'patchPhoneNumberRequest', map: 'body' }] }]);
|
|
4006
|
+
return (options?.client ?? this.client).patch<TelephonyPhoneNumbersUpdateResults, TelephonyPhoneNumbersUpdateErrors, ThrowOnError, 'data'>({
|
|
4007
|
+
responseStyle: 'data',
|
|
4008
|
+
security: [{ scheme: 'bearer', type: 'http' }, {
|
|
4009
|
+
in: 'cookie',
|
|
4010
|
+
name: 'talqing_session',
|
|
4011
|
+
type: 'apiKey'
|
|
4012
|
+
}],
|
|
4013
|
+
url: '/v1/telephony/phone-numbers/{number_id}',
|
|
3935
4014
|
...options,
|
|
3936
4015
|
...params,
|
|
3937
4016
|
headers: {
|
|
@@ -3943,81 +4022,203 @@ export class Accounts extends HeyApiClient {
|
|
|
3943
4022
|
}
|
|
3944
4023
|
|
|
3945
4024
|
/**
|
|
3946
|
-
*
|
|
4025
|
+
* Assign Phone Number
|
|
3947
4026
|
*
|
|
3948
|
-
*
|
|
4027
|
+
* Put an agent on a number so it answers incoming calls.
|
|
3949
4028
|
*
|
|
3950
|
-
*
|
|
3951
|
-
*
|
|
4029
|
+
* The agent must be **published** and on the `voice` or `video` channel, and
|
|
4030
|
+
* the number active, inbound-capable and on a ready carrier account — each is
|
|
4031
|
+
* refused with the reason. One agent per number; assigning again replaces the
|
|
4032
|
+
* previous one. Republishing the agent later needs no reassignment.
|
|
3952
4033
|
*/
|
|
3953
|
-
public
|
|
3954
|
-
|
|
3955
|
-
|
|
3956
|
-
|
|
3957
|
-
|
|
4034
|
+
public assign<ThrowOnError extends boolean = false>(parameters: {
|
|
4035
|
+
number_id: string;
|
|
4036
|
+
assignPhoneNumberRequest: AssignPhoneNumberRequest;
|
|
4037
|
+
}, options?: Options<never, ThrowOnError>): RequestResult<TelephonyPhoneNumbersAssignResults, TelephonyPhoneNumbersAssignErrors, ThrowOnError, 'data'> {
|
|
4038
|
+
const params = buildClientParams([parameters], [{ args: [{ in: 'path', key: 'number_id' }, { key: 'assignPhoneNumberRequest', map: 'body' }] }]);
|
|
4039
|
+
return (options?.client ?? this.client).post<TelephonyPhoneNumbersAssignResults, TelephonyPhoneNumbersAssignErrors, ThrowOnError, 'data'>({
|
|
3958
4040
|
responseStyle: 'data',
|
|
3959
4041
|
security: [{ scheme: 'bearer', type: 'http' }, {
|
|
3960
4042
|
in: 'cookie',
|
|
3961
4043
|
name: 'talqing_session',
|
|
3962
4044
|
type: 'apiKey'
|
|
3963
4045
|
}],
|
|
3964
|
-
url: '/v1/telephony/
|
|
4046
|
+
url: '/v1/telephony/phone-numbers/{number_id}/assign',
|
|
4047
|
+
...options,
|
|
4048
|
+
...params,
|
|
4049
|
+
headers: {
|
|
4050
|
+
'Content-Type': 'application/json',
|
|
4051
|
+
...options?.headers,
|
|
4052
|
+
...params.headers
|
|
4053
|
+
}
|
|
4054
|
+
});
|
|
4055
|
+
}
|
|
4056
|
+
|
|
4057
|
+
/**
|
|
4058
|
+
* Provision Phone Number
|
|
4059
|
+
*
|
|
4060
|
+
* Wire a number up at the carrier and in LiveKit so it can carry calls.
|
|
4061
|
+
*
|
|
4062
|
+
* `import_phone_numbers` already does this unless it was called with
|
|
4063
|
+
* `provision: false`; use this to retry a number left in `error`, or to bring
|
|
4064
|
+
* one back after re-enabling it.
|
|
4065
|
+
*/
|
|
4066
|
+
public provision<ThrowOnError extends boolean = false>(parameters: {
|
|
4067
|
+
number_id: string;
|
|
4068
|
+
}, options?: Options<never, ThrowOnError>): RequestResult<TelephonyPhoneNumbersProvisionResults, TelephonyPhoneNumbersProvisionErrors, ThrowOnError, 'data'> {
|
|
4069
|
+
const params = buildClientParams([parameters], [{ args: [{ in: 'path', key: 'number_id' }] }]);
|
|
4070
|
+
return (options?.client ?? this.client).post<TelephonyPhoneNumbersProvisionResults, TelephonyPhoneNumbersProvisionErrors, ThrowOnError, 'data'>({
|
|
4071
|
+
responseStyle: 'data',
|
|
4072
|
+
security: [{ scheme: 'bearer', type: 'http' }, {
|
|
4073
|
+
in: 'cookie',
|
|
4074
|
+
name: 'talqing_session',
|
|
4075
|
+
type: 'apiKey'
|
|
4076
|
+
}],
|
|
4077
|
+
url: '/v1/telephony/phone-numbers/{number_id}/provision',
|
|
3965
4078
|
...options,
|
|
3966
4079
|
...params
|
|
3967
4080
|
});
|
|
3968
4081
|
}
|
|
3969
4082
|
|
|
3970
4083
|
/**
|
|
3971
|
-
*
|
|
4084
|
+
* Unassign Phone Number
|
|
3972
4085
|
*
|
|
3973
|
-
*
|
|
4086
|
+
* Take the agent off a number, so incoming calls are no longer answered.
|
|
3974
4087
|
*
|
|
3975
|
-
*
|
|
3976
|
-
*
|
|
3977
|
-
* `user_confirmable` cannot be checked over any API; it is done in the
|
|
3978
|
-
* carrier's console and confirmed with `patch_telephony_account`.
|
|
4088
|
+
* The number stays provisioned and can still place outbound calls; its
|
|
4089
|
+
* readiness drops to `needs_agent`.
|
|
3979
4090
|
*/
|
|
3980
|
-
public
|
|
3981
|
-
|
|
3982
|
-
}, options?: Options<never, ThrowOnError>): RequestResult<
|
|
3983
|
-
const params = buildClientParams([parameters], [{ args: [{ in: 'path', key: '
|
|
3984
|
-
return (options?.client ?? this.client).
|
|
4091
|
+
public unassign<ThrowOnError extends boolean = false>(parameters: {
|
|
4092
|
+
number_id: string;
|
|
4093
|
+
}, options?: Options<never, ThrowOnError>): RequestResult<TelephonyPhoneNumbersUnassignResults, TelephonyPhoneNumbersUnassignErrors, ThrowOnError, 'data'> {
|
|
4094
|
+
const params = buildClientParams([parameters], [{ args: [{ in: 'path', key: 'number_id' }] }]);
|
|
4095
|
+
return (options?.client ?? this.client).post<TelephonyPhoneNumbersUnassignResults, TelephonyPhoneNumbersUnassignErrors, ThrowOnError, 'data'>({
|
|
3985
4096
|
responseStyle: 'data',
|
|
3986
4097
|
security: [{ scheme: 'bearer', type: 'http' }, {
|
|
3987
4098
|
in: 'cookie',
|
|
3988
4099
|
name: 'talqing_session',
|
|
3989
4100
|
type: 'apiKey'
|
|
3990
4101
|
}],
|
|
3991
|
-
url: '/v1/telephony/
|
|
4102
|
+
url: '/v1/telephony/phone-numbers/{number_id}/unassign',
|
|
3992
4103
|
...options,
|
|
3993
4104
|
...params
|
|
3994
4105
|
});
|
|
3995
4106
|
}
|
|
4107
|
+
}
|
|
4108
|
+
|
|
4109
|
+
export class Providers extends HeyApiClient {
|
|
4110
|
+
/**
|
|
4111
|
+
* List Telephony Providers
|
|
4112
|
+
*
|
|
4113
|
+
* List the telephony carriers an account can be connected to.
|
|
4114
|
+
*
|
|
4115
|
+
* `account_info_keys`, `credential_keys` and `setup_fields` state exactly what
|
|
4116
|
+
* connecting each carrier needs — read this before `create_telephony_account`
|
|
4117
|
+
* rather than guessing field names. Entries with `implemented: false` have no
|
|
4118
|
+
* adapter yet and cannot be used.
|
|
4119
|
+
*/
|
|
4120
|
+
public list<ThrowOnError extends boolean = false>(parameters?: {
|
|
4121
|
+
limit?: number;
|
|
4122
|
+
offset?: number;
|
|
4123
|
+
}, options?: Options<never, ThrowOnError>): RequestResult<TelephonyProvidersListResults, TelephonyProvidersListErrors, ThrowOnError, 'data'> {
|
|
4124
|
+
const params = buildClientParams([parameters], [{ args: [{ in: 'query', key: 'limit' }, { in: 'query', key: 'offset' }] }]);
|
|
4125
|
+
return (options?.client ?? this.client).get<TelephonyProvidersListResults, TelephonyProvidersListErrors, ThrowOnError, 'data'>({
|
|
4126
|
+
responseStyle: 'data',
|
|
4127
|
+
security: [{ scheme: 'bearer', type: 'http' }, {
|
|
4128
|
+
in: 'cookie',
|
|
4129
|
+
name: 'talqing_session',
|
|
4130
|
+
type: 'apiKey'
|
|
4131
|
+
}],
|
|
4132
|
+
url: '/v1/telephony/providers',
|
|
4133
|
+
...options,
|
|
4134
|
+
...params
|
|
4135
|
+
});
|
|
4136
|
+
}
|
|
4137
|
+
}
|
|
4138
|
+
|
|
4139
|
+
export class Telephony extends HeyApiClient {
|
|
4140
|
+
private _streams?: Streams;
|
|
4141
|
+
get streams(): Streams {
|
|
4142
|
+
return this._streams ??= new Streams({ client: this.client });
|
|
4143
|
+
}
|
|
4144
|
+
|
|
4145
|
+
private _accounts?: Accounts;
|
|
4146
|
+
get accounts(): Accounts {
|
|
4147
|
+
return this._accounts ??= new Accounts({ client: this.client });
|
|
4148
|
+
}
|
|
3996
4149
|
|
|
4150
|
+
private _phoneNumbers?: PhoneNumbers;
|
|
4151
|
+
get phoneNumbers(): PhoneNumbers {
|
|
4152
|
+
return this._phoneNumbers ??= new PhoneNumbers({ client: this.client });
|
|
4153
|
+
}
|
|
4154
|
+
|
|
4155
|
+
private _providers?: Providers;
|
|
4156
|
+
get providers(): Providers {
|
|
4157
|
+
return this._providers ??= new Providers({ client: this.client });
|
|
4158
|
+
}
|
|
4159
|
+
}
|
|
4160
|
+
|
|
4161
|
+
export class Runs extends HeyApiClient {
|
|
3997
4162
|
/**
|
|
3998
|
-
*
|
|
4163
|
+
* List Task Runs
|
|
3999
4164
|
*
|
|
4000
|
-
*
|
|
4165
|
+
* This task's runs, newest first, each with its output, trace and cost.
|
|
4001
4166
|
*
|
|
4002
|
-
*
|
|
4003
|
-
*
|
|
4004
|
-
* the user says they have finished the carrier-console steps — no API can
|
|
4005
|
-
* verify that work, and inbound calling on this account's numbers stays
|
|
4006
|
-
* blocked until they confirm.
|
|
4167
|
+
* `task_version` says which published definition each one ran, and is null for
|
|
4168
|
+
* a run of the draft.
|
|
4007
4169
|
*/
|
|
4008
|
-
public
|
|
4009
|
-
|
|
4010
|
-
|
|
4011
|
-
|
|
4012
|
-
|
|
4013
|
-
|
|
4170
|
+
public list<ThrowOnError extends boolean = false>(parameters: {
|
|
4171
|
+
task_id: string;
|
|
4172
|
+
limit?: number;
|
|
4173
|
+
offset?: number;
|
|
4174
|
+
}, options?: Options<never, ThrowOnError>): RequestResult<TasksRunsListResults, TasksRunsListErrors, ThrowOnError, 'data'> {
|
|
4175
|
+
const params = buildClientParams([parameters], [{ args: [
|
|
4176
|
+
{ in: 'path', key: 'task_id' },
|
|
4177
|
+
{ in: 'query', key: 'limit' },
|
|
4178
|
+
{ in: 'query', key: 'offset' }
|
|
4179
|
+
] }]);
|
|
4180
|
+
return (options?.client ?? this.client).get<TasksRunsListResults, TasksRunsListErrors, ThrowOnError, 'data'>({
|
|
4014
4181
|
responseStyle: 'data',
|
|
4015
4182
|
security: [{ scheme: 'bearer', type: 'http' }, {
|
|
4016
4183
|
in: 'cookie',
|
|
4017
4184
|
name: 'talqing_session',
|
|
4018
4185
|
type: 'apiKey'
|
|
4019
4186
|
}],
|
|
4020
|
-
url: '/v1/
|
|
4187
|
+
url: '/v1/tasks/{task_id}/runs',
|
|
4188
|
+
...options,
|
|
4189
|
+
...params
|
|
4190
|
+
});
|
|
4191
|
+
}
|
|
4192
|
+
|
|
4193
|
+
/**
|
|
4194
|
+
* Run Task
|
|
4195
|
+
*
|
|
4196
|
+
* Run the task once with the variables you supply, and wait for the result.
|
|
4197
|
+
*
|
|
4198
|
+
* **This executes for real**: the tools call your endpoints with your secrets,
|
|
4199
|
+
* the MCP servers spend your credits, and the model spends your tokens. A task
|
|
4200
|
+
* that books a slot, charges a card or sends a message will do so.
|
|
4201
|
+
*
|
|
4202
|
+
* Runs the published version unless `version` names another one, or `"draft"`
|
|
4203
|
+
* to run the unpublished config. `vars` must match what that version declares
|
|
4204
|
+
* — an unknown name is refused rather than dropped. The response is the whole
|
|
4205
|
+
* run: the structured `output`, a `trace` of every tool call, the steps used
|
|
4206
|
+
* and what the tokens cost. On failure `error.type` says whose problem it is.
|
|
4207
|
+
* Secrets are redacted.
|
|
4208
|
+
*/
|
|
4209
|
+
public create<ThrowOnError extends boolean = false>(parameters: {
|
|
4210
|
+
task_id: string;
|
|
4211
|
+
runTaskRequest: RunTaskRequest;
|
|
4212
|
+
}, options?: Options<never, ThrowOnError>): RequestResult<TasksRunsCreateResults, TasksRunsCreateErrors, ThrowOnError, 'data'> {
|
|
4213
|
+
const params = buildClientParams([parameters], [{ args: [{ in: 'path', key: 'task_id' }, { key: 'runTaskRequest', map: 'body' }] }]);
|
|
4214
|
+
return (options?.client ?? this.client).post<TasksRunsCreateResults, TasksRunsCreateErrors, ThrowOnError, 'data'>({
|
|
4215
|
+
responseStyle: 'data',
|
|
4216
|
+
security: [{ scheme: 'bearer', type: 'http' }, {
|
|
4217
|
+
in: 'cookie',
|
|
4218
|
+
name: 'talqing_session',
|
|
4219
|
+
type: 'apiKey'
|
|
4220
|
+
}],
|
|
4221
|
+
url: '/v1/tasks/{task_id}/runs',
|
|
4021
4222
|
...options,
|
|
4022
4223
|
...params,
|
|
4023
4224
|
headers: {
|
|
@@ -4029,120 +4230,143 @@ export class Accounts extends HeyApiClient {
|
|
|
4029
4230
|
}
|
|
4030
4231
|
|
|
4031
4232
|
/**
|
|
4032
|
-
*
|
|
4233
|
+
* Get Task Run
|
|
4033
4234
|
*
|
|
4034
|
-
*
|
|
4235
|
+
* One run in full: what it produced, every tool it called on the way, and
|
|
4236
|
+
* what it cost.
|
|
4035
4237
|
*
|
|
4036
|
-
*
|
|
4037
|
-
*
|
|
4038
|
-
* the
|
|
4039
|
-
* `status` and `setup_steps` say what is working and what is left.
|
|
4238
|
+
* This is what answers "why did it write that" for a caller holding one run id
|
|
4239
|
+
* — an email batch's review table links each drafted row here. Secret values
|
|
4240
|
+
* are redacted from the trace, and a trace that was cut reports it.
|
|
4040
4241
|
*/
|
|
4041
|
-
public
|
|
4042
|
-
|
|
4043
|
-
|
|
4044
|
-
|
|
4045
|
-
|
|
4242
|
+
public get<ThrowOnError extends boolean = false>(parameters: {
|
|
4243
|
+
task_id: string;
|
|
4244
|
+
run_id: string;
|
|
4245
|
+
}, options?: Options<never, ThrowOnError>): RequestResult<TasksRunsGetResults, TasksRunsGetErrors, ThrowOnError, 'data'> {
|
|
4246
|
+
const params = buildClientParams([parameters], [{ args: [{ in: 'path', key: 'task_id' }, { in: 'path', key: 'run_id' }] }]);
|
|
4247
|
+
return (options?.client ?? this.client).get<TasksRunsGetResults, TasksRunsGetErrors, ThrowOnError, 'data'>({
|
|
4248
|
+
responseStyle: 'data',
|
|
4249
|
+
security: [{ scheme: 'bearer', type: 'http' }, {
|
|
4250
|
+
in: 'cookie',
|
|
4251
|
+
name: 'talqing_session',
|
|
4252
|
+
type: 'apiKey'
|
|
4253
|
+
}],
|
|
4254
|
+
url: '/v1/tasks/{task_id}/runs/{run_id}',
|
|
4255
|
+
...options,
|
|
4256
|
+
...params
|
|
4257
|
+
});
|
|
4258
|
+
}
|
|
4259
|
+
}
|
|
4260
|
+
|
|
4261
|
+
export class Versions2 extends HeyApiClient {
|
|
4262
|
+
/**
|
|
4263
|
+
* Get Task Version
|
|
4264
|
+
*
|
|
4265
|
+
* Fetch what one published version of a task actually contains.
|
|
4266
|
+
*
|
|
4267
|
+
* `get_task` lists the versions and when each was published; this returns the
|
|
4268
|
+
* frozen definition itself — prompt, model, output fields and the tool
|
|
4269
|
+
* versions it pinned, exactly as they were at that publish.
|
|
4270
|
+
*/
|
|
4271
|
+
public get<ThrowOnError extends boolean = false>(parameters: {
|
|
4272
|
+
task_id: string;
|
|
4273
|
+
version: number;
|
|
4274
|
+
}, options?: Options<never, ThrowOnError>): RequestResult<TasksVersionsGetResults, TasksVersionsGetErrors, ThrowOnError, 'data'> {
|
|
4275
|
+
const params = buildClientParams([parameters], [{ args: [{ in: 'path', key: 'task_id' }, { in: 'path', key: 'version' }] }]);
|
|
4276
|
+
return (options?.client ?? this.client).get<TasksVersionsGetResults, TasksVersionsGetErrors, ThrowOnError, 'data'>({
|
|
4046
4277
|
responseStyle: 'data',
|
|
4047
4278
|
security: [{ scheme: 'bearer', type: 'http' }, {
|
|
4048
4279
|
in: 'cookie',
|
|
4049
4280
|
name: 'talqing_session',
|
|
4050
4281
|
type: 'apiKey'
|
|
4051
4282
|
}],
|
|
4052
|
-
url: '/v1/
|
|
4283
|
+
url: '/v1/tasks/{task_id}/versions/{version}',
|
|
4053
4284
|
...options,
|
|
4054
4285
|
...params
|
|
4055
4286
|
});
|
|
4056
4287
|
}
|
|
4057
4288
|
|
|
4058
4289
|
/**
|
|
4059
|
-
*
|
|
4290
|
+
* Rollback Task Version
|
|
4060
4291
|
*
|
|
4061
|
-
*
|
|
4292
|
+
* Put an earlier published version of a task back into production.
|
|
4062
4293
|
*
|
|
4063
|
-
*
|
|
4064
|
-
*
|
|
4065
|
-
*
|
|
4294
|
+
* That version becomes live **immediately** and **replaces the current draft**,
|
|
4295
|
+
* so any unpublished edits are lost. No new version is created. The restored
|
|
4296
|
+
* draft tracks each tool's latest published version, not the ones this version
|
|
4297
|
+
* pinned.
|
|
4066
4298
|
*/
|
|
4067
|
-
public
|
|
4068
|
-
|
|
4069
|
-
|
|
4070
|
-
|
|
4071
|
-
|
|
4072
|
-
|
|
4073
|
-
{ in: 'path', key: 'account_id' },
|
|
4074
|
-
{ in: 'query', key: 'limit' },
|
|
4075
|
-
{ in: 'query', key: 'offset' }
|
|
4076
|
-
] }]);
|
|
4077
|
-
return (options?.client ?? this.client).get<TelephonyAccountsRemoteNumbersResults, TelephonyAccountsRemoteNumbersErrors, ThrowOnError, 'data'>({
|
|
4299
|
+
public rollback<ThrowOnError extends boolean = false>(parameters: {
|
|
4300
|
+
task_id: string;
|
|
4301
|
+
version: number;
|
|
4302
|
+
}, options?: Options<never, ThrowOnError>): RequestResult<TasksVersionsRollbackResults, TasksVersionsRollbackErrors, ThrowOnError, 'data'> {
|
|
4303
|
+
const params = buildClientParams([parameters], [{ args: [{ in: 'path', key: 'task_id' }, { in: 'path', key: 'version' }] }]);
|
|
4304
|
+
return (options?.client ?? this.client).post<TasksVersionsRollbackResults, TasksVersionsRollbackErrors, ThrowOnError, 'data'>({
|
|
4078
4305
|
responseStyle: 'data',
|
|
4079
4306
|
security: [{ scheme: 'bearer', type: 'http' }, {
|
|
4080
4307
|
in: 'cookie',
|
|
4081
4308
|
name: 'talqing_session',
|
|
4082
4309
|
type: 'apiKey'
|
|
4083
4310
|
}],
|
|
4084
|
-
url: '/v1/
|
|
4311
|
+
url: '/v1/tasks/{task_id}/versions/{version}/rollback',
|
|
4085
4312
|
...options,
|
|
4086
4313
|
...params
|
|
4087
4314
|
});
|
|
4088
4315
|
}
|
|
4089
4316
|
}
|
|
4090
4317
|
|
|
4091
|
-
export class
|
|
4318
|
+
export class Tasks2 extends HeyApiClient {
|
|
4092
4319
|
/**
|
|
4093
|
-
* List
|
|
4320
|
+
* List Tasks
|
|
4094
4321
|
*
|
|
4095
|
-
* List the workspace's
|
|
4322
|
+
* List the workspace's agent tasks.
|
|
4096
4323
|
*
|
|
4097
|
-
*
|
|
4098
|
-
*
|
|
4099
|
-
*
|
|
4100
|
-
* `
|
|
4324
|
+
* A task is an agent nobody talks to: a prompt, one LLM, tools and MCP
|
|
4325
|
+
* servers, the variables it takes as input, and the typed result it must
|
|
4326
|
+
* produce. Each item carries the full draft config, the published version
|
|
4327
|
+
* number (null while it has never been published), and `last_run`.
|
|
4101
4328
|
*/
|
|
4102
4329
|
public list<ThrowOnError extends boolean = false>(parameters?: {
|
|
4103
|
-
account_id?: string | null;
|
|
4104
4330
|
limit?: number;
|
|
4105
4331
|
offset?: number;
|
|
4106
|
-
}, options?: Options<never, ThrowOnError>): RequestResult<
|
|
4107
|
-
const params = buildClientParams([parameters], [{ args: [
|
|
4108
|
-
|
|
4109
|
-
{ in: 'query', key: 'limit' },
|
|
4110
|
-
{ in: 'query', key: 'offset' }
|
|
4111
|
-
] }]);
|
|
4112
|
-
return (options?.client ?? this.client).get<TelephonyPhoneNumbersListResults, TelephonyPhoneNumbersListErrors, ThrowOnError, 'data'>({
|
|
4332
|
+
}, options?: Options<never, ThrowOnError>): RequestResult<TasksListResults, TasksListErrors, ThrowOnError, 'data'> {
|
|
4333
|
+
const params = buildClientParams([parameters], [{ args: [{ in: 'query', key: 'limit' }, { in: 'query', key: 'offset' }] }]);
|
|
4334
|
+
return (options?.client ?? this.client).get<TasksListResults, TasksListErrors, ThrowOnError, 'data'>({
|
|
4113
4335
|
responseStyle: 'data',
|
|
4114
4336
|
security: [{ scheme: 'bearer', type: 'http' }, {
|
|
4115
4337
|
in: 'cookie',
|
|
4116
4338
|
name: 'talqing_session',
|
|
4117
4339
|
type: 'apiKey'
|
|
4118
4340
|
}],
|
|
4119
|
-
url: '/v1/
|
|
4341
|
+
url: '/v1/tasks',
|
|
4120
4342
|
...options,
|
|
4121
4343
|
...params
|
|
4122
4344
|
});
|
|
4123
4345
|
}
|
|
4124
4346
|
|
|
4125
4347
|
/**
|
|
4126
|
-
*
|
|
4348
|
+
* Create Task
|
|
4127
4349
|
*
|
|
4128
|
-
*
|
|
4350
|
+
* Create an agent task: an agent nobody talks to, which takes named inputs
|
|
4351
|
+
* and returns a typed result.
|
|
4129
4352
|
*
|
|
4130
|
-
*
|
|
4131
|
-
*
|
|
4132
|
-
*
|
|
4353
|
+
* `output` is what makes this a task rather than a chat agent — declare the
|
|
4354
|
+
* fields the model must produce and it is given a `submit_result` tool built
|
|
4355
|
+
* from them. `vars` are its inputs, read as `{{vars.name}}`. The task starts
|
|
4356
|
+
* unpublished; publish it before running it.
|
|
4133
4357
|
*/
|
|
4134
|
-
public
|
|
4135
|
-
|
|
4136
|
-
}, options?: Options<never, ThrowOnError>): RequestResult<
|
|
4137
|
-
const params = buildClientParams([parameters], [{ args: [{ key: '
|
|
4138
|
-
return (options?.client ?? this.client).post<
|
|
4358
|
+
public create<ThrowOnError extends boolean = false>(parameters: {
|
|
4359
|
+
createTaskRequest: CreateTaskRequest;
|
|
4360
|
+
}, options?: Options<never, ThrowOnError>): RequestResult<TasksCreateResults, TasksCreateErrors, ThrowOnError, 'data'> {
|
|
4361
|
+
const params = buildClientParams([parameters], [{ args: [{ key: 'createTaskRequest', map: 'body' }] }]);
|
|
4362
|
+
return (options?.client ?? this.client).post<TasksCreateResults, TasksCreateErrors, ThrowOnError, 'data'>({
|
|
4139
4363
|
responseStyle: 'data',
|
|
4140
4364
|
security: [{ scheme: 'bearer', type: 'http' }, {
|
|
4141
4365
|
in: 'cookie',
|
|
4142
4366
|
name: 'talqing_session',
|
|
4143
4367
|
type: 'apiKey'
|
|
4144
4368
|
}],
|
|
4145
|
-
url: '/v1/
|
|
4369
|
+
url: '/v1/tasks',
|
|
4146
4370
|
...options,
|
|
4147
4371
|
...params,
|
|
4148
4372
|
headers: {
|
|
@@ -4154,82 +4378,72 @@ export class PhoneNumbers extends HeyApiClient {
|
|
|
4154
4378
|
}
|
|
4155
4379
|
|
|
4156
4380
|
/**
|
|
4157
|
-
*
|
|
4381
|
+
* Delete Task
|
|
4158
4382
|
*
|
|
4159
|
-
*
|
|
4383
|
+
* Delete a task and its published versions. Its runs survive, still named
|
|
4384
|
+
* after it.
|
|
4160
4385
|
*/
|
|
4161
|
-
public
|
|
4162
|
-
|
|
4163
|
-
}, options?: Options<never, ThrowOnError>): RequestResult<
|
|
4164
|
-
const params = buildClientParams([parameters], [{ args: [{ in: 'path', key: '
|
|
4165
|
-
return (options?.client ?? this.client).
|
|
4386
|
+
public delete<ThrowOnError extends boolean = false>(parameters: {
|
|
4387
|
+
task_id: string;
|
|
4388
|
+
}, options?: Options<never, ThrowOnError>): RequestResult<TasksDeleteResults, TasksDeleteErrors, ThrowOnError, 'data'> {
|
|
4389
|
+
const params = buildClientParams([parameters], [{ args: [{ in: 'path', key: 'task_id' }] }]);
|
|
4390
|
+
return (options?.client ?? this.client).delete<TasksDeleteResults, TasksDeleteErrors, ThrowOnError, 'data'>({
|
|
4166
4391
|
responseStyle: 'data',
|
|
4167
4392
|
security: [{ scheme: 'bearer', type: 'http' }, {
|
|
4168
4393
|
in: 'cookie',
|
|
4169
4394
|
name: 'talqing_session',
|
|
4170
4395
|
type: 'apiKey'
|
|
4171
4396
|
}],
|
|
4172
|
-
url: '/v1/
|
|
4397
|
+
url: '/v1/tasks/{task_id}',
|
|
4173
4398
|
...options,
|
|
4174
4399
|
...params
|
|
4175
4400
|
});
|
|
4176
4401
|
}
|
|
4177
4402
|
|
|
4178
4403
|
/**
|
|
4179
|
-
*
|
|
4180
|
-
*
|
|
4181
|
-
* Relabel a number, change what it may do, or take it out of service.
|
|
4404
|
+
* Get Task
|
|
4182
4405
|
*
|
|
4183
|
-
*
|
|
4184
|
-
* `status` accepts `disabled`, which tears down its LiveKit routing, and
|
|
4185
|
-
* `pending`, which re-opens a disabled number so it can be provisioned again.
|
|
4406
|
+
* Fetch one task's draft config, published version, history and last run.
|
|
4186
4407
|
*/
|
|
4187
|
-
public
|
|
4188
|
-
|
|
4189
|
-
|
|
4190
|
-
|
|
4191
|
-
|
|
4192
|
-
return (options?.client ?? this.client).patch<TelephonyPhoneNumbersUpdateResults, TelephonyPhoneNumbersUpdateErrors, ThrowOnError, 'data'>({
|
|
4408
|
+
public get<ThrowOnError extends boolean = false>(parameters: {
|
|
4409
|
+
task_id: string;
|
|
4410
|
+
}, options?: Options<never, ThrowOnError>): RequestResult<TasksGetResults, TasksGetErrors, ThrowOnError, 'data'> {
|
|
4411
|
+
const params = buildClientParams([parameters], [{ args: [{ in: 'path', key: 'task_id' }] }]);
|
|
4412
|
+
return (options?.client ?? this.client).get<TasksGetResults, TasksGetErrors, ThrowOnError, 'data'>({
|
|
4193
4413
|
responseStyle: 'data',
|
|
4194
4414
|
security: [{ scheme: 'bearer', type: 'http' }, {
|
|
4195
4415
|
in: 'cookie',
|
|
4196
4416
|
name: 'talqing_session',
|
|
4197
4417
|
type: 'apiKey'
|
|
4198
4418
|
}],
|
|
4199
|
-
url: '/v1/
|
|
4419
|
+
url: '/v1/tasks/{task_id}',
|
|
4200
4420
|
...options,
|
|
4201
|
-
...params
|
|
4202
|
-
headers: {
|
|
4203
|
-
'Content-Type': 'application/json',
|
|
4204
|
-
...options?.headers,
|
|
4205
|
-
...params.headers
|
|
4206
|
-
}
|
|
4421
|
+
...params
|
|
4207
4422
|
});
|
|
4208
4423
|
}
|
|
4209
4424
|
|
|
4210
4425
|
/**
|
|
4211
|
-
*
|
|
4426
|
+
* Update Task
|
|
4212
4427
|
*
|
|
4213
|
-
*
|
|
4428
|
+
* Replace the task's draft config with the one supplied.
|
|
4214
4429
|
*
|
|
4215
|
-
* The
|
|
4216
|
-
* the
|
|
4217
|
-
*
|
|
4218
|
-
* previous one. Republishing the agent later needs no reassignment.
|
|
4430
|
+
* The whole config is sent, so include every field you mean to keep. Writes
|
|
4431
|
+
* land on the draft only — runs and email batches keep using the published
|
|
4432
|
+
* version until you publish again.
|
|
4219
4433
|
*/
|
|
4220
|
-
public
|
|
4221
|
-
|
|
4222
|
-
|
|
4223
|
-
}, options?: Options<never, ThrowOnError>): RequestResult<
|
|
4224
|
-
const params = buildClientParams([parameters], [{ args: [{ in: 'path', key: '
|
|
4225
|
-
return (options?.client ?? this.client).
|
|
4434
|
+
public update<ThrowOnError extends boolean = false>(parameters: {
|
|
4435
|
+
task_id: string;
|
|
4436
|
+
patchTaskRequest: PatchTaskRequest;
|
|
4437
|
+
}, options?: Options<never, ThrowOnError>): RequestResult<TasksUpdateResults, TasksUpdateErrors, ThrowOnError, 'data'> {
|
|
4438
|
+
const params = buildClientParams([parameters], [{ args: [{ in: 'path', key: 'task_id' }, { key: 'patchTaskRequest', map: 'body' }] }]);
|
|
4439
|
+
return (options?.client ?? this.client).patch<TasksUpdateResults, TasksUpdateErrors, ThrowOnError, 'data'>({
|
|
4226
4440
|
responseStyle: 'data',
|
|
4227
4441
|
security: [{ scheme: 'bearer', type: 'http' }, {
|
|
4228
4442
|
in: 'cookie',
|
|
4229
4443
|
name: 'talqing_session',
|
|
4230
4444
|
type: 'apiKey'
|
|
4231
4445
|
}],
|
|
4232
|
-
url: '/v1/
|
|
4446
|
+
url: '/v1/tasks/{task_id}',
|
|
4233
4447
|
...options,
|
|
4234
4448
|
...params,
|
|
4235
4449
|
headers: {
|
|
@@ -4241,101 +4455,66 @@ export class PhoneNumbers extends HeyApiClient {
|
|
|
4241
4455
|
}
|
|
4242
4456
|
|
|
4243
4457
|
/**
|
|
4244
|
-
*
|
|
4458
|
+
* Publish Task
|
|
4245
4459
|
*
|
|
4246
|
-
*
|
|
4460
|
+
* Freeze the current draft as a new immutable version and make it live.
|
|
4247
4461
|
*
|
|
4248
|
-
*
|
|
4249
|
-
*
|
|
4250
|
-
*
|
|
4462
|
+
* Validation must pass. Publishing pins every attached tool to the tool
|
|
4463
|
+
* version live right now, so republishing a tool does not change this task
|
|
4464
|
+
* until the task is published again.
|
|
4251
4465
|
*/
|
|
4252
|
-
public
|
|
4253
|
-
|
|
4254
|
-
}, options?: Options<never, ThrowOnError>): RequestResult<
|
|
4255
|
-
const params = buildClientParams([parameters], [{ args: [{ in: 'path', key: '
|
|
4256
|
-
return (options?.client ?? this.client).post<
|
|
4466
|
+
public publish<ThrowOnError extends boolean = false>(parameters: {
|
|
4467
|
+
task_id: string;
|
|
4468
|
+
}, options?: Options<never, ThrowOnError>): RequestResult<TasksPublishResults, TasksPublishErrors, ThrowOnError, 'data'> {
|
|
4469
|
+
const params = buildClientParams([parameters], [{ args: [{ in: 'path', key: 'task_id' }] }]);
|
|
4470
|
+
return (options?.client ?? this.client).post<TasksPublishResults, TasksPublishErrors, ThrowOnError, 'data'>({
|
|
4257
4471
|
responseStyle: 'data',
|
|
4258
4472
|
security: [{ scheme: 'bearer', type: 'http' }, {
|
|
4259
4473
|
in: 'cookie',
|
|
4260
4474
|
name: 'talqing_session',
|
|
4261
4475
|
type: 'apiKey'
|
|
4262
4476
|
}],
|
|
4263
|
-
url: '/v1/
|
|
4477
|
+
url: '/v1/tasks/{task_id}/publish',
|
|
4264
4478
|
...options,
|
|
4265
4479
|
...params
|
|
4266
4480
|
});
|
|
4267
4481
|
}
|
|
4268
4482
|
|
|
4269
4483
|
/**
|
|
4270
|
-
*
|
|
4271
|
-
*
|
|
4272
|
-
* Take the agent off a number, so incoming calls are no longer answered.
|
|
4273
|
-
*
|
|
4274
|
-
* The number stays provisioned and can still place outbound calls; its
|
|
4275
|
-
* readiness drops to `needs_agent`.
|
|
4276
|
-
*/
|
|
4277
|
-
public unassign<ThrowOnError extends boolean = false>(parameters: {
|
|
4278
|
-
number_id: string;
|
|
4279
|
-
}, options?: Options<never, ThrowOnError>): RequestResult<TelephonyPhoneNumbersUnassignResults, TelephonyPhoneNumbersUnassignErrors, ThrowOnError, 'data'> {
|
|
4280
|
-
const params = buildClientParams([parameters], [{ args: [{ in: 'path', key: 'number_id' }] }]);
|
|
4281
|
-
return (options?.client ?? this.client).post<TelephonyPhoneNumbersUnassignResults, TelephonyPhoneNumbersUnassignErrors, ThrowOnError, 'data'>({
|
|
4282
|
-
responseStyle: 'data',
|
|
4283
|
-
security: [{ scheme: 'bearer', type: 'http' }, {
|
|
4284
|
-
in: 'cookie',
|
|
4285
|
-
name: 'talqing_session',
|
|
4286
|
-
type: 'apiKey'
|
|
4287
|
-
}],
|
|
4288
|
-
url: '/v1/telephony/phone-numbers/{number_id}/unassign',
|
|
4289
|
-
...options,
|
|
4290
|
-
...params
|
|
4291
|
-
});
|
|
4292
|
-
}
|
|
4293
|
-
}
|
|
4294
|
-
|
|
4295
|
-
export class Providers extends HeyApiClient {
|
|
4296
|
-
/**
|
|
4297
|
-
* List Telephony Providers
|
|
4484
|
+
* Validate Task
|
|
4298
4485
|
*
|
|
4299
|
-
*
|
|
4486
|
+
* Run publish-grade validation on the draft without publishing it.
|
|
4300
4487
|
*
|
|
4301
|
-
*
|
|
4302
|
-
*
|
|
4303
|
-
*
|
|
4304
|
-
*
|
|
4488
|
+
* Covers everything a draft write checks plus what publishing adds: a
|
|
4489
|
+
* workspace API key for the model, at least one output field, the operation
|
|
4490
|
+
* trees of the attached tools, and the email batches already drafting with
|
|
4491
|
+
* this task. Returns errors (blocking) and warnings (advisory).
|
|
4305
4492
|
*/
|
|
4306
|
-
public
|
|
4307
|
-
|
|
4308
|
-
|
|
4309
|
-
|
|
4310
|
-
|
|
4311
|
-
return (options?.client ?? this.client).get<TelephonyProvidersListResults, TelephonyProvidersListErrors, ThrowOnError, 'data'>({
|
|
4493
|
+
public validate<ThrowOnError extends boolean = false>(parameters: {
|
|
4494
|
+
task_id: string;
|
|
4495
|
+
}, options?: Options<never, ThrowOnError>): RequestResult<TasksValidateResults, TasksValidateErrors, ThrowOnError, 'data'> {
|
|
4496
|
+
const params = buildClientParams([parameters], [{ args: [{ in: 'path', key: 'task_id' }] }]);
|
|
4497
|
+
return (options?.client ?? this.client).post<TasksValidateResults, TasksValidateErrors, ThrowOnError, 'data'>({
|
|
4312
4498
|
responseStyle: 'data',
|
|
4313
4499
|
security: [{ scheme: 'bearer', type: 'http' }, {
|
|
4314
4500
|
in: 'cookie',
|
|
4315
4501
|
name: 'talqing_session',
|
|
4316
4502
|
type: 'apiKey'
|
|
4317
4503
|
}],
|
|
4318
|
-
url: '/v1/
|
|
4504
|
+
url: '/v1/tasks/{task_id}/validate',
|
|
4319
4505
|
...options,
|
|
4320
4506
|
...params
|
|
4321
4507
|
});
|
|
4322
4508
|
}
|
|
4323
|
-
}
|
|
4324
|
-
|
|
4325
|
-
export class Telephony extends HeyApiClient {
|
|
4326
|
-
private _accounts?: Accounts;
|
|
4327
|
-
get accounts(): Accounts {
|
|
4328
|
-
return this._accounts ??= new Accounts({ client: this.client });
|
|
4329
|
-
}
|
|
4330
4509
|
|
|
4331
|
-
private
|
|
4332
|
-
get
|
|
4333
|
-
return this.
|
|
4510
|
+
private _runs?: Runs;
|
|
4511
|
+
get runs(): Runs {
|
|
4512
|
+
return this._runs ??= new Runs({ client: this.client });
|
|
4334
4513
|
}
|
|
4335
4514
|
|
|
4336
|
-
private
|
|
4337
|
-
get
|
|
4338
|
-
return this.
|
|
4515
|
+
private _versions?: Versions2;
|
|
4516
|
+
get versions(): Versions2 {
|
|
4517
|
+
return this._versions ??= new Versions2({ client: this.client });
|
|
4339
4518
|
}
|
|
4340
4519
|
}
|
|
4341
4520
|
|
|
@@ -4856,7 +5035,9 @@ export class TalqingApi extends HeyApiClient {
|
|
|
4856
5035
|
* Liveness probe: `200` once this process is serving. Unauthenticated.
|
|
4857
5036
|
*
|
|
4858
5037
|
* It answers for the API process, not its dependencies — a `200` here does
|
|
4859
|
-
* not promise Postgres, Redis or LiveKit are reachable.
|
|
5038
|
+
* not promise Postgres, Redis or LiveKit are reachable. The one thing it
|
|
5039
|
+
* does report is `model_registry`, because that snapshot lives in this
|
|
5040
|
+
* process's memory and nothing else can see how old it is.
|
|
4860
5041
|
*/
|
|
4861
5042
|
public health<ThrowOnError extends boolean = false>(options?: Options<never, ThrowOnError>): RequestResult<HealthResults, HealthErrors, ThrowOnError, 'data'> {
|
|
4862
5043
|
return (options?.client ?? this.client).get<HealthResults, HealthErrors, ThrowOnError, 'data'>({
|
|
@@ -4931,16 +5112,16 @@ export class TalqingApi extends HeyApiClient {
|
|
|
4931
5112
|
return this._secrets ??= new Secrets({ client: this.client });
|
|
4932
5113
|
}
|
|
4933
5114
|
|
|
4934
|
-
private _tasks?: Tasks2;
|
|
4935
|
-
get tasks(): Tasks2 {
|
|
4936
|
-
return this._tasks ??= new Tasks2({ client: this.client });
|
|
4937
|
-
}
|
|
4938
|
-
|
|
4939
5115
|
private _telephony?: Telephony;
|
|
4940
5116
|
get telephony(): Telephony {
|
|
4941
5117
|
return this._telephony ??= new Telephony({ client: this.client });
|
|
4942
5118
|
}
|
|
4943
5119
|
|
|
5120
|
+
private _tasks?: Tasks2;
|
|
5121
|
+
get tasks(): Tasks2 {
|
|
5122
|
+
return this._tasks ??= new Tasks2({ client: this.client });
|
|
5123
|
+
}
|
|
5124
|
+
|
|
4944
5125
|
private _tools?: Tools2;
|
|
4945
5126
|
get tools(): Tools2 {
|
|
4946
5127
|
return this._tools ??= new Tools2({ client: this.client });
|