@talqing/sdk 0.15.2 → 0.16.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 +14 -1
- package/dist/cjs/gen/sdk.gen.d.ts.map +1 -1
- package/dist/cjs/gen/sdk.gen.js +27 -2
- package/dist/cjs/gen/sdk.gen.js.map +1 -1
- package/dist/cjs/gen/types.gen.d.ts +202 -35
- package/dist/cjs/gen/types.gen.d.ts.map +1 -1
- package/dist/cjs/vocabulary.d.ts +2 -0
- 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 +14 -1
- package/dist/esm/gen/sdk.gen.d.ts.map +1 -1
- package/dist/esm/gen/sdk.gen.js +24 -0
- package/dist/esm/gen/sdk.gen.js.map +1 -1
- package/dist/esm/gen/types.gen.d.ts +202 -35
- package/dist/esm/gen/types.gen.d.ts.map +1 -1
- package/dist/esm/vocabulary.d.ts +2 -0
- 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 +31 -1
- package/src/gen/types.gen.ts +210 -36
- package/src/vocabulary.ts +2 -0
|
@@ -747,6 +747,19 @@ export type AssistantStartedEvent = {
|
|
|
747
747
|
*/
|
|
748
748
|
trigger_item_id: string;
|
|
749
749
|
};
|
|
750
|
+
/**
|
|
751
|
+
* AttachmentNotKept
|
|
752
|
+
*
|
|
753
|
+
* A file the person sent that could not be stored.
|
|
754
|
+
*/
|
|
755
|
+
export type AttachmentNotKept = {
|
|
756
|
+
/**
|
|
757
|
+
* Reason
|
|
758
|
+
*
|
|
759
|
+
* Why, as a sentence for a person.
|
|
760
|
+
*/
|
|
761
|
+
reason: string;
|
|
762
|
+
};
|
|
750
763
|
/**
|
|
751
764
|
* AvatarCatalogEntryResponse
|
|
752
765
|
*/
|
|
@@ -1863,9 +1876,11 @@ export type ChatMessageRequest = {
|
|
|
1863
1876
|
*/
|
|
1864
1877
|
client_message_id: string;
|
|
1865
1878
|
/**
|
|
1866
|
-
*
|
|
1879
|
+
* Files
|
|
1880
|
+
*
|
|
1881
|
+
* Any type; photos, PDFs and Word files are read by the agent.
|
|
1867
1882
|
*/
|
|
1868
|
-
|
|
1883
|
+
files?: Array<InboundFile>;
|
|
1869
1884
|
/**
|
|
1870
1885
|
* Message
|
|
1871
1886
|
*/
|
|
@@ -2107,11 +2122,115 @@ export type ConversationActivity = {
|
|
|
2107
2122
|
state: 'running' | 'idle';
|
|
2108
2123
|
};
|
|
2109
2124
|
/**
|
|
2110
|
-
*
|
|
2125
|
+
* ConversationDocument
|
|
2111
2126
|
*
|
|
2112
|
-
*
|
|
2127
|
+
* A PDF or Word file the person sent, and whether the agent could read it.
|
|
2113
2128
|
*/
|
|
2114
|
-
export type
|
|
2129
|
+
export type ConversationDocument = {
|
|
2130
|
+
/**
|
|
2131
|
+
* Bytes
|
|
2132
|
+
*/
|
|
2133
|
+
bytes: number;
|
|
2134
|
+
/**
|
|
2135
|
+
* Filename
|
|
2136
|
+
*/
|
|
2137
|
+
filename: string | null;
|
|
2138
|
+
/**
|
|
2139
|
+
* Id
|
|
2140
|
+
*/
|
|
2141
|
+
id: string;
|
|
2142
|
+
/**
|
|
2143
|
+
* Kind
|
|
2144
|
+
*/
|
|
2145
|
+
kind?: 'document';
|
|
2146
|
+
/**
|
|
2147
|
+
* Mime Type
|
|
2148
|
+
*/
|
|
2149
|
+
mime_type: string;
|
|
2150
|
+
/**
|
|
2151
|
+
* Pages
|
|
2152
|
+
*
|
|
2153
|
+
* A PDF's page count; null for Word files.
|
|
2154
|
+
*/
|
|
2155
|
+
pages: number | null;
|
|
2156
|
+
/**
|
|
2157
|
+
* Status
|
|
2158
|
+
*
|
|
2159
|
+
* `pending` until the agent's next turn reads it.
|
|
2160
|
+
*/
|
|
2161
|
+
status: 'pending' | 'read' | 'unreadable';
|
|
2162
|
+
/**
|
|
2163
|
+
* Unreadable Reason
|
|
2164
|
+
*
|
|
2165
|
+
* Why the agent could not read it.
|
|
2166
|
+
*/
|
|
2167
|
+
unreadable_reason: string | null;
|
|
2168
|
+
/**
|
|
2169
|
+
* Url
|
|
2170
|
+
*
|
|
2171
|
+
* Signed download link; valid until `url_expires_at`.
|
|
2172
|
+
*/
|
|
2173
|
+
url: string;
|
|
2174
|
+
/**
|
|
2175
|
+
* Url Expires At
|
|
2176
|
+
*/
|
|
2177
|
+
url_expires_at: string;
|
|
2178
|
+
};
|
|
2179
|
+
/**
|
|
2180
|
+
* ConversationFile
|
|
2181
|
+
*
|
|
2182
|
+
* Any other file the person sent, stored for you; the agent cannot open it.
|
|
2183
|
+
*/
|
|
2184
|
+
export type ConversationFile = {
|
|
2185
|
+
/**
|
|
2186
|
+
* Bytes
|
|
2187
|
+
*/
|
|
2188
|
+
bytes: number;
|
|
2189
|
+
/**
|
|
2190
|
+
* Extension
|
|
2191
|
+
*
|
|
2192
|
+
* The type read from its bytes, e.g. `xlsx`; `bin` if unknown.
|
|
2193
|
+
*/
|
|
2194
|
+
extension: string;
|
|
2195
|
+
/**
|
|
2196
|
+
* Filename
|
|
2197
|
+
*/
|
|
2198
|
+
filename: string | null;
|
|
2199
|
+
/**
|
|
2200
|
+
* Id
|
|
2201
|
+
*/
|
|
2202
|
+
id: string;
|
|
2203
|
+
/**
|
|
2204
|
+
* Kind
|
|
2205
|
+
*/
|
|
2206
|
+
kind?: 'file';
|
|
2207
|
+
/**
|
|
2208
|
+
* Mime Type
|
|
2209
|
+
*/
|
|
2210
|
+
mime_type: string;
|
|
2211
|
+
/**
|
|
2212
|
+
* Playable
|
|
2213
|
+
*
|
|
2214
|
+
* Set when `url` plays in an `<audio>` or `<video>` element.
|
|
2215
|
+
*/
|
|
2216
|
+
playable: 'audio' | 'video' | null;
|
|
2217
|
+
/**
|
|
2218
|
+
* Url
|
|
2219
|
+
*
|
|
2220
|
+
* Signed link; valid until `url_expires_at`.
|
|
2221
|
+
*/
|
|
2222
|
+
url: string;
|
|
2223
|
+
/**
|
|
2224
|
+
* Url Expires At
|
|
2225
|
+
*/
|
|
2226
|
+
url_expires_at: string;
|
|
2227
|
+
};
|
|
2228
|
+
/**
|
|
2229
|
+
* ConversationImage
|
|
2230
|
+
*
|
|
2231
|
+
* A photo the person sent, with a short-lived link to it.
|
|
2232
|
+
*/
|
|
2233
|
+
export type ConversationImage = {
|
|
2115
2234
|
/**
|
|
2116
2235
|
* Bytes
|
|
2117
2236
|
*/
|
|
@@ -2138,6 +2257,8 @@ export type ConversationAttachment = {
|
|
|
2138
2257
|
mime_type: string;
|
|
2139
2258
|
/**
|
|
2140
2259
|
* Url
|
|
2260
|
+
*
|
|
2261
|
+
* Signed; valid until `url_expires_at`.
|
|
2141
2262
|
*/
|
|
2142
2263
|
url: string;
|
|
2143
2264
|
/**
|
|
@@ -2164,7 +2285,13 @@ export type ConversationItemResponse = {
|
|
|
2164
2285
|
/**
|
|
2165
2286
|
* Attachments
|
|
2166
2287
|
*/
|
|
2167
|
-
attachments: Array<
|
|
2288
|
+
attachments: Array<ConversationImage | ConversationDocument | ConversationFile>;
|
|
2289
|
+
/**
|
|
2290
|
+
* Attachments Not Kept
|
|
2291
|
+
*
|
|
2292
|
+
* Files the person sent that could not be stored.
|
|
2293
|
+
*/
|
|
2294
|
+
attachments_not_kept: Array<AttachmentNotKept>;
|
|
2168
2295
|
/**
|
|
2169
2296
|
* Who at your business posted this.
|
|
2170
2297
|
*/
|
|
@@ -2212,12 +2339,6 @@ export type ConversationItemResponse = {
|
|
|
2212
2339
|
* Idempotency Key
|
|
2213
2340
|
*/
|
|
2214
2341
|
idempotency_key: string | null;
|
|
2215
|
-
/**
|
|
2216
|
-
* Images Not Kept
|
|
2217
|
-
*
|
|
2218
|
-
* Images the person sent that were not stored, and why.
|
|
2219
|
-
*/
|
|
2220
|
-
images_not_kept: Array<ImageNotKept>;
|
|
2221
2342
|
latency: ReplyLatency | null;
|
|
2222
2343
|
/**
|
|
2223
2344
|
* Metadata
|
|
@@ -5256,15 +5377,6 @@ export type IfOperation = {
|
|
|
5256
5377
|
*/
|
|
5257
5378
|
then?: Array<HttpOperation | CodeOperation | FrontendRpcOperation | IfOperation | SetVariableOperation | SayOperation | GenerateReplyOperation | AddMessageOperation | EndCallOperation | HandoffOperation | TransferOperation | SendDtmfOperation> | null;
|
|
5258
5379
|
};
|
|
5259
|
-
/**
|
|
5260
|
-
* ImageNotKept
|
|
5261
|
-
*/
|
|
5262
|
-
export type ImageNotKept = {
|
|
5263
|
-
/**
|
|
5264
|
-
* Reason
|
|
5265
|
-
*/
|
|
5266
|
-
reason: string;
|
|
5267
|
-
};
|
|
5268
5380
|
/**
|
|
5269
5381
|
* ImportPhoneNumbersRequest
|
|
5270
5382
|
*/
|
|
@@ -5342,13 +5454,15 @@ export type InboundContent = {
|
|
|
5342
5454
|
replied_to?: string | null;
|
|
5343
5455
|
};
|
|
5344
5456
|
/**
|
|
5345
|
-
*
|
|
5457
|
+
* InboundFile
|
|
5346
5458
|
*
|
|
5347
|
-
* One
|
|
5459
|
+
* One file on an inbound text message: the bytes, and what to call them.
|
|
5348
5460
|
*/
|
|
5349
|
-
export type
|
|
5461
|
+
export type InboundFile = {
|
|
5350
5462
|
/**
|
|
5351
5463
|
* Data Url
|
|
5464
|
+
*
|
|
5465
|
+
* `data:<mime>;base64,<bytes>`, up to 20 MB decoded.
|
|
5352
5466
|
*/
|
|
5353
5467
|
data_url: string;
|
|
5354
5468
|
/**
|
|
@@ -5895,7 +6009,13 @@ export type ItemCreatedEvent = {
|
|
|
5895
6009
|
/**
|
|
5896
6010
|
* Attachments
|
|
5897
6011
|
*/
|
|
5898
|
-
attachments: Array<
|
|
6012
|
+
attachments: Array<ConversationImage | ConversationDocument | ConversationFile>;
|
|
6013
|
+
/**
|
|
6014
|
+
* Attachments Not Kept
|
|
6015
|
+
*
|
|
6016
|
+
* Files the person sent that could not be stored.
|
|
6017
|
+
*/
|
|
6018
|
+
attachments_not_kept: Array<AttachmentNotKept>;
|
|
5899
6019
|
/**
|
|
5900
6020
|
* Who at your business posted this.
|
|
5901
6021
|
*/
|
|
@@ -5947,12 +6067,6 @@ export type ItemCreatedEvent = {
|
|
|
5947
6067
|
* Idempotency Key
|
|
5948
6068
|
*/
|
|
5949
6069
|
idempotency_key: string | null;
|
|
5950
|
-
/**
|
|
5951
|
-
* Images Not Kept
|
|
5952
|
-
*
|
|
5953
|
-
* Images the person sent that were not stored, and why.
|
|
5954
|
-
*/
|
|
5955
|
-
images_not_kept: Array<ImageNotKept>;
|
|
5956
6070
|
latency: ReplyLatency | null;
|
|
5957
6071
|
/**
|
|
5958
6072
|
* Metadata
|
|
@@ -6205,7 +6319,7 @@ export type LLMModelSpec = {
|
|
|
6205
6319
|
/**
|
|
6206
6320
|
* Priority
|
|
6207
6321
|
*
|
|
6208
|
-
* Run this model in its provider's priority (low-latency) lane, where its catalog entry declares one. Steadies the worst case rather than the average, and costs
|
|
6322
|
+
* Run this model in its provider's priority (low-latency) lane, where its catalog entry declares one; on OpenRouter, any model (standard where no host sells one). Steadies the worst case rather than the average, and costs more per token.
|
|
6209
6323
|
*/
|
|
6210
6324
|
priority?: boolean;
|
|
6211
6325
|
/**
|
|
@@ -6242,7 +6356,7 @@ export type LLMModelSpecOverride = {
|
|
|
6242
6356
|
/**
|
|
6243
6357
|
* Priority
|
|
6244
6358
|
*
|
|
6245
|
-
* Run this model in its provider's priority (low-latency) lane, where its catalog entry declares one. Steadies the worst case rather than the average, and costs
|
|
6359
|
+
* Run this model in its provider's priority (low-latency) lane, where its catalog entry declares one; on OpenRouter, any model (standard where no host sells one). Steadies the worst case rather than the average, and costs more per token.
|
|
6246
6360
|
*/
|
|
6247
6361
|
priority?: boolean | null;
|
|
6248
6362
|
/**
|
|
@@ -6349,7 +6463,7 @@ export type LLMSpec = {
|
|
|
6349
6463
|
/**
|
|
6350
6464
|
* Priority
|
|
6351
6465
|
*
|
|
6352
|
-
* Run this model in its provider's priority (low-latency) lane, where its catalog entry declares one. Steadies the worst case rather than the average, and costs
|
|
6466
|
+
* Run this model in its provider's priority (low-latency) lane, where its catalog entry declares one; on OpenRouter, any model (standard where no host sells one). Steadies the worst case rather than the average, and costs more per token.
|
|
6353
6467
|
*/
|
|
6354
6468
|
priority?: boolean;
|
|
6355
6469
|
/**
|
|
@@ -6387,7 +6501,7 @@ export type LLMSpecOverride = {
|
|
|
6387
6501
|
/**
|
|
6388
6502
|
* Priority
|
|
6389
6503
|
*
|
|
6390
|
-
* Run this model in its provider's priority (low-latency) lane, where its catalog entry declares one. Steadies the worst case rather than the average, and costs
|
|
6504
|
+
* Run this model in its provider's priority (low-latency) lane, where its catalog entry declares one; on OpenRouter, any model (standard where no host sells one). Steadies the worst case rather than the average, and costs more per token.
|
|
6391
6505
|
*/
|
|
6392
6506
|
priority?: boolean | null;
|
|
6393
6507
|
/**
|
|
@@ -6582,6 +6696,10 @@ export type ModelHostResponse = {
|
|
|
6582
6696
|
* Quantization
|
|
6583
6697
|
*/
|
|
6584
6698
|
quantization: string | null;
|
|
6699
|
+
/**
|
|
6700
|
+
* Service Tier
|
|
6701
|
+
*/
|
|
6702
|
+
service_tier: 'priority' | 'ultrafast' | null;
|
|
6585
6703
|
/**
|
|
6586
6704
|
* Throughput P50
|
|
6587
6705
|
*/
|
|
@@ -16637,6 +16755,55 @@ export type ConversationsUpdateResults = {
|
|
|
16637
16755
|
200: ConversationResponse;
|
|
16638
16756
|
};
|
|
16639
16757
|
export type ConversationsUpdateResult = ConversationsUpdateResults[keyof ConversationsUpdateResults];
|
|
16758
|
+
export type ConversationsAttachmentsGetData = {
|
|
16759
|
+
body?: never;
|
|
16760
|
+
path: {
|
|
16761
|
+
/**
|
|
16762
|
+
* Conversation Id
|
|
16763
|
+
*/
|
|
16764
|
+
conversation_id: string;
|
|
16765
|
+
/**
|
|
16766
|
+
* Attachment Id
|
|
16767
|
+
*/
|
|
16768
|
+
attachment_id: string;
|
|
16769
|
+
};
|
|
16770
|
+
query?: never;
|
|
16771
|
+
url: '/v1/conversations/{conversation_id}/attachments/{attachment_id}';
|
|
16772
|
+
};
|
|
16773
|
+
export type ConversationsAttachmentsGetErrors = {
|
|
16774
|
+
/**
|
|
16775
|
+
* Missing credential, or one that is revoked or no longer a member of this organization.
|
|
16776
|
+
*/
|
|
16777
|
+
401: ErrorResponse;
|
|
16778
|
+
/**
|
|
16779
|
+
* No such resource in this organization.
|
|
16780
|
+
*/
|
|
16781
|
+
404: ErrorResponse;
|
|
16782
|
+
/**
|
|
16783
|
+
* The request did not match this operation's schema; `detail.errors` lists each field.
|
|
16784
|
+
*/
|
|
16785
|
+
422: ErrorResponse;
|
|
16786
|
+
/**
|
|
16787
|
+
* Unexpected error. Every error this API returns carries this body.
|
|
16788
|
+
*/
|
|
16789
|
+
default: ErrorResponse;
|
|
16790
|
+
};
|
|
16791
|
+
export type ConversationsAttachmentsGetError = ConversationsAttachmentsGetErrors[keyof ConversationsAttachmentsGetErrors];
|
|
16792
|
+
export type ConversationsAttachmentsGetResults = {
|
|
16793
|
+
/**
|
|
16794
|
+
* Response Conversations.Attachments.Get
|
|
16795
|
+
*
|
|
16796
|
+
* Successful Response
|
|
16797
|
+
*/
|
|
16798
|
+
200: ({
|
|
16799
|
+
kind: 'image';
|
|
16800
|
+
} & ConversationImage) | ({
|
|
16801
|
+
kind: 'document';
|
|
16802
|
+
} & ConversationDocument) | ({
|
|
16803
|
+
kind: 'file';
|
|
16804
|
+
} & ConversationFile);
|
|
16805
|
+
};
|
|
16806
|
+
export type ConversationsAttachmentsGetResult = ConversationsAttachmentsGetResults[keyof ConversationsAttachmentsGetResults];
|
|
16640
16807
|
export type ConversationsEventsData = {
|
|
16641
16808
|
body?: never;
|
|
16642
16809
|
path: {
|