@superclerk/sdk 0.1.1 → 0.3.0
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/CHANGELOG.md +38 -0
- package/api.md +32 -4
- package/core/client.js +11 -0
- package/generated/client.d.ts +3 -1
- package/generated/client.js +3 -1
- package/generated/resources.d.ts +136 -18
- package/generated/resources.js +205 -20
- package/generated/tools.d.ts +4147 -214
- package/generated/types.d.ts +1110 -52
- package/generated/version.d.ts +1 -1
- package/generated/version.js +1 -1
- package/generated/webhooks.d.ts +2 -2
- package/lib/chats.d.ts +79 -0
- package/lib/chats.js +122 -0
- package/package.json +2 -2
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,43 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 0.3.0 (2026-11-17)
|
|
4
|
+
|
|
5
|
+
Still pinned to API version `2026-11-05`.
|
|
6
|
+
|
|
7
|
+
- The PlusVibe tools follow PlusVibe's current API. Lists page by cursor: `plusvibe_list_campaigns`,
|
|
8
|
+
`plusvibe_list_leads`, `plusvibe_search_lead` and `plusvibe_list_emails` take `startingAfter` and answer
|
|
9
|
+
`nextStartingAfter` while more remain. `skip`, `page`, `sort`, `direction` and `pageTrail` are gone.
|
|
10
|
+
- `plusvibe_save_reply_draft` takes `threadId` in place of `parentMessageId`.
|
|
11
|
+
- `plusvibe_get_email_account_stats` covers the whole workspace: `endDate` is required and `emailAccountId` is gone.
|
|
12
|
+
- `plusvibe_list_campaigns`' `campaignType` is `all`, `parent` or `subseq`, and `plusvibe_list_leads`' `status` adds
|
|
13
|
+
`PAUSED` and drops `PENDING` and `RESCHEDULED`.
|
|
14
|
+
|
|
15
|
+
## 0.2.0 (2026-11-12)
|
|
16
|
+
|
|
17
|
+
Still pinned to API version `2026-11-05`.
|
|
18
|
+
|
|
19
|
+
- `chats`: talk to your workspace's agents as the app's chat does. `chats.create` starts a chat with an agent,
|
|
20
|
+
`chats.messages.create` sends a message at most once per idempotency key, and `chats.get` with `Prefer: wait` waits
|
|
21
|
+
for the answer. `chats.approvals.decide`, `chats.questions.answer` and `chats.questions.dismiss` settle what a chat's
|
|
22
|
+
`pending` lists, `chats.files.get` reads a file the chat holds, and `chats.stop` stops the agent.
|
|
23
|
+
- `chats.send()` sends a message and waits until the agent stops working on the chat. It answers the chat and the
|
|
24
|
+
agent's replies.
|
|
25
|
+
- `chats.stream()` follows a chat's events. After a dropped connection, 30 s of silence or an API that can't answer
|
|
26
|
+
yet, it reconnects after the last event it received, and waits longer, at random, as failures repeat. A part the
|
|
27
|
+
agent is still writing comes first without an `id`, holding its text so far.
|
|
28
|
+
- The client sends back the cookies the API sets, so a chat's stream reaches the server running the agent's turn and
|
|
29
|
+
gets its text as it's written.
|
|
30
|
+
- `agents.list()` answers `AgentList`: every agent in the workspace, with its `mode`, `instructions`, `model`, `tools`
|
|
31
|
+
and other settings. It answered `WorkflowAgentsResponse`. `agents.get()` reads one agent.
|
|
32
|
+
- `WebhookEvent` includes `chat.waiting` and `chat.idle`.
|
|
33
|
+
- Typed tools for 15 more apps: Acuity Scheduling, Airtable, Calendly, Google Contacts, Google Forms, Google Tasks,
|
|
34
|
+
Jotform, Kajabi, Kit, Pipedrive, Salesforce, Square, TikTok Lead Forms, Typeform and Zoom. YouTube adds
|
|
35
|
+
`youtube_list_uploads`, `youtube_list_videos` and `youtube_upload_video`, and `instagram_publish_reel` takes
|
|
36
|
+
`trialGraduation`.
|
|
37
|
+
- `meta_ads_list_promotable_pages` takes only `accountId` and lists every Page the sign-in can run ads from; `limit`
|
|
38
|
+
and `after` are gone.
|
|
39
|
+
- A request a key's scopes don't allow throws `insufficient_scope`, which replaces `permission_required`.
|
|
40
|
+
|
|
3
41
|
## 0.1.1 (2026-11-07)
|
|
4
42
|
|
|
5
43
|
- The README installs the SDK with npm, pnpm, Yarn or Bun.
|
package/api.md
CHANGED
|
@@ -104,6 +104,33 @@ Generated from the public OpenAPI document. Every method returns an `APIPromise`
|
|
|
104
104
|
- `client.social.posts.reschedule(postID, params)` → `SocialPostsRescheduleResponse` — `POST /v1/social/posts/{postID}/reschedule`
|
|
105
105
|
- `client.social.posts.cancel(postID, params)` → `SocialPostsCancelResponse` — `POST /v1/social/posts/{postID}/cancel`
|
|
106
106
|
|
|
107
|
+
## chats
|
|
108
|
+
|
|
109
|
+
- `client.chats.list(params?)` → `ChatsListResponse (paged)` — `GET /v1/chats`
|
|
110
|
+
- `client.chats.create(params)` → `Chat` — `POST /v1/chats`
|
|
111
|
+
- `client.chats.get(chatID)` → `Chat` — `GET /v1/chats/{chatID}`
|
|
112
|
+
- `client.chats.events(chatID, params?)` → `Response` — `GET /v1/chats/{chatID}/events`
|
|
113
|
+
- `client.chats.stop(chatID)` → `Chat` — `POST /v1/chats/{chatID}/stop`
|
|
114
|
+
|
|
115
|
+
### chats.messages
|
|
116
|
+
|
|
117
|
+
- `client.chats.messages.list(chatID, params?)` → `ChatsMessagesListResponse (paged)` — `GET /v1/chats/{chatID}/messages`
|
|
118
|
+
- `client.chats.messages.create(chatID, params)` → `ChatMessage` — `POST /v1/chats/{chatID}/messages`
|
|
119
|
+
- `client.chats.messages.get(messageID, params)` → `ChatMessage` — `GET /v1/chats/{chatID}/messages/{messageID}`
|
|
120
|
+
|
|
121
|
+
### chats.approvals
|
|
122
|
+
|
|
123
|
+
- `client.chats.approvals.decide(approvalID, params)` → `Chat` — `POST /v1/chats/{chatID}/approvals/{approvalID}/decide`
|
|
124
|
+
|
|
125
|
+
### chats.questions
|
|
126
|
+
|
|
127
|
+
- `client.chats.questions.answer(questionID, params)` → `Chat` — `POST /v1/chats/{chatID}/questions/{questionID}/answer`
|
|
128
|
+
- `client.chats.questions.dismiss(questionID, params)` → `Chat` — `POST /v1/chats/{chatID}/questions/{questionID}/dismiss`
|
|
129
|
+
|
|
130
|
+
### chats.files
|
|
131
|
+
|
|
132
|
+
- `client.chats.files.get(fileID, params)` → `ChatFile` — `GET /v1/chats/{chatID}/files/{fileID}`
|
|
133
|
+
|
|
107
134
|
## conversations
|
|
108
135
|
|
|
109
136
|
- `client.conversations.list(params?)` → `ConversationsListResponse (paged)` — `GET /v1/conversations`
|
|
@@ -234,6 +261,11 @@ Generated from the public OpenAPI document. Every method returns an `APIPromise`
|
|
|
234
261
|
|
|
235
262
|
- `client.inbox.agents.republish(agentID)` → `InboxAgentUpdate` — `POST /v1/inbox/agents/{agentID}/republish`
|
|
236
263
|
|
|
264
|
+
## agents
|
|
265
|
+
|
|
266
|
+
- `client.agents.list()` → `AgentList` — `GET /v1/agents`
|
|
267
|
+
- `client.agents.get(agentID)` → `Agent` — `GET /v1/agents/{agentID}`
|
|
268
|
+
|
|
237
269
|
## workflows
|
|
238
270
|
|
|
239
271
|
- `client.workflows.list(params?)` → `WorkflowsListResponse` — `GET /v1/workflows`
|
|
@@ -301,10 +333,6 @@ Generated from the public OpenAPI document. Every method returns an `APIPromise`
|
|
|
301
333
|
- `client.workflows.versions.get(workflowVersionID, params)` → `WorkflowVersionSnapshot` — `GET /v1/workflows/{workflowID}/versions/{workflowVersionID}`
|
|
302
334
|
- `client.workflows.versions.activate(workflowVersionID, params)` → `WorkflowsVersionsActivateResponse` — `POST /v1/workflows/{workflowID}/versions/{workflowVersionID}/activate`
|
|
303
335
|
|
|
304
|
-
## agents
|
|
305
|
-
|
|
306
|
-
- `client.agents.list()` → `WorkflowAgentsResponse` — `GET /v1/agents`
|
|
307
|
-
|
|
308
336
|
## receptionists
|
|
309
337
|
|
|
310
338
|
- `client.receptionists.list()` → `ReceptionistsListResponse` — `GET /v1/receptionists`
|
package/core/client.js
CHANGED
|
@@ -21,6 +21,9 @@ export class Core {
|
|
|
21
21
|
#userAgent = userAgent();
|
|
22
22
|
// SUPERCLERK_LOG=debug writes each attempt and retry to stderr, for you or the agent debugging an integration.
|
|
23
23
|
#debug = readEnv("SUPERCLERK_LOG") === "debug";
|
|
24
|
+
// The cookies the API sets, sent back as a browser would: its load balancer keeps a client on the server its cookie
|
|
25
|
+
// names, and only the server running a chat's turn streams the agent's text as it's written.
|
|
26
|
+
#cookies = new Map();
|
|
24
27
|
constructor(options = {}) {
|
|
25
28
|
const apiKey = options.apiKey ?? readEnv("SUPERCLERK_API_KEY");
|
|
26
29
|
if (!apiKey)
|
|
@@ -100,6 +103,12 @@ export class Core {
|
|
|
100
103
|
const startedAt = Date.now();
|
|
101
104
|
try {
|
|
102
105
|
const response = await this.#fetch(new Request(url, { ...init, signal }));
|
|
106
|
+
if (url.startsWith(this.baseURL)) {
|
|
107
|
+
for (const cookie of response.headers.getSetCookie()) {
|
|
108
|
+
const [name, ...value] = cookie.split(";", 1)[0].split("=");
|
|
109
|
+
this.#cookies.set(name.trim(), value.join("=").trim());
|
|
110
|
+
}
|
|
111
|
+
}
|
|
103
112
|
// An upload URL's storage answers too, without a Superclerk request ID.
|
|
104
113
|
const requestID = response.headers.get("x-superclerk-request-id");
|
|
105
114
|
this.log(`${init.method} ${host}${pathname} → ${response.status} in ${Date.now() - startedAt} ms${requestID ? ` (${requestID})` : ""}`);
|
|
@@ -133,6 +142,8 @@ export class Core {
|
|
|
133
142
|
headers.set("Superclerk-Workspace", workspace);
|
|
134
143
|
if (operation.idempotent)
|
|
135
144
|
headers.set("Idempotency-Key", options.idempotencyKey ?? crypto.randomUUID());
|
|
145
|
+
if (this.#cookies.size > 0)
|
|
146
|
+
headers.set("Cookie", Array.from(this.#cookies, ([name, value]) => `${name}=${value}`).join("; "));
|
|
136
147
|
for (const [name, value] of Object.entries(options.headers ?? {}))
|
|
137
148
|
headers.set(name, value);
|
|
138
149
|
return headers;
|
package/generated/client.d.ts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { Core, type ClientOptions } from "../core/client.js";
|
|
2
|
+
import { Chats } from "../lib/chats.js";
|
|
2
3
|
import { Connect } from "../lib/connect.js";
|
|
3
4
|
import { Connections } from "../lib/connections.js";
|
|
4
5
|
import { Social } from "../lib/social.js";
|
|
@@ -14,6 +15,7 @@ export declare class Superclerk extends Core {
|
|
|
14
15
|
readonly apps: Apps;
|
|
15
16
|
readonly connections: Connections;
|
|
16
17
|
readonly social: Social;
|
|
18
|
+
readonly chats: Chats;
|
|
17
19
|
readonly conversations: Conversations;
|
|
18
20
|
readonly tags: Tags;
|
|
19
21
|
readonly contacts: Contacts;
|
|
@@ -23,8 +25,8 @@ export declare class Superclerk extends Core {
|
|
|
23
25
|
readonly opportunities: Opportunities;
|
|
24
26
|
readonly tasks: Tasks;
|
|
25
27
|
readonly inbox: Inbox;
|
|
26
|
-
readonly workflows: Workflows;
|
|
27
28
|
readonly agents: Agents;
|
|
29
|
+
readonly workflows: Workflows;
|
|
28
30
|
readonly receptionists: Receptionists;
|
|
29
31
|
/** A copy of this client with some options changed, such as the client workspace it acts in. */
|
|
30
32
|
withOptions(options: ClientOptions): Superclerk;
|
package/generated/client.js
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
// Generated by script/generate.ts from the public OpenAPI document. Do not edit.
|
|
2
2
|
import { Core } from "../core/client.js";
|
|
3
|
+
import { Chats } from "../lib/chats.js";
|
|
3
4
|
import { Connect } from "../lib/connect.js";
|
|
4
5
|
import { Connections } from "../lib/connections.js";
|
|
5
6
|
import { Social } from "../lib/social.js";
|
|
@@ -15,6 +16,7 @@ export class Superclerk extends Core {
|
|
|
15
16
|
apps = new Apps(this);
|
|
16
17
|
connections = new Connections(this);
|
|
17
18
|
social = new Social(this);
|
|
19
|
+
chats = new Chats(this);
|
|
18
20
|
conversations = new Conversations(this);
|
|
19
21
|
tags = new Tags(this);
|
|
20
22
|
contacts = new Contacts(this);
|
|
@@ -24,8 +26,8 @@ export class Superclerk extends Core {
|
|
|
24
26
|
opportunities = new Opportunities(this);
|
|
25
27
|
tasks = new Tasks(this);
|
|
26
28
|
inbox = new Inbox(this);
|
|
27
|
-
workflows = new Workflows(this);
|
|
28
29
|
agents = new Agents(this);
|
|
30
|
+
workflows = new Workflows(this);
|
|
29
31
|
receptionists = new Receptionists(this);
|
|
30
32
|
/** A copy of this client with some options changed, such as the client workspace it acts in. */
|
|
31
33
|
withOptions(options) {
|
package/generated/resources.d.ts
CHANGED
|
@@ -172,7 +172,7 @@ export declare class ConnectionsAccounts extends APIResource {
|
|
|
172
172
|
/**
|
|
173
173
|
* List the accounts a connection can act as
|
|
174
174
|
*
|
|
175
|
-
* The accounts the connection's grant reaches, read from the provider now, and which of them the connection acts as: the pages, profiles, channels or locations a Social connection posts as, or the
|
|
175
|
+
* The accounts the connection's grant reaches, read from the provider now, and which of them the connection acts as: the pages, profiles, channels or locations a Social connection posts as, or the ad accounts an ads connection's tools act on, every one of which connecting turns on. A Social list is one page of the provider's list; follow nextCursor until it is null. An ads list comes in one page. A TikTok account carries the creator's settings, which a TikTok post names by creatorInfoFingerprint.
|
|
176
176
|
*
|
|
177
177
|
* `GET /v1/connections/{connectionID}/accounts`
|
|
178
178
|
*/
|
|
@@ -429,6 +429,116 @@ export declare class SocialBase extends APIResource {
|
|
|
429
429
|
readonly media: SocialMedia;
|
|
430
430
|
readonly posts: SocialPosts;
|
|
431
431
|
}
|
|
432
|
+
export declare class ChatsMessages extends APIResource {
|
|
433
|
+
/**
|
|
434
|
+
* List a chat's messages
|
|
435
|
+
*
|
|
436
|
+
* Newest first: what the person sent, and what the agent answered with its text, its reasoning and the tools it ran.
|
|
437
|
+
*
|
|
438
|
+
* `GET /v1/chats/{chatID}/messages`
|
|
439
|
+
*/
|
|
440
|
+
list(chatID: string, params?: Types.ChatsMessagesListParams, options?: RequestOptions): PagePromise<Types.ChatsMessagesListResponse>;
|
|
441
|
+
/**
|
|
442
|
+
* Send a message
|
|
443
|
+
*
|
|
444
|
+
* Sends the parts at most once per idempotency key and answers the message; the agent answers in the background, so read the chat to wait for it. A message sent while the agent works joins its turn at the next step, and one sent while it waits on a question is kept for once the question is answered or dismissed. A pending approval refuses a message: 409 approval_pending. A channel's conversation takes no message here: 409 read_only.
|
|
445
|
+
*
|
|
446
|
+
* `POST /v1/chats/{chatID}/messages`
|
|
447
|
+
*/
|
|
448
|
+
create(chatID: string, params: Types.ChatsMessagesCreateParams, options?: RequestOptions): APIPromise<Types.ChatMessage>;
|
|
449
|
+
/**
|
|
450
|
+
* Get a message
|
|
451
|
+
*
|
|
452
|
+
* One message of the chat.
|
|
453
|
+
*
|
|
454
|
+
* `GET /v1/chats/{chatID}/messages/{messageID}`
|
|
455
|
+
*/
|
|
456
|
+
get(messageID: string, params: Types.ChatsMessagesGetParams, options?: RequestOptions): APIPromise<Types.ChatMessage>;
|
|
457
|
+
}
|
|
458
|
+
export declare class ChatsApprovals extends APIResource {
|
|
459
|
+
/**
|
|
460
|
+
* Approve or deny a tool call
|
|
461
|
+
*
|
|
462
|
+
* Decides an approval the chat's pending lists; the agent then runs the tool, or not, and goes on. Sending the same decision again changes nothing; another one is a 409. A script's write plan is decided with its planDigest.
|
|
463
|
+
*
|
|
464
|
+
* `POST /v1/chats/{chatID}/approvals/{approvalID}/decide`
|
|
465
|
+
*/
|
|
466
|
+
decide(approvalID: string, params: Types.ChatsApprovalsDecideParams, options?: RequestOptions): APIPromise<Types.Chat>;
|
|
467
|
+
}
|
|
468
|
+
export declare class ChatsQuestions extends APIResource {
|
|
469
|
+
/**
|
|
470
|
+
* Answer the agent's question
|
|
471
|
+
*
|
|
472
|
+
* One answer per question, each the chosen option labels or, where the question allows, the person's own words; a connection request is answered with [[connectionID]]. The agent goes on with the answer. The same answer again changes nothing; another one is a 409.
|
|
473
|
+
*
|
|
474
|
+
* `POST /v1/chats/{chatID}/questions/{questionID}/answer`
|
|
475
|
+
*/
|
|
476
|
+
answer(questionID: string, params: Types.ChatsQuestionsAnswerParams, options?: RequestOptions): APIPromise<Types.Chat>;
|
|
477
|
+
/**
|
|
478
|
+
* Dismiss the agent's question
|
|
479
|
+
*
|
|
480
|
+
* Ends the turn that asked it; a message sent while it waited is answered next.
|
|
481
|
+
*
|
|
482
|
+
* `POST /v1/chats/{chatID}/questions/{questionID}/dismiss`
|
|
483
|
+
*/
|
|
484
|
+
dismiss(questionID: string, params: Types.ChatsQuestionsDismissParams, options?: RequestOptions): APIPromise<Types.Chat>;
|
|
485
|
+
}
|
|
486
|
+
export declare class ChatsFiles extends APIResource {
|
|
487
|
+
/**
|
|
488
|
+
* Get a file
|
|
489
|
+
*
|
|
490
|
+
* A file the chat holds, with a link that reads it for five minutes.
|
|
491
|
+
*
|
|
492
|
+
* `GET /v1/chats/{chatID}/files/{fileID}`
|
|
493
|
+
*/
|
|
494
|
+
get(fileID: string, params: Types.ChatsFilesGetParams, options?: RequestOptions): APIPromise<Types.ChatFile>;
|
|
495
|
+
}
|
|
496
|
+
export declare class ChatsBase extends APIResource {
|
|
497
|
+
readonly messages: ChatsMessages;
|
|
498
|
+
readonly approvals: ChatsApprovals;
|
|
499
|
+
readonly questions: ChatsQuestions;
|
|
500
|
+
readonly files: ChatsFiles;
|
|
501
|
+
/**
|
|
502
|
+
* List chats
|
|
503
|
+
*
|
|
504
|
+
* The chats the app lists, most recently active first: the member's own, outside any website and subagent. Archived chats are left out.
|
|
505
|
+
*
|
|
506
|
+
* `GET /v1/chats`
|
|
507
|
+
*/
|
|
508
|
+
list(params?: Types.ChatsListParams, options?: RequestOptions): PagePromise<Types.ChatsListResponse>;
|
|
509
|
+
/**
|
|
510
|
+
* Start a chat with an agent
|
|
511
|
+
*
|
|
512
|
+
* A chat with an agent agents.list returns whose mode is primary or all, which answers with its own instructions, model and tools. A subagent works only on tasks another agent gives it: 400 invalid_request.
|
|
513
|
+
*
|
|
514
|
+
* `POST /v1/chats`
|
|
515
|
+
*/
|
|
516
|
+
create(params: Types.ChatsCreateParams, options?: RequestOptions): APIPromise<Types.Chat>;
|
|
517
|
+
/**
|
|
518
|
+
* Get a chat
|
|
519
|
+
*
|
|
520
|
+
* The chat's status: running while the agent works, waiting while it needs an answer to what pending lists, idle otherwise, with the error that ended its latest message. Answers 202 while running.
|
|
521
|
+
*
|
|
522
|
+
* `GET /v1/chats/{chatID}`
|
|
523
|
+
*/
|
|
524
|
+
get(chatID: string, options?: RequestOptions): APIPromise<Types.Chat>;
|
|
525
|
+
/**
|
|
526
|
+
* Stream a chat
|
|
527
|
+
*
|
|
528
|
+
* Server-sent events: chat first and whenever it changes; on a new stream the transcript as messages; then message and part as each is written, delta as the agent's text streams (sent only by the server running the turn), and removed, deleted and error. Stored changes carry ids: reconnect with after, or the Last-Event-ID your client sends, to receive every change after it.
|
|
529
|
+
*
|
|
530
|
+
* `GET /v1/chats/{chatID}/events`
|
|
531
|
+
*/
|
|
532
|
+
events(chatID: string, params?: Types.ChatsEventsParams, options?: RequestOptions): APIPromise<Response>;
|
|
533
|
+
/**
|
|
534
|
+
* Stop the agent
|
|
535
|
+
*
|
|
536
|
+
* Stops the agent's turn, and dismisses what it waits on. Stopping an idle chat changes nothing.
|
|
537
|
+
*
|
|
538
|
+
* `POST /v1/chats/{chatID}/stop`
|
|
539
|
+
*/
|
|
540
|
+
stop(chatID: string, options?: RequestOptions): APIPromise<Types.Chat>;
|
|
541
|
+
}
|
|
432
542
|
export declare class ConversationsMessages extends APIResource {
|
|
433
543
|
/**
|
|
434
544
|
* List a conversation's messages
|
|
@@ -441,7 +551,7 @@ export declare class ConversationsMessages extends APIResource {
|
|
|
441
551
|
/**
|
|
442
552
|
* Reply as staff
|
|
443
553
|
*
|
|
444
|
-
* Queues the text for the customer at most once per idempotency key, and answers the message with status sending; list the messages to see it sent, or not_sent with why. The
|
|
554
|
+
* Queues the text for the customer at most once per idempotency key, and answers the message with status sending; list the messages to see it sent, or not_sent with why. The AI stays out for ten minutes from the reply, or until someone hands the conversation back if a person already held it, an AI turn in flight stops, and the customer's earlier messages count as answered. inReplyTo quotes a message the customer sent.
|
|
445
555
|
*
|
|
446
556
|
* `POST /v1/conversations/{conversationID}/messages`
|
|
447
557
|
*/
|
|
@@ -476,7 +586,7 @@ export declare class Conversations extends APIResource {
|
|
|
476
586
|
/**
|
|
477
587
|
* Take a conversation over from the AI
|
|
478
588
|
*
|
|
479
|
-
* A person holds the conversation
|
|
589
|
+
* A person holds the conversation until someone hands it back.
|
|
480
590
|
*
|
|
481
591
|
* Formerly `POST /v1/conversations/{conversationID}/take-over`, which still answers, marked deprecated.
|
|
482
592
|
*
|
|
@@ -938,7 +1048,7 @@ export declare class InboxAccountsAi extends APIResource {
|
|
|
938
1048
|
/**
|
|
939
1049
|
* Set AI up on an account
|
|
940
1050
|
*
|
|
941
|
-
* Makes the account a workflow of its own from the template, with its settings or the given ones, and puts it live for everyone who writes there. The workflow
|
|
1051
|
+
* Makes the account a workflow of its own from the template, with its settings or the given ones, and puts it live for everyone who writes there. The Inbox manages that workflow: only these routes change it, and Automations doesn't list it. A retry with the same key answers the workflow the first call made.
|
|
942
1052
|
*
|
|
943
1053
|
* `POST /v1/inbox/accounts/{connectionID}/ai`
|
|
944
1054
|
*/
|
|
@@ -956,7 +1066,7 @@ export declare class InboxAccountsSettings extends APIResource {
|
|
|
956
1066
|
/**
|
|
957
1067
|
* Change an account's AI settings
|
|
958
1068
|
*
|
|
959
|
-
* Replaces the settings at expectedRevision and publishes them in one step, keeping the live version's approvals: the next conversation uses them, and ones under way finish as they started. Refused
|
|
1069
|
+
* Replaces the settings at expectedRevision and publishes them in one step, keeping the live version's approvals: the next conversation uses them, and ones under way finish as they started. Refused for an account whose AI was built in Automations, which changes it there. A retry with the same key answers what the first call made.
|
|
960
1070
|
*
|
|
961
1071
|
* `PUT /v1/inbox/accounts/{connectionID}/settings`
|
|
962
1072
|
*/
|
|
@@ -976,7 +1086,7 @@ export declare class InboxAccounts extends APIResource {
|
|
|
976
1086
|
/**
|
|
977
1087
|
* Take an account out of the Inbox
|
|
978
1088
|
*
|
|
979
|
-
* In one step, the account stops receiving messages here and each workflow the Inbox made for it is archived; its conversations stay. Refused with nothing changed for an account set up elsewhere, and while the AI is answering a conversation there. A retry with the same key answers what the first call did.
|
|
1089
|
+
* In one step, the account stops receiving messages here and each workflow the Inbox made for it is archived; its conversations stay. A phone line keeps receiving, since its calls run through it: only its AI goes, and its texts wait for your team. Refused with nothing changed for an account set up elsewhere, and while the AI is answering a conversation there. A retry with the same key answers what the first call did.
|
|
980
1090
|
*
|
|
981
1091
|
* Formerly `POST /v1/inbox/accounts/{connectionID}/ai/remove`, which still answers, marked deprecated.
|
|
982
1092
|
*
|
|
@@ -1011,6 +1121,26 @@ export declare class Inbox extends APIResource {
|
|
|
1011
1121
|
readonly templates: InboxTemplates;
|
|
1012
1122
|
readonly agents: InboxAgents;
|
|
1013
1123
|
}
|
|
1124
|
+
export declare class Agents extends APIResource {
|
|
1125
|
+
/**
|
|
1126
|
+
* List agents
|
|
1127
|
+
*
|
|
1128
|
+
* The workspace's agents: its own agent first, and the ones that work only for other agents last. A chat and the Inbox take one whose mode is primary or all; a Run Agent step takes any, by its exact ID.
|
|
1129
|
+
*
|
|
1130
|
+
* Formerly `GET /v1/workflows/agents`, which still answers, marked deprecated.
|
|
1131
|
+
*
|
|
1132
|
+
* `GET /v1/agents`
|
|
1133
|
+
*/
|
|
1134
|
+
list(options?: RequestOptions): APIPromise<Types.AgentList>;
|
|
1135
|
+
/**
|
|
1136
|
+
* Get an agent
|
|
1137
|
+
*
|
|
1138
|
+
* One of the agents agents.list returns.
|
|
1139
|
+
*
|
|
1140
|
+
* `GET /v1/agents/{agentID}`
|
|
1141
|
+
*/
|
|
1142
|
+
get(agentID: string, options?: RequestOptions): APIPromise<Types.Agent>;
|
|
1143
|
+
}
|
|
1014
1144
|
export declare class WorkflowsCatalog extends APIResource {
|
|
1015
1145
|
/**
|
|
1016
1146
|
* List workflow authoring capabilities
|
|
@@ -1297,18 +1427,6 @@ export declare class Workflows extends APIResource {
|
|
|
1297
1427
|
*/
|
|
1298
1428
|
resume(workflowID: string, options?: RequestOptions): APIPromise<Types.WorkflowsResumeResponse>;
|
|
1299
1429
|
}
|
|
1300
|
-
export declare class Agents extends APIResource {
|
|
1301
|
-
/**
|
|
1302
|
-
* List agents available to Run Agent workflow steps
|
|
1303
|
-
*
|
|
1304
|
-
* Use an exact returned ID. The active revision is resolved once when the workflow is published.
|
|
1305
|
-
*
|
|
1306
|
-
* Formerly `GET /v1/workflows/agents`, which still answers, marked deprecated.
|
|
1307
|
-
*
|
|
1308
|
-
* `GET /v1/agents`
|
|
1309
|
-
*/
|
|
1310
|
-
list(options?: RequestOptions): APIPromise<Types.WorkflowAgentsResponse>;
|
|
1311
|
-
}
|
|
1312
1430
|
export declare class Receptionists extends APIResource {
|
|
1313
1431
|
/**
|
|
1314
1432
|
* List receptionists available to workflows
|