@blazingagents/sdk 0.33.0 → 0.35.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/dist/chat-transport.js +4 -1
- package/dist/client.d.ts +18 -2
- package/dist/client.js +16 -15
- package/dist/contracts/entities/agents.d.ts +7 -6
- package/dist/contracts/entities/agents.js +129 -36
- package/dist/contracts/entities/chat-connections.d.ts +9 -8
- package/dist/contracts/entities/chat-connections.js +70 -40
- package/dist/contracts/entities/chat.d.ts +8 -4
- package/dist/contracts/entities/chat.js +102 -28
- package/dist/contracts/entities/mcp-connections.d.ts +2 -0
- package/dist/contracts/entities/mcp-connections.js +36 -23
- package/dist/contracts/entities/memories.d.ts +1 -0
- package/dist/contracts/entities/memories.js +5 -3
- package/dist/contracts/entities/merchant.js +28 -9
- package/dist/contracts/entities/prompts.d.ts +2 -2
- package/dist/contracts/entities/prompts.js +42 -15
- package/dist/contracts/entities/providers.js +14 -6
- package/dist/contracts/entities/sessions.d.ts +17 -15
- package/dist/contracts/entities/sessions.js +23 -10
- package/dist/contracts/entities/skills.js +6 -3
- package/dist/contracts/entities/spending-limits.d.ts +0 -23
- package/dist/contracts/entities/spending-limits.js +0 -9
- package/dist/contracts/entities/tasks.d.ts +4 -7
- package/dist/contracts/entities/tasks.js +45 -15
- package/dist/contracts/entities/tenants.d.ts +2 -28
- package/dist/contracts/entities/tenants.js +15 -22
- package/dist/contracts/entities/usage.d.ts +1 -1
- package/dist/contracts/entities/usage.js +16 -6
- package/dist/contracts/entities/workspaces.d.ts +1 -1
- package/dist/contracts/entities/workspaces.js +26 -10
- package/dist/contracts/index.d.ts +20 -15
- package/dist/contracts/index.js +13 -13
- package/dist/contracts/limitations.d.ts +2 -4
- package/dist/contracts/limitations.js +2 -4
- package/dist/direct-chat-transport.js +2 -1
- package/dist/errors.d.ts +11 -0
- package/dist/errors.js +21 -0
- package/dist/http.d.ts +3 -1
- package/dist/http.js +12 -1
- package/dist/index.d.ts +20 -3
- package/dist/resources/agents.d.ts +120 -1
- package/dist/resources/agents.js +1 -33
- package/dist/resources/artifacts.d.ts +42 -1
- package/dist/resources/artifacts.js +0 -12
- package/dist/resources/chat-connections.d.ts +110 -1
- package/dist/resources/chat-connections.js +0 -33
- package/dist/resources/chat-deliveries.d.ts +23 -1
- package/dist/resources/chat-deliveries.js +1 -4
- package/dist/resources/mcp-connections.d.ts +63 -1
- package/dist/resources/mcp-connections.js +3 -21
- package/dist/resources/memories.d.ts +58 -1
- package/dist/resources/memories.js +0 -15
- package/dist/resources/merchant-bindings.d.ts +39 -1
- package/dist/resources/merchant-bindings.js +0 -9
- package/dist/resources/merchant-connection.d.ts +37 -1
- package/dist/resources/merchant-connection.js +1 -13
- package/dist/resources/merchant-usage-events.d.ts +66 -1
- package/dist/resources/merchant-usage-events.js +0 -18
- package/dist/resources/prompts.d.ts +50 -1
- package/dist/resources/prompts.js +0 -15
- package/dist/resources/providers.d.ts +64 -1
- package/dist/resources/providers.js +0 -21
- package/dist/resources/sessions.d.ts +124 -1
- package/dist/resources/sessions.js +5 -36
- package/dist/resources/skills.d.ts +95 -1
- package/dist/resources/skills.js +0 -27
- package/dist/resources/tasks.d.ts +107 -1
- package/dist/resources/tasks.js +0 -30
- package/dist/resources/tenant.d.ts +23 -1
- package/dist/resources/tenant.js +2 -10
- package/dist/resources/usage.d.ts +34 -1
- package/dist/resources/usage.js +2 -15
- package/dist/resources/workspaces.d.ts +50 -1
- package/dist/resources/workspaces.js +0 -15
- package/dist/types.d.ts +12 -1083
- package/package.json +1 -1
|
@@ -356,26 +356,28 @@ export declare const continueToolApprovalsBodySchema: z.ZodObject<{
|
|
|
356
356
|
approved: z.ZodBoolean;
|
|
357
357
|
reason: z.ZodOptional<z.ZodString>;
|
|
358
358
|
}, z.core.$strict>>;
|
|
359
|
-
functions: z.ZodOptional<z.
|
|
360
|
-
description:
|
|
361
|
-
inputSchema: z.
|
|
362
|
-
},
|
|
359
|
+
functions: z.ZodOptional<z.ZodCustom<Record<string, {
|
|
360
|
+
description: string;
|
|
361
|
+
inputSchema: z.core.JSONSchema.JSONSchema;
|
|
362
|
+
}>, Record<string, {
|
|
363
|
+
description: string;
|
|
364
|
+
inputSchema: z.core.JSONSchema.JSONSchema;
|
|
365
|
+
}>>>;
|
|
363
366
|
}, z.core.$strict>;
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
* rides here. `turn_interrupted` is never an HTTP error code. The Turn may
|
|
368
|
-
* have saved its work before the cut, so read the Session's messages.
|
|
369
|
-
*/
|
|
370
|
-
export declare const turnInterruptedEventSchema: z.ZodObject<{
|
|
371
|
-
type: z.ZodLiteral<"data-turn-interrupted">;
|
|
367
|
+
export declare const turnStreamErrorEventSchema: z.ZodObject<{
|
|
368
|
+
type: z.ZodLiteral<"data-ba-error">;
|
|
369
|
+
transient: z.ZodLiteral<true>;
|
|
372
370
|
data: z.ZodObject<{
|
|
373
|
-
code: z.
|
|
371
|
+
code: z.ZodCustom<"admin_agent_managed" | "agent_disabled" | "agent_mcp_connection_not_found" | "agent_mcp_connections_invalid" | "api_key_limit_reached" | "artifact_session_cap_reached" | "chat_webhook_conflict" | "chat_webhook_registration_failed" | "checkout_evidence_mismatch" | "forbidden" | "function_call_conflict" | "idempotency_conflict" | "input_idempotency_conflict" | "insufficient_scope" | "internal" | "invalid_cursor" | "invalid_request" | "mcp_connection_authentication_failed" | "mcp_connection_discovery_failed" | "mcp_connection_in_use" | "mcp_connection_invalid" | "mcp_connection_limit_reached" | "mcp_connection_name_conflict" | "mcp_connection_stale_credential_version" | "mcp_connection_unreachable" | "merchant_account_mismatch" | "merchant_balance_required" | "merchant_binding_not_found" | "merchant_binding_required" | "merchant_connection_not_found" | "merchant_credential_invalid" | "merchant_customer_not_found" | "merchant_customer_unmapped" | "merchant_eligibility_unavailable" | "merchant_event_not_found" | "merchant_event_state_conflict" | "merchant_provider_unavailable" | "merchant_subscription_required" | "message_id_conflict" | "message_not_found" | "model_discovery_unsupported" | "model_not_found" | "model_spending_limit_exceeded" | "model_validation_unavailable" | "not_found" | "prompt_variable_missing" | "prompt_variable_unknown" | "provider_historical_use" | "provider_in_use" | "provider_limit_reached" | "provider_name_conflict" | "provider_not_found" | "provider_required" | "quota_exceeded" | "rate_limited" | "service_unavailable" | "session_busy" | "session_fork_deleted" | "session_fork_unavailable" | "session_turn_unresponsive" | "session_version_mismatch" | "skill_invalid_archive" | "skill_invalid_markdown" | "skill_limit_reached" | "skill_name_conflict" | "skill_not_found" | "skill_too_many_files" | "skill_uncompressed_too_large" | "steer_not_available" | "subscription_required" | "task_active_run_exists" | "tenant_deleting" | "tenant_deletion_in_progress" | "tenant_deletion_not_ready" | "tenant_not_deleting" | "tool_approval_continuation_settled" | "tool_approval_decision_conflict" | "turn_interrupted" | "unauthorized" | "usage_credit_required" | "validation_failed" | "workspace_busy" | "workspace_in_use" | "workspace_not_found" | (string & {}), "admin_agent_managed" | "agent_disabled" | "agent_mcp_connection_not_found" | "agent_mcp_connections_invalid" | "api_key_limit_reached" | "artifact_session_cap_reached" | "chat_webhook_conflict" | "chat_webhook_registration_failed" | "checkout_evidence_mismatch" | "forbidden" | "function_call_conflict" | "idempotency_conflict" | "input_idempotency_conflict" | "insufficient_scope" | "internal" | "invalid_cursor" | "invalid_request" | "mcp_connection_authentication_failed" | "mcp_connection_discovery_failed" | "mcp_connection_in_use" | "mcp_connection_invalid" | "mcp_connection_limit_reached" | "mcp_connection_name_conflict" | "mcp_connection_stale_credential_version" | "mcp_connection_unreachable" | "merchant_account_mismatch" | "merchant_balance_required" | "merchant_binding_not_found" | "merchant_binding_required" | "merchant_connection_not_found" | "merchant_credential_invalid" | "merchant_customer_not_found" | "merchant_customer_unmapped" | "merchant_eligibility_unavailable" | "merchant_event_not_found" | "merchant_event_state_conflict" | "merchant_provider_unavailable" | "merchant_subscription_required" | "message_id_conflict" | "message_not_found" | "model_discovery_unsupported" | "model_not_found" | "model_spending_limit_exceeded" | "model_validation_unavailable" | "not_found" | "prompt_variable_missing" | "prompt_variable_unknown" | "provider_historical_use" | "provider_in_use" | "provider_limit_reached" | "provider_name_conflict" | "provider_not_found" | "provider_required" | "quota_exceeded" | "rate_limited" | "service_unavailable" | "session_busy" | "session_fork_deleted" | "session_fork_unavailable" | "session_turn_unresponsive" | "session_version_mismatch" | "skill_invalid_archive" | "skill_invalid_markdown" | "skill_limit_reached" | "skill_name_conflict" | "skill_not_found" | "skill_too_many_files" | "skill_uncompressed_too_large" | "steer_not_available" | "subscription_required" | "task_active_run_exists" | "tenant_deleting" | "tenant_deletion_in_progress" | "tenant_deletion_not_ready" | "tenant_not_deleting" | "tool_approval_continuation_settled" | "tool_approval_decision_conflict" | "turn_interrupted" | "unauthorized" | "usage_credit_required" | "validation_failed" | "workspace_busy" | "workspace_in_use" | "workspace_not_found" | (string & {})>;
|
|
372
|
+
details: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
373
|
+
message: z.ZodString;
|
|
374
374
|
}, z.core.$strict>;
|
|
375
|
-
transient: z.ZodLiteral<true>;
|
|
376
375
|
}, z.core.$strict>;
|
|
377
|
-
export type
|
|
376
|
+
export type TurnStreamErrorEvent = z.infer<typeof turnStreamErrorEventSchema>;
|
|
378
377
|
export type SessionForkedFrom = z.infer<typeof sessionForkedFromSchema>;
|
|
378
|
+
export type SessionListItem = z.infer<typeof sessionListItemSchema>;
|
|
379
|
+
export type LatestSessionListItem = z.infer<typeof latestSessionListItemSchema>;
|
|
380
|
+
export type SessionMessage = z.infer<typeof sessionMessageSchema>;
|
|
379
381
|
export type SessionResponse = z.infer<typeof sessionResponseSchema>;
|
|
380
382
|
export type SessionsListResponse = z.infer<typeof sessionsListResponseSchema>;
|
|
381
383
|
export type LatestSessionsListResponse = z.infer<typeof latestSessionsListResponseSchema>;
|
|
@@ -4,7 +4,7 @@ import { agentIdSchema, sessionIdSchema } from "../ids.js";
|
|
|
4
4
|
import { toolExecutionReferenceSchema } from "./agent-approval.js";
|
|
5
5
|
import { agentConfigSchema, agentResponseSchema } from "./agents.js";
|
|
6
6
|
import { metadataSchema, userIdSchema } from "./attribution.js";
|
|
7
|
-
import {
|
|
7
|
+
import { chatRequestBodySchema } from "./chat.js";
|
|
8
8
|
/**
|
|
9
9
|
* `GET /v1/agents/{agentId}/sessions` list item. `agentId`/`tenantId` never
|
|
10
10
|
* leak to the wire; `userId`/`metadata` come from the first successful Turn.
|
|
@@ -106,7 +106,7 @@ export const toolApprovalStateSchema = z
|
|
|
106
106
|
decidedAt: z.iso.datetime({ offset: true }).nullable().optional(),
|
|
107
107
|
approvalId: z.string().min(1),
|
|
108
108
|
decision: z.enum(["pending", "approved", "denied"]),
|
|
109
|
-
input: z.json(),
|
|
109
|
+
input: z.json().meta({ type: "object" }),
|
|
110
110
|
reason: z.string().nullable(),
|
|
111
111
|
toolCallId: z.string().min(1),
|
|
112
112
|
toolName: z.string().min(1),
|
|
@@ -130,20 +130,33 @@ export const continueToolApprovalsBodySchema = z
|
|
|
130
130
|
.array(toolApprovalDecisionSchema)
|
|
131
131
|
.min(1)
|
|
132
132
|
.refine((decisions) => new Set(decisions.map((decision) => decision.approvalId)).size ===
|
|
133
|
-
decisions.length, { message: "Approval IDs must be distinct." })
|
|
134
|
-
|
|
133
|
+
decisions.length, { message: "Approval IDs must be distinct." })
|
|
134
|
+
.describe("One decision for every approval in the current round."),
|
|
135
|
+
functions: chatRequestBodySchema.shape.functions,
|
|
135
136
|
})
|
|
136
137
|
.strict();
|
|
137
138
|
/**
|
|
138
|
-
* Transient event that precedes the `error` chunk when a Turn stream
|
|
139
|
+
* Transient event that precedes the `error` chunk when a Turn stream fails
|
|
139
140
|
* after it started. The `error` chunk has no field for a code, so the code
|
|
140
|
-
* rides here
|
|
141
|
-
*
|
|
141
|
+
* rides here, in the shape of an HTTP error body's `error`. `turn_interrupted`
|
|
142
|
+
* is the one stream-only code: the stream was cut, and the Turn may have saved
|
|
143
|
+
* its work before the cut, so read the Session's messages.
|
|
142
144
|
*/
|
|
143
|
-
|
|
145
|
+
/** Open like an HTTP error code, so a code added after this release still parses. */
|
|
146
|
+
const turnStreamErrorCodeSchema = z.custom((value) => typeof value === "string" && value.length > 0);
|
|
147
|
+
export const turnStreamErrorEventSchema = z
|
|
144
148
|
.object({
|
|
145
|
-
type: z.literal("data-
|
|
146
|
-
data: z.object({ code: z.literal("turn_interrupted") }).strict(),
|
|
149
|
+
type: z.literal("data-ba-error"),
|
|
147
150
|
transient: z.literal(true),
|
|
151
|
+
data: z
|
|
152
|
+
.object({
|
|
153
|
+
code: turnStreamErrorCodeSchema,
|
|
154
|
+
details: z
|
|
155
|
+
.record(z.string(), z.unknown())
|
|
156
|
+
.refine((value) => Object.keys(value).length > 0)
|
|
157
|
+
.optional(),
|
|
158
|
+
message: z.string().min(1),
|
|
159
|
+
})
|
|
160
|
+
.strict(),
|
|
148
161
|
})
|
|
149
162
|
.strict();
|
|
@@ -55,8 +55,10 @@ export const skillDetailSchema = skillSchema
|
|
|
55
55
|
export const skillsListResponseSchema = paginatedResponseSchema(skillSchema);
|
|
56
56
|
export const createSkillBodySchema = z
|
|
57
57
|
.object({
|
|
58
|
-
path: z.literal("SKILL.md"),
|
|
59
|
-
content: z
|
|
58
|
+
path: z.literal("SKILL.md").describe("Always `SKILL.md`."),
|
|
59
|
+
content: z
|
|
60
|
+
.string()
|
|
61
|
+
.describe("The `SKILL.md` document. It must start with YAML frontmatter that sets `name` and `description`."),
|
|
60
62
|
})
|
|
61
63
|
.strict();
|
|
62
64
|
export const skillArchiveTypeSchema = z.enum(["zip", "tar", "tar.gz"]);
|
|
@@ -68,7 +70,8 @@ export const copySkillBodySchema = z
|
|
|
68
70
|
.max(MAX_SKILL_COPY_DESTINATIONS)
|
|
69
71
|
.refine(hasUniqueValues, {
|
|
70
72
|
message: "Destination Agent ids must be unique.",
|
|
71
|
-
})
|
|
73
|
+
})
|
|
74
|
+
.describe("IDs of the agents to copy the skill to, each listed once. Send 1 to 30."),
|
|
72
75
|
})
|
|
73
76
|
.strict();
|
|
74
77
|
const skillCopyCreatedResultSchema = z
|
|
@@ -76,26 +76,3 @@ export type SpendingLimitResponse = z.infer<typeof spendingLimitResponseSchema>;
|
|
|
76
76
|
export type SpendingLimitStopDetails = z.infer<typeof spendingLimitStopDetailsSchema>;
|
|
77
77
|
export type UpdateSpendingLimitBody = z.infer<typeof updateSpendingLimitBodySchema>;
|
|
78
78
|
export declare function nextSpendingLimitReset(schedule: Pick<SpendingLimit, "resetStartDate" | "resetInterval">, after: string | Date): string;
|
|
79
|
-
export declare const spendingLimitStopEventSchema: z.ZodObject<{
|
|
80
|
-
type: z.ZodLiteral<"data-model-spending-limit">;
|
|
81
|
-
data: z.ZodObject<{
|
|
82
|
-
scope: z.ZodEnum<{
|
|
83
|
-
agent: "agent";
|
|
84
|
-
both: "both";
|
|
85
|
-
tenant: "tenant";
|
|
86
|
-
}>;
|
|
87
|
-
reason: z.ZodEnum<{
|
|
88
|
-
exhausted: "exhausted";
|
|
89
|
-
reserved: "reserved";
|
|
90
|
-
unknown_usage: "unknown_usage";
|
|
91
|
-
unpriced: "unpriced";
|
|
92
|
-
}>;
|
|
93
|
-
spentUsd: z.ZodNumber;
|
|
94
|
-
reservedUsd: z.ZodNumber;
|
|
95
|
-
availableUsd: z.ZodNumber;
|
|
96
|
-
nextResetAt: z.ZodNullable<z.ZodISODateTime>;
|
|
97
|
-
code: z.ZodLiteral<"model_spending_limit_exceeded">;
|
|
98
|
-
}, z.core.$strict>;
|
|
99
|
-
transient: z.ZodLiteral<true>;
|
|
100
|
-
}, z.core.$strict>;
|
|
101
|
-
export type SpendingLimitStopEvent = z.infer<typeof spendingLimitStopEventSchema>;
|
|
@@ -68,12 +68,3 @@ export function nextSpendingLimitReset(schedule, after) {
|
|
|
68
68
|
}
|
|
69
69
|
return boundary().toISOString();
|
|
70
70
|
}
|
|
71
|
-
export const spendingLimitStopEventSchema = z
|
|
72
|
-
.object({
|
|
73
|
-
type: z.literal("data-model-spending-limit"),
|
|
74
|
-
data: spendingLimitStopDetailsSchema.extend({
|
|
75
|
-
code: z.literal("model_spending_limit_exceeded"),
|
|
76
|
-
}),
|
|
77
|
-
transient: z.literal(true),
|
|
78
|
-
})
|
|
79
|
-
.strict();
|
|
@@ -41,13 +41,8 @@ export declare const taskScheduleInputSchema: z.ZodDiscriminatedUnion<[z.ZodObje
|
|
|
41
41
|
timezone: z.ZodDefault<z.ZodString>;
|
|
42
42
|
}, z.core.$strict>;
|
|
43
43
|
}, z.core.$strict>], "kind">;
|
|
44
|
-
/**
|
|
45
|
-
* `POST /v1/tasks` — schedule present = scheduled task; absent = on-demand.
|
|
46
|
-
* `submit: true` enqueues a run immediately. An optional `idempotencyKey`
|
|
47
|
-
* makes retries return the original Task and initial run id. Without a key,
|
|
48
|
-
* each call creates a new Task. Run creation has its own idempotency key.
|
|
49
|
-
*/
|
|
50
44
|
export declare const createTaskBodySchema: z.ZodObject<{
|
|
45
|
+
idempotencyKey: z.ZodOptional<z.ZodString>;
|
|
51
46
|
agentId: z.ZodString;
|
|
52
47
|
name: z.ZodString;
|
|
53
48
|
prompt: z.ZodString;
|
|
@@ -71,7 +66,6 @@ export declare const createTaskBodySchema: z.ZodObject<{
|
|
|
71
66
|
}, z.core.$strict>], "kind">>>;
|
|
72
67
|
enabled: z.ZodDefault<z.ZodBoolean>;
|
|
73
68
|
submit: z.ZodDefault<z.ZodBoolean>;
|
|
74
|
-
idempotencyKey: z.ZodOptional<z.ZodString>;
|
|
75
69
|
userId: z.ZodDefault<z.ZodString>;
|
|
76
70
|
metadata: z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
77
71
|
}, z.core.$strict>;
|
|
@@ -601,6 +595,9 @@ export declare const taskRunMessagesResponseSchema: z.ZodObject<{
|
|
|
601
595
|
succeeded: "succeeded";
|
|
602
596
|
}>;
|
|
603
597
|
}, z.core.$strip>;
|
|
598
|
+
export type TaskListItem = z.infer<typeof taskListItemSchema>;
|
|
599
|
+
export type TaskRunStatus = z.infer<typeof taskRunStatusSchema>;
|
|
600
|
+
export type TaskScheduleInput = z.infer<typeof taskScheduleInputSchema>;
|
|
604
601
|
export type TasksListResponse = z.infer<typeof tasksListResponseSchema>;
|
|
605
602
|
export type TaskResponse = z.infer<typeof taskResponseSchema>;
|
|
606
603
|
export type TaskRunResponse = z.infer<typeof taskRunResponseSchema>;
|
|
@@ -110,27 +110,52 @@ const taskPromptSchema = z.string().trim().min(1).max(MAX_TASK_PROMPT_LENGTH);
|
|
|
110
110
|
* makes retries return the original Task and initial run id. Without a key,
|
|
111
111
|
* each call creates a new Task. Run creation has its own idempotency key.
|
|
112
112
|
*/
|
|
113
|
+
const taskFieldDescriptions = {
|
|
114
|
+
agentId: "ID of the agent that runs the task. It cannot change later.",
|
|
115
|
+
name: "Display name, 1 to 80 characters.",
|
|
116
|
+
prompt: "The prompt the agent receives on every run, 1 to 6,000 characters.",
|
|
117
|
+
schedule: "When the task runs by itself: `once` at a time, every `everyMs` milliseconds (at least 60,000) for `interval`, or a five-field cron expression in an IANA timezone for `cron`. `null` means the task runs only when you start it.",
|
|
118
|
+
enabled: "Whether the schedule fires. A disabled task can still be started on demand.",
|
|
119
|
+
submit: "Start a run as soon as the task is created.",
|
|
120
|
+
userId: "Your end user's ID, used for attribution. An empty string means a tenant-level task. It cannot change after creation.",
|
|
121
|
+
metadata: "Your own key-value data, returned unchanged and copied to each run.",
|
|
122
|
+
};
|
|
113
123
|
export const createTaskBodySchema = z
|
|
114
124
|
.object({
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
125
|
+
idempotencyKey: z
|
|
126
|
+
.string()
|
|
127
|
+
.trim()
|
|
128
|
+
.min(1)
|
|
129
|
+
.optional()
|
|
130
|
+
.describe("Retry the same creation with this key to return the current task and its original initial run. Changed requests or deleted tasks return a conflict."),
|
|
131
|
+
agentId: agentIdSchema.describe(taskFieldDescriptions.agentId),
|
|
132
|
+
name: taskNameSchema.describe(taskFieldDescriptions.name),
|
|
133
|
+
prompt: taskPromptSchema.describe(taskFieldDescriptions.prompt),
|
|
134
|
+
schedule: taskScheduleInputSchema
|
|
135
|
+
.nullable()
|
|
136
|
+
.default(null)
|
|
137
|
+
.describe(taskFieldDescriptions.schedule),
|
|
138
|
+
enabled: z.boolean().default(true).describe(taskFieldDescriptions.enabled),
|
|
139
|
+
submit: z.boolean().default(false).describe(taskFieldDescriptions.submit),
|
|
140
|
+
userId: userIdSchema.default("").describe(taskFieldDescriptions.userId),
|
|
141
|
+
metadata: metadataSchema
|
|
142
|
+
.default({})
|
|
143
|
+
.describe(taskFieldDescriptions.metadata),
|
|
124
144
|
})
|
|
125
145
|
.strict();
|
|
126
146
|
// `PATCH /v1/tasks/{taskId}` — `agentId` and `userId` are immutable.
|
|
127
147
|
export const updateTaskBodySchema = z
|
|
128
148
|
.object({
|
|
129
|
-
name: taskNameSchema.optional(),
|
|
130
|
-
prompt: taskPromptSchema.optional(),
|
|
131
|
-
schedule: taskScheduleInputSchema
|
|
132
|
-
|
|
133
|
-
|
|
149
|
+
name: taskNameSchema.optional().describe(taskFieldDescriptions.name),
|
|
150
|
+
prompt: taskPromptSchema.optional().describe(taskFieldDescriptions.prompt),
|
|
151
|
+
schedule: taskScheduleInputSchema
|
|
152
|
+
.nullable()
|
|
153
|
+
.optional()
|
|
154
|
+
.describe(taskFieldDescriptions.schedule),
|
|
155
|
+
enabled: z.boolean().optional().describe(taskFieldDescriptions.enabled),
|
|
156
|
+
metadata: metadataSchema
|
|
157
|
+
.optional()
|
|
158
|
+
.describe("Your own key-value data. Replaces the current metadata."),
|
|
134
159
|
})
|
|
135
160
|
.strict()
|
|
136
161
|
.refine(hasObjectKeys, {
|
|
@@ -139,7 +164,12 @@ export const updateTaskBodySchema = z
|
|
|
139
164
|
// `POST /v1/tasks/{taskId}/runs` — optional client idempotency key.
|
|
140
165
|
export const createTaskRunBodySchema = z
|
|
141
166
|
.object({
|
|
142
|
-
idempotencyKey: z
|
|
167
|
+
idempotencyKey: z
|
|
168
|
+
.string()
|
|
169
|
+
.trim()
|
|
170
|
+
.min(1)
|
|
171
|
+
.optional()
|
|
172
|
+
.describe("Your own key for this run. Retrying with the same key returns the same run instead of starting another."),
|
|
143
173
|
})
|
|
144
174
|
.strict();
|
|
145
175
|
/**
|
|
@@ -1,32 +1,4 @@
|
|
|
1
1
|
import { z } from "zod";
|
|
2
|
-
/**
|
|
3
|
-
* `GET /v1/me` (JWT-only) — the tenant record. `authUserId` is a uuid
|
|
4
|
-
* referencing `auth.users(id)` per the migration.
|
|
5
|
-
*/
|
|
6
|
-
export declare const tenantSchema: z.ZodObject<{
|
|
7
|
-
id: z.ZodString;
|
|
8
|
-
authUserId: z.ZodUUID;
|
|
9
|
-
email: z.ZodString;
|
|
10
|
-
name: z.ZodString;
|
|
11
|
-
createdAt: z.ZodISODateTime;
|
|
12
|
-
updatedAt: z.ZodISODateTime;
|
|
13
|
-
}, z.core.$strip>;
|
|
14
|
-
export declare const subscriptionStatusSchema: z.ZodEnum<{
|
|
15
|
-
active: "active";
|
|
16
|
-
inactive: "inactive";
|
|
17
|
-
}>;
|
|
18
|
-
export declare const tenantResponseSchema: z.ZodObject<{
|
|
19
|
-
id: z.ZodString;
|
|
20
|
-
authUserId: z.ZodUUID;
|
|
21
|
-
email: z.ZodString;
|
|
22
|
-
name: z.ZodString;
|
|
23
|
-
createdAt: z.ZodISODateTime;
|
|
24
|
-
updatedAt: z.ZodISODateTime;
|
|
25
|
-
subscriptionStatus: z.ZodEnum<{
|
|
26
|
-
active: "active";
|
|
27
|
-
inactive: "inactive";
|
|
28
|
-
}>;
|
|
29
|
-
}, z.core.$strip>;
|
|
30
2
|
/**
|
|
31
3
|
* Tenant deletion lifecycle — `requestedAt` marks the tenant deleting and
|
|
32
4
|
* `deletesAt` is the scheduled permanent-deletion time (24 hours after
|
|
@@ -76,5 +48,7 @@ export declare const updateTenantSettingsBodySchema: z.ZodObject<{
|
|
|
76
48
|
resetDay: z.ZodNumber;
|
|
77
49
|
}, z.core.$strict>>>;
|
|
78
50
|
}, z.core.$strict>;
|
|
51
|
+
export type Quota = z.infer<typeof quotaSchema>;
|
|
52
|
+
export type TenantDeletion = z.infer<typeof tenantDeletionSchema>;
|
|
79
53
|
export type TenantSettingsResponse = z.infer<typeof tenantSettingsResponseSchema>;
|
|
80
54
|
export type UpdateTenantSettingsBody = z.infer<typeof updateTenantSettingsBodySchema>;
|
|
@@ -1,25 +1,6 @@
|
|
|
1
1
|
import { z } from "zod";
|
|
2
|
-
import { tenantIdSchema } from "../ids.js";
|
|
3
2
|
import { MAX_QUOTA_RESET_DAY, MAX_TENANT_NAME_LENGTH, MIN_QUOTA_RESET_DAY, } from "../limitations.js";
|
|
4
3
|
import { atLeastOneFieldMessage, hasObjectKeys } from "../utils.js";
|
|
5
|
-
/**
|
|
6
|
-
* `GET /v1/me` (JWT-only) — the tenant record. `authUserId` is a uuid
|
|
7
|
-
* referencing `auth.users(id)` per the migration.
|
|
8
|
-
*/
|
|
9
|
-
export const tenantSchema = z
|
|
10
|
-
.object({
|
|
11
|
-
id: tenantIdSchema,
|
|
12
|
-
authUserId: z.uuid(),
|
|
13
|
-
email: z.string().min(1),
|
|
14
|
-
name: z.string().min(1),
|
|
15
|
-
createdAt: z.iso.datetime({ offset: true }),
|
|
16
|
-
updatedAt: z.iso.datetime({ offset: true }),
|
|
17
|
-
})
|
|
18
|
-
.strip();
|
|
19
|
-
export const subscriptionStatusSchema = z.enum(["active", "inactive"]);
|
|
20
|
-
export const tenantResponseSchema = tenantSchema
|
|
21
|
-
.extend({ subscriptionStatus: subscriptionStatusSchema })
|
|
22
|
-
.strip();
|
|
23
4
|
/**
|
|
24
5
|
* Tenant deletion lifecycle — `requestedAt` marks the tenant deleting and
|
|
25
6
|
* `deletesAt` is the scheduled permanent-deletion time (24 hours after
|
|
@@ -62,9 +43,21 @@ export const tenantSettingsResponseSchema = tenantSettingsSchema
|
|
|
62
43
|
.strip();
|
|
63
44
|
export const updateTenantSettingsBodySchema = z
|
|
64
45
|
.object({
|
|
65
|
-
monetizationEnabled: z
|
|
66
|
-
|
|
67
|
-
|
|
46
|
+
monetizationEnabled: z
|
|
47
|
+
.boolean()
|
|
48
|
+
.optional()
|
|
49
|
+
.describe("Bill usage to your end users through your merchant account. Turning it off drops usage events your merchant has not yet accepted."),
|
|
50
|
+
name: z
|
|
51
|
+
.string()
|
|
52
|
+
.trim()
|
|
53
|
+
.min(1)
|
|
54
|
+
.max(MAX_TENANT_NAME_LENGTH)
|
|
55
|
+
.optional()
|
|
56
|
+
.describe("Display name of your tenant."),
|
|
57
|
+
quota: quotaSchema
|
|
58
|
+
.nullable()
|
|
59
|
+
.optional()
|
|
60
|
+
.describe("The whole monthly quota, replacing the current one, or `null` to remove it. Send `monthlyTokenLimit`, `monthlyRequestLimit`, and `resetDay`, with at least one limit set."),
|
|
68
61
|
})
|
|
69
62
|
.strict()
|
|
70
63
|
.refine(hasObjectKeys, {
|
|
@@ -35,9 +35,9 @@ export declare const usageTotalsSchema: z.ZodObject<{
|
|
|
35
35
|
durationMs: z.ZodNumber;
|
|
36
36
|
}, z.core.$strip>;
|
|
37
37
|
export declare const sessionUsageQuerySchema: z.ZodObject<{
|
|
38
|
-
sessionIds: z.ZodArray<z.ZodString>;
|
|
39
38
|
from: z.ZodOptional<z.ZodISODate>;
|
|
40
39
|
to: z.ZodOptional<z.ZodISODate>;
|
|
40
|
+
sessionIds: z.ZodArray<z.ZodString>;
|
|
41
41
|
}, z.core.$strict>;
|
|
42
42
|
export declare const sessionUsageResponseSchema: z.ZodObject<{
|
|
43
43
|
data: z.ZodArray<z.ZodObject<{
|
|
@@ -34,20 +34,30 @@ function validateUsageRange(value, ctx) {
|
|
|
34
34
|
}
|
|
35
35
|
}
|
|
36
36
|
}
|
|
37
|
+
const usageRangeFields = {
|
|
38
|
+
from: z.iso
|
|
39
|
+
.date()
|
|
40
|
+
.optional()
|
|
41
|
+
.describe("First UTC day to include, as `YYYY-MM-DD`. Send it with `to`, or leave both out for the last 30 days ending today."),
|
|
42
|
+
to: z.iso
|
|
43
|
+
.date()
|
|
44
|
+
.optional()
|
|
45
|
+
.describe(`Last UTC day to include, as \`YYYY-MM-DD\`. It must not be before \`from\` and can be at most ${MAX_USAGE_RANGE_DAYS} days after it.`),
|
|
46
|
+
};
|
|
37
47
|
/**
|
|
38
48
|
* Query for the bounded dashboard-oriented usage overview. The date range has
|
|
39
49
|
* the same semantics as `UsageQuery`; `limit` bounds each ranking.
|
|
40
50
|
*/
|
|
41
51
|
export const usageOverviewQuerySchema = z
|
|
42
52
|
.object({
|
|
43
|
-
|
|
44
|
-
to: z.iso.date().optional(),
|
|
53
|
+
...usageRangeFields,
|
|
45
54
|
limit: z
|
|
46
55
|
.number()
|
|
47
56
|
.int()
|
|
48
57
|
.min(1)
|
|
49
58
|
.max(MAX_USAGE_OVERVIEW_TOP_N)
|
|
50
|
-
.default(DEFAULT_USAGE_OVERVIEW_TOP_N)
|
|
59
|
+
.default(DEFAULT_USAGE_OVERVIEW_TOP_N)
|
|
60
|
+
.describe(`Rows to return in each ranked breakdown (\`byAgent\`, \`byUser\`, \`byModel\`), from 1 to ${MAX_USAGE_OVERVIEW_TOP_N}.`),
|
|
51
61
|
})
|
|
52
62
|
.strict()
|
|
53
63
|
.superRefine(validateUsageRange);
|
|
@@ -89,9 +99,9 @@ export const sessionUsageQuerySchema = z
|
|
|
89
99
|
.max(100)
|
|
90
100
|
.refine(hasUniqueValues, {
|
|
91
101
|
message: "Session ids must be unique.",
|
|
92
|
-
})
|
|
93
|
-
|
|
94
|
-
|
|
102
|
+
})
|
|
103
|
+
.describe("One to 100 distinct session IDs. Every session must be visible to the caller."),
|
|
104
|
+
...usageRangeFields,
|
|
95
105
|
})
|
|
96
106
|
.strict()
|
|
97
107
|
.superRefine(validateUsageRange);
|
|
@@ -34,11 +34,11 @@ export declare const workspaceSchema: z.ZodObject<{
|
|
|
34
34
|
updatedAt: z.ZodISODateTime;
|
|
35
35
|
}, z.core.$strip>;
|
|
36
36
|
export declare const createWorkspaceBodySchema: z.ZodObject<{
|
|
37
|
-
name: z.ZodOptional<z.ZodString>;
|
|
38
37
|
tier: z.ZodDefault<z.ZodEnum<{
|
|
39
38
|
core: "core";
|
|
40
39
|
plus: "plus";
|
|
41
40
|
}>>;
|
|
41
|
+
name: z.ZodOptional<z.ZodString>;
|
|
42
42
|
userId: z.ZodDefault<z.ZodString>;
|
|
43
43
|
metadata: z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
44
44
|
networkPolicy: z.ZodDefault<z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
@@ -38,22 +38,38 @@ export const workspaceSchema = z
|
|
|
38
38
|
updatedAt: z.iso.datetime({ offset: true }),
|
|
39
39
|
})
|
|
40
40
|
.strip();
|
|
41
|
+
const networkPolicyDescription = "Which hosts the workspace can reach: `unrestricted`, `allowlist` with `allowedHosts`, or `offline`.";
|
|
41
42
|
export const createWorkspaceBodySchema = z
|
|
42
43
|
.object({
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
44
|
+
tier: workspaceTierSchema
|
|
45
|
+
.default("core")
|
|
46
|
+
.describe("Workspace tier, fixed at creation. Core loses its files when the workspace stops; Plus keeps them when it stops while idle."),
|
|
47
|
+
name: workspaceNameSchema
|
|
48
|
+
.optional()
|
|
49
|
+
.describe(`Display name, up to ${MAX_WORKSPACE_NAME_LENGTH} characters. Leave it out for an unnamed workspace.`),
|
|
50
|
+
userId: userIdSchema
|
|
51
|
+
.default("")
|
|
52
|
+
.describe('Your own ID for the end user who owns the workspace. `""` means a tenant-level workspace. It cannot be changed later.'),
|
|
53
|
+
metadata: metadataSchema
|
|
54
|
+
.default({})
|
|
55
|
+
.describe("Your own key-value data, returned as sent."),
|
|
56
|
+
networkPolicy: workspaceNetworkPolicySchema
|
|
57
|
+
.default({ mode: "unrestricted" })
|
|
58
|
+
.describe(networkPolicyDescription),
|
|
50
59
|
})
|
|
51
60
|
.strict();
|
|
52
61
|
export const updateWorkspaceBodySchema = z
|
|
53
62
|
.object({
|
|
54
|
-
name: workspaceNameSchema
|
|
55
|
-
|
|
56
|
-
|
|
63
|
+
name: workspaceNameSchema
|
|
64
|
+
.nullable()
|
|
65
|
+
.optional()
|
|
66
|
+
.describe(`New display name, up to ${MAX_WORKSPACE_NAME_LENGTH} characters, or \`null\` to clear it.`),
|
|
67
|
+
metadata: metadataSchema
|
|
68
|
+
.optional()
|
|
69
|
+
.describe("Replaces the workspace's metadata."),
|
|
70
|
+
networkPolicy: workspaceNetworkPolicySchema
|
|
71
|
+
.optional()
|
|
72
|
+
.describe(`Replaces the network policy. ${networkPolicyDescription}`),
|
|
57
73
|
})
|
|
58
74
|
.strict()
|
|
59
75
|
.refine(hasObjectKeys, { message: "At least one field is required." });
|
|
@@ -4,28 +4,33 @@ export type { ApprovalDecision, ApprovalPolicy, ToolExecutionReference, ToolRefe
|
|
|
4
4
|
export { approvalDecisionSchema, approvalPolicySchema, toolExecutionReferenceSchema, toolReferenceSchema, } from "./entities/agent-approval.ts";
|
|
5
5
|
export type { AgentToolDefinition, AgentToolFileAccessTag, AgentToolGroupTag, AgentToolName, AgentToolTag, AgentToolTags, } from "./entities/agent-tools.ts";
|
|
6
6
|
export { AGENT_TOOL_FILE_ACCESS_TAGS, AGENT_TOOL_GROUPS, AGENT_TOOL_TAGS, AGENT_TOOLS, agentToolNames, chatFunctionNameSchema, } from "./entities/agent-tools.ts";
|
|
7
|
-
export {
|
|
8
|
-
export {
|
|
9
|
-
export {
|
|
7
|
+
export type { AgentStatus } from "./entities/agents.ts";
|
|
8
|
+
export { agentConfigSchema, agentInstructionsSchema, agentModelIdSchema, agentResponseSchema, agentStatusSchema, agentsListQuerySchema, agentsResponseSchema, agentToolsSchema, createAgentBodySchema, updateAgentBodySchema, } from "./entities/agents.ts";
|
|
9
|
+
export { artifactDownloadUrlResponseSchema, artifactFilenameSchema, artifactListItemSchema, artifactsListResponseSchema, } from "./entities/artifacts.ts";
|
|
10
|
+
export { attributionCreateInputSchema, metadataSchema, userIdSchema, } from "./entities/attribution.ts";
|
|
10
11
|
export type { ChatFunctionCallEvent, ChatFunctionDefinition, ChatFunctionDefinitions, ChatFunctionOutcome, ClaimChatFunctionBody, PromptVariables, ResolveChatFunctionBody, UsageSummary, } from "./entities/chat.ts";
|
|
11
12
|
export { blazingAgentsChatMessageMetadataSchema, chatFunctionCallEventSchema, chatFunctionDefinitionSchema, chatFunctionDefinitionsSchema, chatFunctionOutcomeSchema, chatModeSchema, chatRequestBodySchema, chatTriggerSchema, claimChatFunctionBodySchema, claimChatFunctionResponseSchema, generationRequestBodySchema, jsonSchemaShapeSchema, MAX_CHAT_FUNCTION_DEFINITIONS_BYTES, MAX_CHAT_FUNCTION_PAYLOAD_BYTES, MAX_CHAT_FUNCTIONS, promptVariablesSchema, resolveChatFunctionBodySchema, resolveChatFunctionResponseSchema, usageSummarySchema, } from "./entities/chat.ts";
|
|
12
13
|
export { chatConfigurationSchema, chatConnectionSchema, chatConnectionsResponseSchema, chatCredentialsSchema, chatDeliveriesResponseSchema, chatDeliveryListSchema, chatDeliveryListStatusSchema, chatDeliveryResultSchema, chatDeliverySchema, chatDeliveryStatusSchema, chatHealthCheckSchema, chatHealthSchema, chatIdentitySchema, createChatConnectionBodySchema, repairChatDeliveryBodySchema, rotateChatConnectionBodySchema, tenantChatDeliverySchema, updateChatConnectionBodySchema, } from "./entities/chat-connections.ts";
|
|
13
|
-
export {
|
|
14
|
-
export {
|
|
15
|
-
export {
|
|
14
|
+
export type { McpConnectionLiveDetails, McpConnectionTestErrorCode, } from "./entities/mcp-connections.ts";
|
|
15
|
+
export { approveMcpOauthAuthorizationBodySchema, createMcpConnectionBodySchema, forwardedMetadataKeysSchema, mcpAttachmentResponseSchema, mcpAttachmentsResponseSchema, mcpConnectionAuthTypeSchema, mcpConnectionLiveDetailsSchema, mcpConnectionReconnectResultSchema, mcpConnectionResponseSchema, mcpConnectionStatusSchema, mcpConnectionsResponseSchema, mcpConnectionTestErrorCodeSchema, mcpConnectionTestResponseSchema, mcpOauthAuthorizationLaunchResponseSchema, reconnectMcpConnectionBodySchema, updateMcpAttachmentBodySchema, updateMcpConnectionBodySchema, } from "./entities/mcp-connections.ts";
|
|
16
|
+
export type { CreateMemoryBody, Memory, UpdateMemoryBody, } from "./entities/memories.ts";
|
|
17
|
+
export { createMemoryBodySchema, memoriesListResponseSchema, memoryResponseSchema, memorySchema, memoryTextSchema, updateMemoryBodySchema, } from "./entities/memories.ts";
|
|
18
|
+
export { createMerchantConnectionBodySchema, merchantBindingResponseSchema, merchantBindingsResponseSchema, merchantConnectionResponseSchema, merchantConnectionSchema, merchantConnectionStatusSchema, merchantCustomerBindingSchema, merchantEnvironmentSchema, merchantGuardSchema, merchantProviderSchema, merchantUsageEventNextAction, merchantUsageEventNextActionSchema, merchantUsageEventResponseSchema, merchantUsageEventSchema, merchantUsageEventStatusSchema, merchantUsageEventsResponseSchema, merchantUsageSummaryQuerySchema, merchantUsageSummaryResponseSchema, merchantUsageSummarySchema, merchantWorkflowIssueSchema, updateMerchantConnectionBodySchema, upsertMerchantBindingBodySchema, } from "./entities/merchant.ts";
|
|
16
19
|
export { createPromptBodySchema, parsePromptVariables, promptResponseSchema, promptsListQuerySchema, promptsResponseSchema, promptTemplateSchema, renderPromptTemplate, updatePromptBodySchema, } from "./entities/prompts.ts";
|
|
17
20
|
export { createProviderBodySchema, providerListItemSchema, providerModelsResponseSchema, providerResponseSchema, providersResponseSchema, providerTypeSchema, thinkingLevelsResponseSchema, updateProviderBodySchema, } from "./entities/providers.ts";
|
|
18
21
|
export type { ChatSteerConsumedEvent, SessionActivity, SessionInput, SessionInputResponse, SessionInputState, SessionInputsQuery, SessionInputsResponse, StopSessionBody, StopSessionResponse, SubmitSessionInputBody, } from "./entities/session-inputs.ts";
|
|
19
22
|
export { chatSteerConsumedEventSchema, sessionActivitySchema, sessionInputRequestIdSchema, sessionInputResponseSchema, sessionInputSchema, sessionInputStateSchema, sessionInputsQuerySchema, sessionInputsResponseSchema, stopSessionBodySchema, stopSessionResponseSchema, submitSessionInputBodySchema, } from "./entities/session-inputs.ts";
|
|
20
|
-
export type { ContinueToolApprovalsBody, SessionForkedFrom, ToolApprovalContinuationState, ToolApprovalDecision, ToolApprovalsResponse,
|
|
21
|
-
export { continueToolApprovalsBodySchema, latestSessionListItemSchema, latestSessionsListResponseSchema, sessionForkedFromSchema, sessionListItemSchema, sessionMessageSchema, sessionMessagesResponseSchema, sessionResponseSchema, sessionsListResponseSchema, toolApprovalContinuationStateSchema, toolApprovalDecisionSchema, toolApprovalStateSchema, toolApprovalsResponseSchema,
|
|
22
|
-
export { copySkillBodySchema, createSkillBodySchema, skillCopyResultsSchema, skillDetailSchema, skillsListResponseSchema, } from "./entities/skills.ts";
|
|
23
|
-
export type { SpendingLimit, SpendingLimitResponse, SpendingLimitStopDetails,
|
|
24
|
-
export { nextSpendingLimitReset, spendingLimitPeriodSchema, spendingLimitResetIntervalSchema, spendingLimitResponseSchema, spendingLimitSchema, spendingLimitStopDetailsSchema,
|
|
25
|
-
export {
|
|
26
|
-
export {
|
|
23
|
+
export type { ContinueToolApprovalsBody, LatestSessionListItem, SessionForkedFrom, SessionListItem, SessionMessage, ToolApprovalContinuationState, ToolApprovalDecision, ToolApprovalsResponse, TurnStreamErrorEvent, } from "./entities/sessions.ts";
|
|
24
|
+
export { continueToolApprovalsBodySchema, latestSessionListItemSchema, latestSessionsListResponseSchema, sessionForkedFromSchema, sessionListItemSchema, sessionMessageSchema, sessionMessagesResponseSchema, sessionResponseSchema, sessionsListResponseSchema, toolApprovalContinuationSchema, toolApprovalContinuationStateSchema, toolApprovalDecisionSchema, toolApprovalStateSchema, toolApprovalsResponseSchema, turnStreamErrorEventSchema, } from "./entities/sessions.ts";
|
|
25
|
+
export { copySkillBodySchema, createSkillBodySchema, skillArchiveTypeSchema, skillCopyResultsSchema, skillDescriptionSchema, skillDetailSchema, skillFilePathSchema, skillMetadataSchema, skillNameSchema, skillSchema, skillsListResponseSchema, } from "./entities/skills.ts";
|
|
26
|
+
export type { SpendingLimit, SpendingLimitResponse, SpendingLimitStopDetails, UpdateSpendingLimitBody, } from "./entities/spending-limits.ts";
|
|
27
|
+
export { nextSpendingLimitReset, spendingLimitPeriodSchema, spendingLimitResetIntervalSchema, spendingLimitResponseSchema, spendingLimitSchema, spendingLimitStopDetailsSchema, updateSpendingLimitBodySchema, } from "./entities/spending-limits.ts";
|
|
28
|
+
export type { CreateTaskBody, TaskListItem, TaskRunStatus, TaskScheduleInput, UpdateTaskBody, } from "./entities/tasks.ts";
|
|
29
|
+
export { createTaskBodySchema, createTaskResponseSchema, createTaskRunBodySchema, createTaskRunResponseSchema, taskCronConfigSchema, taskIntervalConfigSchema, taskLatestRunSchema, taskListItemSchema, taskOnceConfigSchema, taskResponseSchema, taskRunMessagesResponseSchema, taskRunResponseSchema, taskRunStatusSchema, taskRunsListResponseSchema, taskScheduleInputSchema, taskScheduleKindSchema, tasksListResponseSchema, updateTaskBodySchema, } from "./entities/tasks.ts";
|
|
30
|
+
export type { Quota, TenantDeletion, UpdateTenantSettingsBody, } from "./entities/tenants.ts";
|
|
31
|
+
export { quotaSchema, tenantDeletionSchema, tenantSettingsResponseSchema, updateTenantSettingsBodySchema, } from "./entities/tenants.ts";
|
|
27
32
|
export type { SessionUsageQuery, SessionUsageResponse, UsageBucket, UsageOverviewQuery, UsageOverviewResponse, UsageResponse, UsageTotals, } from "./entities/usage.ts";
|
|
28
33
|
export { sessionUsageQuerySchema, sessionUsageResponseSchema, usageOverviewQuerySchema, usageOverviewResponseSchema, usageResponseSchema, } from "./entities/usage.ts";
|
|
29
34
|
export type { WorkspaceTier } from "./entities/workspaces.ts";
|
|
30
|
-
export { createWorkspaceBodySchema, updateWorkspaceBodySchema, workspaceSchema, workspacesListResponseSchema, workspaceTierSchema, } from "./entities/workspaces.ts";
|
|
31
|
-
export { agentIdSchema, apiKeyTokenSchema, functionCallIdSchema, isAdminAgentId, promptIdSchema, sessionIdSchema, } from "./ids.ts";
|
|
35
|
+
export { createWorkspaceBodySchema, updateWorkspaceBodySchema, workspaceNetworkPolicySchema, workspaceSchema, workspacesListResponseSchema, workspaceTierSchema, } from "./entities/workspaces.ts";
|
|
36
|
+
export { agentIdSchema, apiKeyTokenSchema, chatDeliveryIdSchema, functionCallIdSchema, isAdminAgentId, merchantUsageEventIdSchema, promptIdSchema, sessionIdSchema, } from "./ids.ts";
|
package/dist/contracts/index.js
CHANGED
|
@@ -3,22 +3,22 @@
|
|
|
3
3
|
export { receivedApiErrorResponseSchema } from "./api.js";
|
|
4
4
|
export { approvalDecisionSchema, approvalPolicySchema, toolExecutionReferenceSchema, toolReferenceSchema, } from "./entities/agent-approval.js";
|
|
5
5
|
export { AGENT_TOOL_FILE_ACCESS_TAGS, AGENT_TOOL_GROUPS, AGENT_TOOL_TAGS, AGENT_TOOLS, agentToolNames, chatFunctionNameSchema, } from "./entities/agent-tools.js";
|
|
6
|
-
export { agentConfigSchema, agentResponseSchema, agentStatusSchema, agentsListQuerySchema, agentsResponseSchema, createAgentBodySchema, updateAgentBodySchema, } from "./entities/agents.js";
|
|
7
|
-
export { artifactDownloadUrlResponseSchema, artifactListItemSchema, artifactsListResponseSchema, } from "./entities/artifacts.js";
|
|
8
|
-
export { attributionCreateInputSchema, metadataSchema, } from "./entities/attribution.js";
|
|
6
|
+
export { agentConfigSchema, agentInstructionsSchema, agentModelIdSchema, agentResponseSchema, agentStatusSchema, agentsListQuerySchema, agentsResponseSchema, agentToolsSchema, createAgentBodySchema, updateAgentBodySchema, } from "./entities/agents.js";
|
|
7
|
+
export { artifactDownloadUrlResponseSchema, artifactFilenameSchema, artifactListItemSchema, artifactsListResponseSchema, } from "./entities/artifacts.js";
|
|
8
|
+
export { attributionCreateInputSchema, metadataSchema, userIdSchema, } from "./entities/attribution.js";
|
|
9
9
|
export { blazingAgentsChatMessageMetadataSchema, chatFunctionCallEventSchema, chatFunctionDefinitionSchema, chatFunctionDefinitionsSchema, chatFunctionOutcomeSchema, chatModeSchema, chatRequestBodySchema, chatTriggerSchema, claimChatFunctionBodySchema, claimChatFunctionResponseSchema, generationRequestBodySchema, jsonSchemaShapeSchema, MAX_CHAT_FUNCTION_DEFINITIONS_BYTES, MAX_CHAT_FUNCTION_PAYLOAD_BYTES, MAX_CHAT_FUNCTIONS, promptVariablesSchema, resolveChatFunctionBodySchema, resolveChatFunctionResponseSchema, usageSummarySchema, } from "./entities/chat.js";
|
|
10
10
|
export { chatConfigurationSchema, chatConnectionSchema, chatConnectionsResponseSchema, chatCredentialsSchema, chatDeliveriesResponseSchema, chatDeliveryListSchema, chatDeliveryListStatusSchema, chatDeliveryResultSchema, chatDeliverySchema, chatDeliveryStatusSchema, chatHealthCheckSchema, chatHealthSchema, chatIdentitySchema, createChatConnectionBodySchema, repairChatDeliveryBodySchema, rotateChatConnectionBodySchema, tenantChatDeliverySchema, updateChatConnectionBodySchema, } from "./entities/chat-connections.js";
|
|
11
|
-
export { approveMcpOauthAuthorizationBodySchema, createMcpConnectionBodySchema, mcpAttachmentResponseSchema, mcpAttachmentsResponseSchema, mcpConnectionAuthTypeSchema, mcpConnectionReconnectResultSchema, mcpConnectionResponseSchema, mcpConnectionStatusSchema, mcpConnectionsResponseSchema, mcpConnectionTestErrorCodeSchema, mcpConnectionTestResponseSchema, mcpOauthAuthorizationLaunchResponseSchema, reconnectMcpConnectionBodySchema, updateMcpAttachmentBodySchema, updateMcpConnectionBodySchema, } from "./entities/mcp-connections.js";
|
|
12
|
-
export { createMemoryBodySchema, memoriesListResponseSchema, memoryResponseSchema, memorySchema, updateMemoryBodySchema, } from "./entities/memories.js";
|
|
13
|
-
export { createMerchantConnectionBodySchema, merchantBindingResponseSchema, merchantBindingsResponseSchema, merchantConnectionResponseSchema, merchantConnectionSchema, merchantConnectionStatusSchema, merchantCustomerBindingSchema, merchantEnvironmentSchema, merchantGuardSchema, merchantProviderSchema, merchantUsageEventNextAction, merchantUsageEventNextActionSchema, merchantUsageEventSchema, merchantUsageEventStatusSchema, merchantUsageEventsResponseSchema, merchantUsageSummaryQuerySchema, merchantUsageSummaryResponseSchema, merchantUsageSummarySchema, merchantWorkflowIssueSchema, updateMerchantConnectionBodySchema, upsertMerchantBindingBodySchema, } from "./entities/merchant.js";
|
|
11
|
+
export { approveMcpOauthAuthorizationBodySchema, createMcpConnectionBodySchema, forwardedMetadataKeysSchema, mcpAttachmentResponseSchema, mcpAttachmentsResponseSchema, mcpConnectionAuthTypeSchema, mcpConnectionLiveDetailsSchema, mcpConnectionReconnectResultSchema, mcpConnectionResponseSchema, mcpConnectionStatusSchema, mcpConnectionsResponseSchema, mcpConnectionTestErrorCodeSchema, mcpConnectionTestResponseSchema, mcpOauthAuthorizationLaunchResponseSchema, reconnectMcpConnectionBodySchema, updateMcpAttachmentBodySchema, updateMcpConnectionBodySchema, } from "./entities/mcp-connections.js";
|
|
12
|
+
export { createMemoryBodySchema, memoriesListResponseSchema, memoryResponseSchema, memorySchema, memoryTextSchema, updateMemoryBodySchema, } from "./entities/memories.js";
|
|
13
|
+
export { createMerchantConnectionBodySchema, merchantBindingResponseSchema, merchantBindingsResponseSchema, merchantConnectionResponseSchema, merchantConnectionSchema, merchantConnectionStatusSchema, merchantCustomerBindingSchema, merchantEnvironmentSchema, merchantGuardSchema, merchantProviderSchema, merchantUsageEventNextAction, merchantUsageEventNextActionSchema, merchantUsageEventResponseSchema, merchantUsageEventSchema, merchantUsageEventStatusSchema, merchantUsageEventsResponseSchema, merchantUsageSummaryQuerySchema, merchantUsageSummaryResponseSchema, merchantUsageSummarySchema, merchantWorkflowIssueSchema, updateMerchantConnectionBodySchema, upsertMerchantBindingBodySchema, } from "./entities/merchant.js";
|
|
14
14
|
export { createPromptBodySchema, parsePromptVariables, promptResponseSchema, promptsListQuerySchema, promptsResponseSchema, promptTemplateSchema, renderPromptTemplate, updatePromptBodySchema, } from "./entities/prompts.js";
|
|
15
15
|
export { createProviderBodySchema, providerListItemSchema, providerModelsResponseSchema, providerResponseSchema, providersResponseSchema, providerTypeSchema, thinkingLevelsResponseSchema, updateProviderBodySchema, } from "./entities/providers.js";
|
|
16
16
|
export { chatSteerConsumedEventSchema, sessionActivitySchema, sessionInputRequestIdSchema, sessionInputResponseSchema, sessionInputSchema, sessionInputStateSchema, sessionInputsQuerySchema, sessionInputsResponseSchema, stopSessionBodySchema, stopSessionResponseSchema, submitSessionInputBodySchema, } from "./entities/session-inputs.js";
|
|
17
|
-
export { continueToolApprovalsBodySchema, latestSessionListItemSchema, latestSessionsListResponseSchema, sessionForkedFromSchema, sessionListItemSchema, sessionMessageSchema, sessionMessagesResponseSchema, sessionResponseSchema, sessionsListResponseSchema, toolApprovalContinuationStateSchema, toolApprovalDecisionSchema, toolApprovalStateSchema, toolApprovalsResponseSchema,
|
|
18
|
-
export { copySkillBodySchema, createSkillBodySchema, skillCopyResultsSchema, skillDetailSchema, skillsListResponseSchema, } from "./entities/skills.js";
|
|
19
|
-
export { nextSpendingLimitReset, spendingLimitPeriodSchema, spendingLimitResetIntervalSchema, spendingLimitResponseSchema, spendingLimitSchema, spendingLimitStopDetailsSchema,
|
|
20
|
-
export { createTaskBodySchema, createTaskResponseSchema, createTaskRunBodySchema, createTaskRunResponseSchema, taskCronConfigSchema, taskIntervalConfigSchema, taskListItemSchema, taskOnceConfigSchema, taskResponseSchema, taskRunMessagesResponseSchema, taskRunResponseSchema, taskRunStatusSchema, taskRunsListResponseSchema, taskScheduleInputSchema, taskScheduleKindSchema, tasksListResponseSchema, updateTaskBodySchema, } from "./entities/tasks.js";
|
|
21
|
-
export { quotaSchema,
|
|
17
|
+
export { continueToolApprovalsBodySchema, latestSessionListItemSchema, latestSessionsListResponseSchema, sessionForkedFromSchema, sessionListItemSchema, sessionMessageSchema, sessionMessagesResponseSchema, sessionResponseSchema, sessionsListResponseSchema, toolApprovalContinuationSchema, toolApprovalContinuationStateSchema, toolApprovalDecisionSchema, toolApprovalStateSchema, toolApprovalsResponseSchema, turnStreamErrorEventSchema, } from "./entities/sessions.js";
|
|
18
|
+
export { copySkillBodySchema, createSkillBodySchema, skillArchiveTypeSchema, skillCopyResultsSchema, skillDescriptionSchema, skillDetailSchema, skillFilePathSchema, skillMetadataSchema, skillNameSchema, skillSchema, skillsListResponseSchema, } from "./entities/skills.js";
|
|
19
|
+
export { nextSpendingLimitReset, spendingLimitPeriodSchema, spendingLimitResetIntervalSchema, spendingLimitResponseSchema, spendingLimitSchema, spendingLimitStopDetailsSchema, updateSpendingLimitBodySchema, } from "./entities/spending-limits.js";
|
|
20
|
+
export { createTaskBodySchema, createTaskResponseSchema, createTaskRunBodySchema, createTaskRunResponseSchema, taskCronConfigSchema, taskIntervalConfigSchema, taskLatestRunSchema, taskListItemSchema, taskOnceConfigSchema, taskResponseSchema, taskRunMessagesResponseSchema, taskRunResponseSchema, taskRunStatusSchema, taskRunsListResponseSchema, taskScheduleInputSchema, taskScheduleKindSchema, tasksListResponseSchema, updateTaskBodySchema, } from "./entities/tasks.js";
|
|
21
|
+
export { quotaSchema, tenantDeletionSchema, tenantSettingsResponseSchema, updateTenantSettingsBodySchema, } from "./entities/tenants.js";
|
|
22
22
|
export { sessionUsageQuerySchema, sessionUsageResponseSchema, usageOverviewQuerySchema, usageOverviewResponseSchema, usageResponseSchema, } from "./entities/usage.js";
|
|
23
|
-
export { createWorkspaceBodySchema, updateWorkspaceBodySchema, workspaceSchema, workspacesListResponseSchema, workspaceTierSchema, } from "./entities/workspaces.js";
|
|
24
|
-
export { agentIdSchema, apiKeyTokenSchema, functionCallIdSchema, isAdminAgentId, promptIdSchema, sessionIdSchema, } from "./ids.js";
|
|
23
|
+
export { createWorkspaceBodySchema, updateWorkspaceBodySchema, workspaceNetworkPolicySchema, workspaceSchema, workspacesListResponseSchema, workspaceTierSchema, } from "./entities/workspaces.js";
|
|
24
|
+
export { agentIdSchema, apiKeyTokenSchema, chatDeliveryIdSchema, functionCallIdSchema, isAdminAgentId, merchantUsageEventIdSchema, promptIdSchema, sessionIdSchema, } from "./ids.js";
|