@talqing/sdk 0.4.0 → 0.4.1
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 +199 -70
- package/dist/cjs/gen/sdk.gen.d.ts.map +1 -1
- package/dist/cjs/gen/sdk.gen.js +319 -73
- package/dist/cjs/gen/sdk.gen.js.map +1 -1
- package/dist/cjs/gen/types.gen.d.ts +1102 -198
- package/dist/cjs/gen/types.gen.d.ts.map +1 -1
- package/dist/cjs/vocabulary.d.ts +2 -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 +199 -70
- package/dist/esm/gen/sdk.gen.d.ts.map +1 -1
- package/dist/esm/gen/sdk.gen.js +314 -70
- package/dist/esm/gen/sdk.gen.js.map +1 -1
- package/dist/esm/gen/types.gen.d.ts +1102 -198
- package/dist/esm/gen/types.gen.d.ts.map +1 -1
- package/dist/esm/vocabulary.d.ts +2 -1
- package/dist/esm/vocabulary.d.ts.map +1 -1
- package/package.json +2 -2
- package/src/gen/index.ts +1 -1
- package/src/gen/sdk.gen.ts +368 -80
- package/src/gen/types.gen.ts +1150 -187
- package/src/vocabulary.ts +2 -0
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { type Client, type ClientMeta, type Options as Options2, type RequestResult, type ServerSentEventsResult, type TDataShape } from './client/index.js';
|
|
2
|
-
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, ConversationsEventsResult, ConversationsEventsResults, ConversationsGetErrors, ConversationsGetResults, ConversationsItemsListErrors, ConversationsItemsListResults, ConversationsListErrors, ConversationsListResults, ConversationsMessagesCreateErrors, ConversationsMessagesCreateResults, ConversationsSessionsListErrors, ConversationsSessionsListResults, ConversationsSnapshotErrors, ConversationsSnapshotResults, ConversationsUpdateErrors, ConversationsUpdateResults, CopilotAgentsSendErrors, CopilotAgentsSendResults, CopilotAgentsStreamResult, CopilotAgentsStreamResults, CopilotKnowledgeSendErrors, CopilotKnowledgeSendResults, CopilotKnowledgeStreamResult, CopilotKnowledgeStreamResults, CopilotTasksSendErrors, CopilotTasksSendResults, CopilotTasksStreamResult, CopilotTasksStreamResults, CopilotToolsSendErrors, CopilotToolsSendResults, CopilotToolsStreamResult, CopilotToolsStreamResults, CreateAgentRequest, CreateCallBatchRequest, CreateEmailBatchRequest, CreateIntegrationRequest, CreateIntegrationTriggerRequest, CreateKBRequest, CreateSecretRequest, CreateTaskRequest, CreateTelephonyAccountRequest, CreateTextConversationRequest, CreateToolRequest, CreateWebhookRequest, CreditCheckoutRequest, EmailBatchesCancelErrors, EmailBatchesCancelResults, EmailBatchesCreateErrors, EmailBatchesCreateResults, EmailBatchesGetErrors, EmailBatchesGetResults, EmailBatchesListErrors, EmailBatchesListResults, EmailBatchesPauseErrors, EmailBatchesPauseResults, EmailBatchesRecipientsListErrors, EmailBatchesRecipientsListResults,
|
|
2
|
+
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, ConversationsEventsResult, ConversationsEventsResults, ConversationsGetErrors, ConversationsGetResults, ConversationsItemsListErrors, ConversationsItemsListResults, ConversationsListErrors, ConversationsListResults, ConversationsMessagesCreateErrors, ConversationsMessagesCreateResults, ConversationsSessionsListErrors, ConversationsSessionsListResults, ConversationsSnapshotErrors, ConversationsSnapshotResults, ConversationsUpdateErrors, ConversationsUpdateResults, CopilotAgentsSendErrors, CopilotAgentsSendResults, CopilotAgentsStreamResult, CopilotAgentsStreamResults, CopilotKnowledgeSendErrors, CopilotKnowledgeSendResults, CopilotKnowledgeStreamResult, CopilotKnowledgeStreamResults, CopilotTasksSendErrors, CopilotTasksSendResults, CopilotTasksStreamResult, CopilotTasksStreamResults, CopilotToolsSendErrors, CopilotToolsSendResults, 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, 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';
|
|
3
3
|
export type Options<TData extends TDataShape = TDataShape, ThrowOnError extends boolean = boolean, TResponse = unknown> = Options2<TData, ThrowOnError, TResponse> & {
|
|
4
4
|
/**
|
|
5
5
|
* You can provide a client instance returned by `createClient()` instead of
|
|
@@ -998,6 +998,22 @@ export declare class Recipients2 extends HeyApiClient {
|
|
|
998
998
|
recipient_id: string;
|
|
999
999
|
patchEmailRecipientRequest: PatchEmailRecipientRequest;
|
|
1000
1000
|
}, options?: Options<never, ThrowOnError>): RequestResult<EmailBatchesRecipientsUpdateResults, EmailBatchesRecipientsUpdateErrors, ThrowOnError, 'data'>;
|
|
1001
|
+
/**
|
|
1002
|
+
* Redraft Email Batch Recipients
|
|
1003
|
+
*
|
|
1004
|
+
* Draft rows again from scratch. **Each one runs the task and is billed again.**
|
|
1005
|
+
*
|
|
1006
|
+
* `selection` is `failed` (drafting failed), `stale_version` (drafted by an
|
|
1007
|
+
* older published version of the task), `not_sent`, or `all` — which names
|
|
1008
|
+
* every row it refuses. Rows already sent or queued are never redrafted.
|
|
1009
|
+
*
|
|
1010
|
+
* This revives a batch that had finished drafting, and a person's edited cells
|
|
1011
|
+
* survive unless you pass `clear_overrides`.
|
|
1012
|
+
*/
|
|
1013
|
+
redraft<ThrowOnError extends boolean = false>(parameters: {
|
|
1014
|
+
batch_id: string;
|
|
1015
|
+
redraftRequest: RedraftRequest;
|
|
1016
|
+
}, options?: Options<never, ThrowOnError>): RequestResult<EmailBatchesRecipientsRedraftResults, EmailBatchesRecipientsRedraftErrors, ThrowOnError, 'data'>;
|
|
1001
1017
|
/**
|
|
1002
1018
|
* Restore Email Batch Recipients
|
|
1003
1019
|
*
|
|
@@ -1008,50 +1024,105 @@ export declare class Recipients2 extends HeyApiClient {
|
|
|
1008
1024
|
selectRecipientsRequest: SelectRecipientsRequest;
|
|
1009
1025
|
}, options?: Options<never, ThrowOnError>): RequestResult<EmailBatchesRecipientsRestoreResults, EmailBatchesRecipientsRestoreErrors, ThrowOnError, 'data'>;
|
|
1010
1026
|
/**
|
|
1011
|
-
*
|
|
1027
|
+
* Skip Email Batch Recipients
|
|
1012
1028
|
*
|
|
1013
|
-
*
|
|
1029
|
+
* Take drafted rows out of consideration. Reversible with `restore`.
|
|
1014
1030
|
*
|
|
1015
|
-
* `selection: "all_eligible"
|
|
1016
|
-
*
|
|
1017
|
-
*
|
|
1018
|
-
* alternative would be telling you that twelve failed rows are unrecoverable
|
|
1019
|
-
* because the other 4 988 finished first.
|
|
1031
|
+
* Takes either `recipient_ids` or `selection: "all_eligible"`, which here means
|
|
1032
|
+
* every row that has a draft. The reversible verbs keep that shorthand while
|
|
1033
|
+
* `send` does not, because the rule is about irreversibility rather than bulk.
|
|
1020
1034
|
*/
|
|
1021
|
-
|
|
1035
|
+
skip<ThrowOnError extends boolean = false>(parameters: {
|
|
1022
1036
|
batch_id: string;
|
|
1023
1037
|
selectRecipientsRequest: SelectRecipientsRequest;
|
|
1024
|
-
}, options?: Options<never, ThrowOnError>): RequestResult<
|
|
1038
|
+
}, options?: Options<never, ThrowOnError>): RequestResult<EmailBatchesRecipientsSkipResults, EmailBatchesRecipientsSkipErrors, ThrowOnError, 'data'>;
|
|
1039
|
+
}
|
|
1040
|
+
export declare class Sends extends HeyApiClient {
|
|
1025
1041
|
/**
|
|
1026
|
-
*
|
|
1042
|
+
* List Email Sends
|
|
1027
1043
|
*
|
|
1028
|
-
*
|
|
1044
|
+
* Every send on this batch, newest first, with its counts and its schedule.
|
|
1045
|
+
*/
|
|
1046
|
+
list<ThrowOnError extends boolean = false>(parameters: {
|
|
1047
|
+
batch_id: string;
|
|
1048
|
+
limit?: number;
|
|
1049
|
+
offset?: number;
|
|
1050
|
+
}, options?: Options<never, ThrowOnError>): RequestResult<EmailBatchesSendsListResults, EmailBatchesSendsListErrors, ThrowOnError, 'data'>;
|
|
1051
|
+
/**
|
|
1052
|
+
* Create Email Send
|
|
1053
|
+
*
|
|
1054
|
+
* Send these rows. **This mails real people and cannot be undone.**
|
|
1029
1055
|
*
|
|
1030
|
-
*
|
|
1031
|
-
*
|
|
1032
|
-
*
|
|
1033
|
-
* `patch_email_batch_recipient` and try again.
|
|
1056
|
+
* Name `recipient_ids`, or pass `selection: "all_drafts"` for every reviewed
|
|
1057
|
+
* draft. A row whose `to`, `subject` or `body` does not resolve comes back in
|
|
1058
|
+
* `rejected` and stays a draft; fix it with `patch_email_batch_recipient`.
|
|
1034
1059
|
*
|
|
1035
|
-
*
|
|
1036
|
-
*
|
|
1060
|
+
* The send is a row you can steer: `start_at` schedules it, `window` holds it
|
|
1061
|
+
* to business hours, `send_gap_seconds` paces it and `send_daily_cap` bounds
|
|
1062
|
+
* how many leave per day. Everything omitted comes from the batch. Cancel it
|
|
1063
|
+
* and every unsent row comes back as a draft.
|
|
1037
1064
|
*/
|
|
1038
|
-
|
|
1065
|
+
create<ThrowOnError extends boolean = false>(parameters: {
|
|
1039
1066
|
batch_id: string;
|
|
1040
|
-
|
|
1041
|
-
}, options?: Options<never, ThrowOnError>): RequestResult<
|
|
1067
|
+
createEmailSendRequest: CreateEmailSendRequest;
|
|
1068
|
+
}, options?: Options<never, ThrowOnError>): RequestResult<EmailBatchesSendsCreateResults, EmailBatchesSendsCreateErrors, ThrowOnError, 'data'>;
|
|
1042
1069
|
/**
|
|
1043
|
-
*
|
|
1070
|
+
* Get Email Send
|
|
1044
1071
|
*
|
|
1045
|
-
*
|
|
1072
|
+
* One send: where its rows are, and when it next does something.
|
|
1046
1073
|
*
|
|
1047
|
-
*
|
|
1048
|
-
*
|
|
1049
|
-
* `send` does not, because the rule is about irreversibility rather than bulk.
|
|
1074
|
+
* `next_send_at` covers all three reasons a send waits — a start time, a closed
|
|
1075
|
+
* window, and a daily cap already spent.
|
|
1050
1076
|
*/
|
|
1051
|
-
|
|
1077
|
+
get<ThrowOnError extends boolean = false>(parameters: {
|
|
1052
1078
|
batch_id: string;
|
|
1053
|
-
|
|
1054
|
-
}, options?: Options<never, ThrowOnError>): RequestResult<
|
|
1079
|
+
send_id: string;
|
|
1080
|
+
}, options?: Options<never, ThrowOnError>): RequestResult<EmailBatchesSendsGetResults, EmailBatchesSendsGetErrors, ThrowOnError, 'data'>;
|
|
1081
|
+
/**
|
|
1082
|
+
* Patch Email Send
|
|
1083
|
+
*
|
|
1084
|
+
* Re-steer one send: its pace, its hours, its daily cap, its start time.
|
|
1085
|
+
*
|
|
1086
|
+
* Never its sender, and never which rows it holds — to change that, cancel it
|
|
1087
|
+
* and create another. `start_at` moves only before the send has begun.
|
|
1088
|
+
*/
|
|
1089
|
+
update<ThrowOnError extends boolean = false>(parameters: {
|
|
1090
|
+
batch_id: string;
|
|
1091
|
+
send_id: string;
|
|
1092
|
+
patchEmailSendRequest: PatchEmailSendRequest;
|
|
1093
|
+
}, options?: Options<never, ThrowOnError>): RequestResult<EmailBatchesSendsUpdateResults, EmailBatchesSendsUpdateErrors, ThrowOnError, 'data'>;
|
|
1094
|
+
/**
|
|
1095
|
+
* Cancel Email Send
|
|
1096
|
+
*
|
|
1097
|
+
* Stop this send, and give every row it has not sent back as a draft.
|
|
1098
|
+
*
|
|
1099
|
+
* Not a destructive action: the drafts come back exactly as they were, ready
|
|
1100
|
+
* for another send. It is also the only way to change what a scheduled send
|
|
1101
|
+
* contains — a send's rows are fixed once it exists.
|
|
1102
|
+
*/
|
|
1103
|
+
cancel<ThrowOnError extends boolean = false>(parameters: {
|
|
1104
|
+
batch_id: string;
|
|
1105
|
+
send_id: string;
|
|
1106
|
+
}, options?: Options<never, ThrowOnError>): RequestResult<EmailBatchesSendsCancelResults, EmailBatchesSendsCancelErrors, ThrowOnError, 'data'>;
|
|
1107
|
+
/**
|
|
1108
|
+
* Pause Email Send
|
|
1109
|
+
*
|
|
1110
|
+
* Stop sending. It takes hold on the next email, and nothing is lost —
|
|
1111
|
+
* the rows stay queued for whenever you resume.
|
|
1112
|
+
*/
|
|
1113
|
+
pause<ThrowOnError extends boolean = false>(parameters: {
|
|
1114
|
+
batch_id: string;
|
|
1115
|
+
send_id: string;
|
|
1116
|
+
}, options?: Options<never, ThrowOnError>): RequestResult<EmailBatchesSendsPauseResults, EmailBatchesSendsPauseErrors, ThrowOnError, 'data'>;
|
|
1117
|
+
/**
|
|
1118
|
+
* Resume Email Send
|
|
1119
|
+
*
|
|
1120
|
+
* Undo a pause and carry on from where it stopped.
|
|
1121
|
+
*/
|
|
1122
|
+
resume<ThrowOnError extends boolean = false>(parameters: {
|
|
1123
|
+
batch_id: string;
|
|
1124
|
+
send_id: string;
|
|
1125
|
+
}, options?: Options<never, ThrowOnError>): RequestResult<EmailBatchesSendsResumeResults, EmailBatchesSendsResumeErrors, ThrowOnError, 'data'>;
|
|
1055
1126
|
}
|
|
1056
1127
|
export declare class Batches2 extends HeyApiClient {
|
|
1057
1128
|
/**
|
|
@@ -1080,13 +1151,16 @@ export declare class Batches2 extends HeyApiClient {
|
|
|
1080
1151
|
* scraped contacts — and this runs on your account under your agreement.
|
|
1081
1152
|
*
|
|
1082
1153
|
* **Nothing is sent that a person has not selected.** Creating a batch only
|
|
1083
|
-
* starts drafting; sending is a separate call
|
|
1154
|
+
* starts drafting; sending is a separate call that creates a send you can
|
|
1155
|
+
* schedule, pace, pause and cancel.
|
|
1084
1156
|
*
|
|
1085
|
-
* **Every row runs
|
|
1086
|
-
*
|
|
1157
|
+
* **Every row runs the task's CURRENT published version**, re-read every pass,
|
|
1158
|
+
* so publishing a better prompt mid-batch changes every row drafted after it.
|
|
1087
1159
|
*
|
|
1088
1160
|
* `field_map` points `to`, `subject` and `body` at a column of your list or at
|
|
1089
|
-
* a field the task produces.
|
|
1161
|
+
* a field the task produces. `window` is when email may LEAVE, inherited by
|
|
1162
|
+
* every send; drafting is not restricted by hours. An invalid batch is a 400
|
|
1163
|
+
* listing every problem.
|
|
1090
1164
|
*
|
|
1091
1165
|
* There is no spend cap: every row runs the task and is billed, so a 5 000-row
|
|
1092
1166
|
* batch doing research costs 5 000 task runs whether or not anything is sent.
|
|
@@ -1099,8 +1173,8 @@ export declare class Batches2 extends HeyApiClient {
|
|
|
1099
1173
|
*
|
|
1100
1174
|
* One batch: its policy, its per-status counts and what drafting has cost.
|
|
1101
1175
|
*
|
|
1102
|
-
*
|
|
1103
|
-
*
|
|
1176
|
+
* `drafted_versions` says which published version of the task wrote how many
|
|
1177
|
+
* rows, and `sent_today` how much of `send_daily_cap` is left today.
|
|
1104
1178
|
*/
|
|
1105
1179
|
get<ThrowOnError extends boolean = false>(parameters: {
|
|
1106
1180
|
batch_id: string;
|
|
@@ -1110,10 +1184,12 @@ export declare class Batches2 extends HeyApiClient {
|
|
|
1110
1184
|
*
|
|
1111
1185
|
* Edit a batch's policy. The next drafting pass reads the new row.
|
|
1112
1186
|
*
|
|
1113
|
-
* Pacing and the
|
|
1114
|
-
*
|
|
1115
|
-
*
|
|
1116
|
-
*
|
|
1187
|
+
* Pacing, the window and the daily cap are editable at any time; the sending
|
|
1188
|
+
* half is the DEFAULT for the next send, and a send already created carries its
|
|
1189
|
+
* own copy. The sender, the body format and the field map freeze once the batch
|
|
1190
|
+
* has sent anything — changing them then would make the rows already delivered
|
|
1191
|
+
* no longer describe what they were sent as. `start_at` moves only while the
|
|
1192
|
+
* batch is still scheduled.
|
|
1117
1193
|
*/
|
|
1118
1194
|
update<ThrowOnError extends boolean = false>(parameters: {
|
|
1119
1195
|
batch_id: string;
|
|
@@ -1122,12 +1198,12 @@ export declare class Batches2 extends HeyApiClient {
|
|
|
1122
1198
|
/**
|
|
1123
1199
|
* Cancel Email Batch
|
|
1124
1200
|
*
|
|
1125
|
-
* Stop drafting for good.
|
|
1126
|
-
*
|
|
1201
|
+
* Stop drafting for good. A batch cannot be deleted, because it is the
|
|
1202
|
+
* record of what was sent to whom.
|
|
1127
1203
|
*
|
|
1128
|
-
* Rows already drafted are **not** touched
|
|
1129
|
-
* drafts already produced are still worth reviewing and
|
|
1130
|
-
* reached report as `canceled`.
|
|
1204
|
+
* Rows already drafted are **not** touched and neither is any send: cancelling
|
|
1205
|
+
* stops drafting, and drafts already produced are still worth reviewing and
|
|
1206
|
+
* sending. Rows never reached report as `canceled`.
|
|
1131
1207
|
*/
|
|
1132
1208
|
cancel<ThrowOnError extends boolean = false>(parameters: {
|
|
1133
1209
|
batch_id: string;
|
|
@@ -1153,6 +1229,8 @@ export declare class Batches2 extends HeyApiClient {
|
|
|
1153
1229
|
}, options?: Options<never, ThrowOnError>): RequestResult<EmailBatchesResumeResults, EmailBatchesResumeErrors, ThrowOnError, 'data'>;
|
|
1154
1230
|
private _recipients?;
|
|
1155
1231
|
get recipients(): Recipients2;
|
|
1232
|
+
private _sends?;
|
|
1233
|
+
get sends(): Sends;
|
|
1156
1234
|
}
|
|
1157
1235
|
export declare class Senders extends HeyApiClient {
|
|
1158
1236
|
/**
|
|
@@ -1597,8 +1675,8 @@ export declare class Runs extends HeyApiClient {
|
|
|
1597
1675
|
*
|
|
1598
1676
|
* This task's runs, newest first, each with its output, trace and cost.
|
|
1599
1677
|
*
|
|
1600
|
-
*
|
|
1601
|
-
*
|
|
1678
|
+
* `task_version` says which published definition each one ran, and is null for
|
|
1679
|
+
* a run of the draft.
|
|
1602
1680
|
*/
|
|
1603
1681
|
list<ThrowOnError extends boolean = false>(parameters: {
|
|
1604
1682
|
task_id: string;
|
|
@@ -1614,10 +1692,12 @@ export declare class Runs extends HeyApiClient {
|
|
|
1614
1692
|
* the MCP servers spend your credits, and the model spends your tokens. A task
|
|
1615
1693
|
* that books a slot, charges a card or sends a message will do so.
|
|
1616
1694
|
*
|
|
1617
|
-
*
|
|
1618
|
-
*
|
|
1619
|
-
*
|
|
1620
|
-
*
|
|
1695
|
+
* Runs the published version unless `version` names another one, or `"draft"`
|
|
1696
|
+
* to run the unpublished config. `vars` must match what that version declares
|
|
1697
|
+
* — an unknown name is refused rather than dropped. The response is the whole
|
|
1698
|
+
* run: the structured `output`, a `trace` of every tool call, the steps used
|
|
1699
|
+
* and what the tokens cost. On failure `error.type` says whose problem it is.
|
|
1700
|
+
* Secrets are redacted.
|
|
1621
1701
|
*/
|
|
1622
1702
|
create<ThrowOnError extends boolean = false>(parameters: {
|
|
1623
1703
|
task_id: string;
|
|
@@ -1638,6 +1718,35 @@ export declare class Runs extends HeyApiClient {
|
|
|
1638
1718
|
run_id: string;
|
|
1639
1719
|
}, options?: Options<never, ThrowOnError>): RequestResult<TasksRunsGetResults, TasksRunsGetErrors, ThrowOnError, 'data'>;
|
|
1640
1720
|
}
|
|
1721
|
+
export declare class Versions2 extends HeyApiClient {
|
|
1722
|
+
/**
|
|
1723
|
+
* Get Task Version
|
|
1724
|
+
*
|
|
1725
|
+
* Fetch what one published version of a task actually contains.
|
|
1726
|
+
*
|
|
1727
|
+
* `get_task` lists the versions and when each was published; this returns the
|
|
1728
|
+
* frozen definition itself — prompt, model, output fields and the tool
|
|
1729
|
+
* versions it pinned, exactly as they were at that publish.
|
|
1730
|
+
*/
|
|
1731
|
+
get<ThrowOnError extends boolean = false>(parameters: {
|
|
1732
|
+
task_id: string;
|
|
1733
|
+
version: number;
|
|
1734
|
+
}, options?: Options<never, ThrowOnError>): RequestResult<TasksVersionsGetResults, TasksVersionsGetErrors, ThrowOnError, 'data'>;
|
|
1735
|
+
/**
|
|
1736
|
+
* Rollback Task Version
|
|
1737
|
+
*
|
|
1738
|
+
* Put an earlier published version of a task back into production.
|
|
1739
|
+
*
|
|
1740
|
+
* That version becomes live **immediately** and **replaces the current draft**,
|
|
1741
|
+
* so any unpublished edits are lost. No new version is created. The restored
|
|
1742
|
+
* draft tracks each tool's latest published version, not the ones this version
|
|
1743
|
+
* pinned.
|
|
1744
|
+
*/
|
|
1745
|
+
rollback<ThrowOnError extends boolean = false>(parameters: {
|
|
1746
|
+
task_id: string;
|
|
1747
|
+
version: number;
|
|
1748
|
+
}, options?: Options<never, ThrowOnError>): RequestResult<TasksVersionsRollbackResults, TasksVersionsRollbackErrors, ThrowOnError, 'data'>;
|
|
1749
|
+
}
|
|
1641
1750
|
export declare class Tasks2 extends HeyApiClient {
|
|
1642
1751
|
/**
|
|
1643
1752
|
* List Tasks
|
|
@@ -1646,9 +1755,8 @@ export declare class Tasks2 extends HeyApiClient {
|
|
|
1646
1755
|
*
|
|
1647
1756
|
* A task is an agent nobody talks to: a prompt, one LLM, tools and MCP
|
|
1648
1757
|
* servers, the variables it takes as input, and the typed result it must
|
|
1649
|
-
* produce.
|
|
1650
|
-
*
|
|
1651
|
-
* than only in its own history.
|
|
1758
|
+
* produce. Each item carries the full draft config, the published version
|
|
1759
|
+
* number (null while it has never been published), and `last_run`.
|
|
1652
1760
|
*/
|
|
1653
1761
|
list<ThrowOnError extends boolean = false>(parameters?: {
|
|
1654
1762
|
limit?: number;
|
|
@@ -1660,16 +1768,10 @@ export declare class Tasks2 extends HeyApiClient {
|
|
|
1660
1768
|
* Create an agent task: an agent nobody talks to, which takes named inputs
|
|
1661
1769
|
* and returns a typed result.
|
|
1662
1770
|
*
|
|
1663
|
-
* A task has no draft and no publish step: it is valid the moment it saves and
|
|
1664
|
-
* callable immediately. An invalid config is a 400 listing every problem and
|
|
1665
|
-
* nothing is stored.
|
|
1666
|
-
*
|
|
1667
1771
|
* `output` is what makes this a task rather than a chat agent — declare the
|
|
1668
1772
|
* fields the model must produce and it is given a `submit_result` tool built
|
|
1669
|
-
* from them. `vars` are its inputs, read as `{{vars.name}}`.
|
|
1670
|
-
*
|
|
1671
|
-
* `warnings` reports the non-fatal problems. There is no publish screen to
|
|
1672
|
-
* show them on, so read them here.
|
|
1773
|
+
* from them. `vars` are its inputs, read as `{{vars.name}}`. The task starts
|
|
1774
|
+
* unpublished; publish it before running it.
|
|
1673
1775
|
*/
|
|
1674
1776
|
create<ThrowOnError extends boolean = false>(parameters: {
|
|
1675
1777
|
createTaskRequest: CreateTaskRequest;
|
|
@@ -1677,7 +1779,8 @@ export declare class Tasks2 extends HeyApiClient {
|
|
|
1677
1779
|
/**
|
|
1678
1780
|
* Delete Task
|
|
1679
1781
|
*
|
|
1680
|
-
* Delete a task. Its
|
|
1782
|
+
* Delete a task and its published versions. Its runs survive, still named
|
|
1783
|
+
* after it.
|
|
1681
1784
|
*/
|
|
1682
1785
|
delete<ThrowOnError extends boolean = false>(parameters: {
|
|
1683
1786
|
task_id: string;
|
|
@@ -1685,7 +1788,7 @@ export declare class Tasks2 extends HeyApiClient {
|
|
|
1685
1788
|
/**
|
|
1686
1789
|
* Get Task
|
|
1687
1790
|
*
|
|
1688
|
-
* Fetch one task's config
|
|
1791
|
+
* Fetch one task's draft config, published version, history and last run.
|
|
1689
1792
|
*/
|
|
1690
1793
|
get<ThrowOnError extends boolean = false>(parameters: {
|
|
1691
1794
|
task_id: string;
|
|
@@ -1693,19 +1796,45 @@ export declare class Tasks2 extends HeyApiClient {
|
|
|
1693
1796
|
/**
|
|
1694
1797
|
* Update Task
|
|
1695
1798
|
*
|
|
1696
|
-
* Replace
|
|
1799
|
+
* Replace the task's draft config with the one supplied.
|
|
1697
1800
|
*
|
|
1698
|
-
* The whole config is sent, so include every field you mean to keep
|
|
1699
|
-
*
|
|
1700
|
-
*
|
|
1701
|
-
* record of which definition produced an earlier run.
|
|
1801
|
+
* The whole config is sent, so include every field you mean to keep. Writes
|
|
1802
|
+
* land on the draft only — runs and email batches keep using the published
|
|
1803
|
+
* version until you publish again.
|
|
1702
1804
|
*/
|
|
1703
1805
|
update<ThrowOnError extends boolean = false>(parameters: {
|
|
1704
1806
|
task_id: string;
|
|
1705
1807
|
patchTaskRequest: PatchTaskRequest;
|
|
1706
1808
|
}, options?: Options<never, ThrowOnError>): RequestResult<TasksUpdateResults, TasksUpdateErrors, ThrowOnError, 'data'>;
|
|
1809
|
+
/**
|
|
1810
|
+
* Publish Task
|
|
1811
|
+
*
|
|
1812
|
+
* Freeze the current draft as a new immutable version and make it live.
|
|
1813
|
+
*
|
|
1814
|
+
* Validation must pass. Publishing pins every attached tool to the tool
|
|
1815
|
+
* version live right now, so republishing a tool does not change this task
|
|
1816
|
+
* until the task is published again.
|
|
1817
|
+
*/
|
|
1818
|
+
publish<ThrowOnError extends boolean = false>(parameters: {
|
|
1819
|
+
task_id: string;
|
|
1820
|
+
}, options?: Options<never, ThrowOnError>): RequestResult<TasksPublishResults, TasksPublishErrors, ThrowOnError, 'data'>;
|
|
1821
|
+
/**
|
|
1822
|
+
* Validate Task
|
|
1823
|
+
*
|
|
1824
|
+
* Run publish-grade validation on the draft without publishing it.
|
|
1825
|
+
*
|
|
1826
|
+
* Covers everything a draft write checks plus what publishing adds: a
|
|
1827
|
+
* workspace API key for the model, at least one output field, the operation
|
|
1828
|
+
* trees of the attached tools, and the email batches already drafting with
|
|
1829
|
+
* this task. Returns errors (blocking) and warnings (advisory).
|
|
1830
|
+
*/
|
|
1831
|
+
validate<ThrowOnError extends boolean = false>(parameters: {
|
|
1832
|
+
task_id: string;
|
|
1833
|
+
}, options?: Options<never, ThrowOnError>): RequestResult<TasksValidateResults, TasksValidateErrors, ThrowOnError, 'data'>;
|
|
1707
1834
|
private _runs?;
|
|
1708
1835
|
get runs(): Runs;
|
|
1836
|
+
private _versions?;
|
|
1837
|
+
get versions(): Versions2;
|
|
1709
1838
|
}
|
|
1710
1839
|
export declare class Accounts extends HeyApiClient {
|
|
1711
1840
|
/**
|
|
@@ -1915,7 +2044,7 @@ export declare class Telephony extends HeyApiClient {
|
|
|
1915
2044
|
private _providers?;
|
|
1916
2045
|
get providers(): Providers;
|
|
1917
2046
|
}
|
|
1918
|
-
export declare class
|
|
2047
|
+
export declare class Versions3 extends HeyApiClient {
|
|
1919
2048
|
/**
|
|
1920
2049
|
* Get Tool Version
|
|
1921
2050
|
*
|
|
@@ -2047,7 +2176,7 @@ export declare class Tools2 extends HeyApiClient {
|
|
|
2047
2176
|
tool_id: string;
|
|
2048
2177
|
}, options?: Options<never, ThrowOnError>): RequestResult<ToolsValidateResults, ToolsValidateErrors, ThrowOnError, 'data'>;
|
|
2049
2178
|
private _versions?;
|
|
2050
|
-
get versions():
|
|
2179
|
+
get versions(): Versions3;
|
|
2051
2180
|
}
|
|
2052
2181
|
export declare class Webhooks extends HeyApiClient {
|
|
2053
2182
|
/**
|