@archastro/sdk 0.5.0 → 0.5.3
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/README.md +86 -0
- package/dist/auth.d.ts +143 -0
- package/dist/auth.d.ts.map +1 -1
- package/dist/auth.js +187 -1
- package/dist/auth.js.map +1 -1
- package/dist/client.d.ts +26 -0
- package/dist/client.d.ts.map +1 -1
- package/dist/client.js +27 -1
- package/dist/client.js.map +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +2 -2
- package/dist/index.js.map +1 -1
- package/dist/types/ai.d.ts +150 -12
- package/dist/types/ai.d.ts.map +1 -1
- package/dist/types/ai.js +71 -41
- package/dist/types/ai.js.map +1 -1
- package/dist/types/artifacts.d.ts +81 -24
- package/dist/types/artifacts.d.ts.map +1 -1
- package/dist/types/artifacts.js +39 -21
- package/dist/types/artifacts.js.map +1 -1
- package/dist/types/automations.d.ts +41 -9
- package/dist/types/automations.d.ts.map +1 -1
- package/dist/types/automations.js +25 -17
- package/dist/types/automations.js.map +1 -1
- package/dist/types/chat.d.ts +21185 -39
- package/dist/types/chat.d.ts.map +1 -1
- package/dist/types/chat.js +64 -8
- package/dist/types/chat.js.map +1 -1
- package/dist/types/common.d.ts +16970 -2136
- package/dist/types/common.d.ts.map +1 -1
- package/dist/types/common.js +1695 -332
- package/dist/types/common.js.map +1 -1
- package/dist/types/config.d.ts +239 -31
- package/dist/types/config.d.ts.map +1 -1
- package/dist/types/config.js +86 -34
- package/dist/types/config.js.map +1 -1
- package/dist/types/image.d.ts +27 -4
- package/dist/types/image.d.ts.map +1 -1
- package/dist/types/image.js +17 -10
- package/dist/types/image.js.map +1 -1
- package/dist/types/index.d.ts +2 -1
- package/dist/types/index.d.ts.map +1 -1
- package/dist/types/index.js +3 -2
- package/dist/types/index.js.map +1 -1
- package/dist/types/invites.d.ts +20 -11
- package/dist/types/invites.d.ts.map +1 -1
- package/dist/types/invites.js +9 -12
- package/dist/types/invites.js.map +1 -1
- package/dist/types/notifications.d.ts +163 -0
- package/dist/types/notifications.d.ts.map +1 -0
- package/dist/types/notifications.js +44 -0
- package/dist/types/notifications.js.map +1 -0
- package/dist/types/teams.d.ts +1628 -231
- package/dist/types/teams.d.ts.map +1 -1
- package/dist/types/teams.js +76 -45
- package/dist/types/teams.js.map +1 -1
- package/dist/types/threads.d.ts +997 -243
- package/dist/types/threads.d.ts.map +1 -1
- package/dist/types/threads.js +84 -51
- package/dist/types/threads.js.map +1 -1
- package/dist/types/users.d.ts +98 -18
- package/dist/types/users.d.ts.map +1 -1
- package/dist/types/users.js +43 -18
- package/dist/types/users.js.map +1 -1
- package/dist/v1/resources/activity_feed.d.ts +89 -0
- package/dist/v1/resources/activity_feed.d.ts.map +1 -1
- package/dist/v1/resources/activity_feed.js +56 -2
- package/dist/v1/resources/activity_feed.js.map +1 -1
- package/dist/v1/resources/agent_computers.d.ts +48 -2
- package/dist/v1/resources/agent_computers.d.ts.map +1 -1
- package/dist/v1/resources/agent_computers.js +48 -1
- package/dist/v1/resources/agent_computers.js.map +1 -1
- package/dist/v1/resources/agent_env_vars.d.ts +50 -0
- package/dist/v1/resources/agent_env_vars.d.ts.map +1 -0
- package/dist/v1/resources/agent_env_vars.js +56 -0
- package/dist/v1/resources/agent_env_vars.js.map +1 -0
- package/dist/v1/resources/agent_health_actions.d.ts +43 -0
- package/dist/v1/resources/agent_health_actions.d.ts.map +1 -0
- package/dist/v1/resources/agent_health_actions.js +50 -0
- package/dist/v1/resources/agent_health_actions.js.map +1 -0
- package/dist/v1/resources/agent_installations.d.ts +100 -0
- package/dist/v1/resources/agent_installations.d.ts.map +1 -1
- package/dist/v1/resources/agent_installations.js +106 -2
- package/dist/v1/resources/agent_installations.js.map +1 -1
- package/dist/v1/resources/agent_routine_runs.d.ts +33 -0
- package/dist/v1/resources/agent_routine_runs.d.ts.map +1 -0
- package/dist/v1/resources/agent_routine_runs.js +48 -0
- package/dist/v1/resources/agent_routine_runs.js.map +1 -0
- package/dist/v1/resources/agent_routines.d.ts +148 -2
- package/dist/v1/resources/agent_routines.d.ts.map +1 -1
- package/dist/v1/resources/agent_routines.js +168 -3
- package/dist/v1/resources/agent_routines.js.map +1 -1
- package/dist/v1/resources/agent_sessions.d.ts +118 -1
- package/dist/v1/resources/agent_sessions.d.ts.map +1 -1
- package/dist/v1/resources/agent_sessions.js +134 -2
- package/dist/v1/resources/agent_sessions.js.map +1 -1
- package/dist/v1/resources/agent_skills.d.ts +83 -1
- package/dist/v1/resources/agent_skills.d.ts.map +1 -1
- package/dist/v1/resources/agent_skills.js +87 -2
- package/dist/v1/resources/agent_skills.js.map +1 -1
- package/dist/v1/resources/agent_tools.d.ts +109 -2
- package/dist/v1/resources/agent_tools.d.ts.map +1 -1
- package/dist/v1/resources/agent_tools.js +114 -2
- package/dist/v1/resources/agent_tools.js.map +1 -1
- package/dist/v1/resources/agents.d.ts +517 -9
- package/dist/v1/resources/agents.d.ts.map +1 -1
- package/dist/v1/resources/agents.js +515 -12
- package/dist/v1/resources/agents.js.map +1 -1
- package/dist/v1/resources/ai.d.ts +93 -0
- package/dist/v1/resources/ai.d.ts.map +1 -1
- package/dist/v1/resources/ai.js +89 -1
- package/dist/v1/resources/ai.js.map +1 -1
- package/dist/v1/resources/artifacts.d.ts +73 -0
- package/dist/v1/resources/artifacts.d.ts.map +1 -1
- package/dist/v1/resources/artifacts.js +74 -2
- package/dist/v1/resources/artifacts.js.map +1 -1
- package/dist/v1/resources/automation_runs.d.ts +8 -4
- package/dist/v1/resources/automation_runs.d.ts.map +1 -1
- package/dist/v1/resources/automation_runs.js +9 -5
- package/dist/v1/resources/automation_runs.js.map +1 -1
- package/dist/v1/resources/automations.d.ts +20 -0
- package/dist/v1/resources/automations.d.ts.map +1 -1
- package/dist/v1/resources/automations.js +21 -1
- package/dist/v1/resources/automations.js.map +1 -1
- package/dist/v1/resources/bug_reports.d.ts +29 -0
- package/dist/v1/resources/bug_reports.d.ts.map +1 -0
- package/dist/v1/resources/bug_reports.js +29 -0
- package/dist/v1/resources/bug_reports.js.map +1 -0
- package/dist/v1/resources/config.d.ts +429 -4
- package/dist/v1/resources/config.d.ts.map +1 -1
- package/dist/v1/resources/config.js +493 -9
- package/dist/v1/resources/config.js.map +1 -1
- package/dist/v1/resources/custom_objects.d.ts +117 -2
- package/dist/v1/resources/custom_objects.d.ts.map +1 -1
- package/dist/v1/resources/custom_objects.js +132 -3
- package/dist/v1/resources/custom_objects.js.map +1 -1
- package/dist/v1/resources/files.d.ts +62 -0
- package/dist/v1/resources/files.d.ts.map +1 -0
- package/dist/v1/resources/files.js +58 -0
- package/dist/v1/resources/files.js.map +1 -0
- package/dist/v1/resources/index.d.ts +13 -0
- package/dist/v1/resources/index.d.ts.map +1 -1
- package/dist/v1/resources/index.js +14 -1
- package/dist/v1/resources/index.js.map +1 -1
- package/dist/v1/resources/installation_sources.d.ts +12 -0
- package/dist/v1/resources/installation_sources.d.ts.map +1 -1
- package/dist/v1/resources/installation_sources.js +13 -1
- package/dist/v1/resources/installation_sources.js.map +1 -1
- package/dist/v1/resources/invites.d.ts +15 -0
- package/dist/v1/resources/invites.d.ts.map +1 -1
- package/dist/v1/resources/invites.js +16 -1
- package/dist/v1/resources/invites.js.map +1 -1
- package/dist/v1/resources/knowledge_documents.d.ts +104 -0
- package/dist/v1/resources/knowledge_documents.d.ts.map +1 -0
- package/dist/v1/resources/knowledge_documents.js +112 -0
- package/dist/v1/resources/knowledge_documents.js.map +1 -0
- package/dist/v1/resources/knowledge_sources.d.ts +190 -0
- package/dist/v1/resources/knowledge_sources.d.ts.map +1 -0
- package/dist/v1/resources/knowledge_sources.js +176 -0
- package/dist/v1/resources/knowledge_sources.js.map +1 -0
- package/dist/v1/resources/kv.d.ts +73 -0
- package/dist/v1/resources/kv.d.ts.map +1 -1
- package/dist/v1/resources/kv.js +96 -3
- package/dist/v1/resources/kv.js.map +1 -1
- package/dist/v1/resources/notification_preferences.d.ts +61 -0
- package/dist/v1/resources/notification_preferences.d.ts.map +1 -0
- package/dist/v1/resources/notification_preferences.js +65 -0
- package/dist/v1/resources/notification_preferences.js.map +1 -0
- package/dist/v1/resources/notifications.d.ts +133 -0
- package/dist/v1/resources/notifications.d.ts.map +1 -0
- package/dist/v1/resources/notifications.js +136 -0
- package/dist/v1/resources/notifications.js.map +1 -0
- package/dist/v1/resources/orgs.d.ts +18 -0
- package/dist/v1/resources/orgs.d.ts.map +1 -1
- package/dist/v1/resources/orgs.js +30 -2
- package/dist/v1/resources/orgs.js.map +1 -1
- package/dist/v1/resources/slack_channel_bindings.d.ts +101 -0
- package/dist/v1/resources/slack_channel_bindings.d.ts.map +1 -0
- package/dist/v1/resources/slack_channel_bindings.js +114 -0
- package/dist/v1/resources/slack_channel_bindings.js.map +1 -0
- package/dist/v1/resources/solution_categories.d.ts +36 -0
- package/dist/v1/resources/solution_categories.d.ts.map +1 -0
- package/dist/v1/resources/solution_categories.js +55 -0
- package/dist/v1/resources/solution_categories.js.map +1 -0
- package/dist/v1/resources/solution_tags.d.ts +37 -0
- package/dist/v1/resources/solution_tags.d.ts.map +1 -0
- package/dist/v1/resources/solution_tags.js +54 -0
- package/dist/v1/resources/solution_tags.js.map +1 -0
- package/dist/v1/resources/solutions.d.ts +309 -0
- package/dist/v1/resources/solutions.d.ts.map +1 -0
- package/dist/v1/resources/solutions.js +214 -0
- package/dist/v1/resources/solutions.js.map +1 -0
- package/dist/v1/resources/team_memberships.d.ts +31 -0
- package/dist/v1/resources/team_memberships.d.ts.map +1 -1
- package/dist/v1/resources/team_memberships.js +49 -2
- package/dist/v1/resources/team_memberships.js.map +1 -1
- package/dist/v1/resources/teams.d.ts +458 -49
- package/dist/v1/resources/teams.d.ts.map +1 -1
- package/dist/v1/resources/teams.js +319 -27
- package/dist/v1/resources/teams.js.map +1 -1
- package/dist/v1/resources/thread_messages.d.ts +70 -0
- package/dist/v1/resources/thread_messages.d.ts.map +1 -1
- package/dist/v1/resources/thread_messages.js +85 -2
- package/dist/v1/resources/thread_messages.js.map +1 -1
- package/dist/v1/resources/threads.d.ts +201 -0
- package/dist/v1/resources/threads.d.ts.map +1 -1
- package/dist/v1/resources/threads.js +220 -4
- package/dist/v1/resources/threads.js.map +1 -1
- package/dist/v1/resources/users.d.ts +213 -39
- package/dist/v1/resources/users.d.ts.map +1 -1
- package/dist/v1/resources/users.js +121 -16
- package/dist/v1/resources/users.js.map +1 -1
- package/dist/v1.d.ts +26 -0
- package/dist/v1.d.ts.map +1 -1
- package/dist/v1.js +40 -1
- package/dist/v1.js.map +1 -1
- package/package.json +4 -2
- package/dist/types/agents.d.ts +0 -2084
- package/dist/types/agents.d.ts.map +0 -1
- package/dist/types/agents.js +0 -203
- package/dist/types/agents.js.map +0 -1
- package/dist/types/members.d.ts +0 -99
- package/dist/types/members.d.ts.map +0 -1
- package/dist/types/members.js +0 -36
- package/dist/types/members.js.map +0 -1
- package/dist/types/orgs.d.ts +0 -193
- package/dist/types/orgs.d.ts.map +0 -1
- package/dist/types/orgs.js +0 -69
- package/dist/types/orgs.js.map +0 -1
- package/dist/types/reactions.d.ts +0 -29
- package/dist/types/reactions.d.ts.map +0 -1
- package/dist/types/reactions.js +0 -15
- package/dist/types/reactions.js.map +0 -1
- package/dist/types/schedules.d.ts +0 -32
- package/dist/types/schedules.d.ts.map +0 -1
- package/dist/types/schedules.js +0 -16
- package/dist/types/schedules.js.map +0 -1
- package/dist/types/system.d.ts +0 -23
- package/dist/types/system.d.ts.map +0 -1
- package/dist/types/system.js +0 -13
- package/dist/types/system.js.map +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"agents.js","sourceRoot":"","sources":["../../../src/v1/resources/agents.ts"],"names":[],"mappings":"AAAA,yDAAyD;AACzD,wEAAwE;AACxE,6BAA6B;
|
|
1
|
+
{"version":3,"file":"agents.js","sourceRoot":"","sources":["../../../src/v1/resources/agents.ts"],"names":[],"mappings":"AAAA,yDAAyD;AACzD,wEAAwE;AACxE,6B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AAK,SAAS,CAAC,CAAC;IAC7D,CAAC;IAED;;;;;;;;;;;;;;;;;;;;;;OAsBG;IACH,KAAK,CAAC,MAAM,CAAC,KAAa,EAAE,KAA6J;QACvL,OAAO,IAAI,CAAC,IAAI,CAAC,OAAO,CAAC,kBAAkB,KAAK,SAAS,EAAE,EAAE,MAAM,EAAE,MAAM,EAAE,IAAI,EAAE,KAAK,EAAE,CAAC,CAAC;IAC9F,CAAC;IAED;;;;;;;;;;;;;;OAcG;IACH,KAAK,CAAC,OAAO,CAAC,KAAa,EAAE,KAAmV;QAC9W,OAAO,IAAI,CAAC,IAAI,CAAC,OAAO,CAAC,kBAAkB,KAAK,UAAU,EAAE,EAAE,MAAM,EAAE,MAAM,EAAE,IAAI,EAAE,KAAK,EAAE,CAAC,CAAC;IAC/F,CAAC;IAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OAgCG;IACH,KAAK,CAAC,OAAO,CAAC,KAAa,EAAE,KAAyY;QACpa,OAAO,IAAI,CAAC,IAAI,CAAC,OAAO,CAAC,kBAAkB,KAAK,UAAU,EAAE,EAAE,MAAM,EAAE,MAAM,EAAE,IAAI,EAAE,KAAK,EAAE,CAAC,CAAC;IAC/F,CAAC;CACF"}
|
|
@@ -3,6 +3,23 @@ import type { AICompletionResult, AIImageResult } from "../../types/ai.js";
|
|
|
3
3
|
export declare class ChatResource {
|
|
4
4
|
private http;
|
|
5
5
|
constructor(http: HttpClient);
|
|
6
|
+
/**
|
|
7
|
+
* Create a chat completion
|
|
8
|
+
* Sends a list of messages to the configured AI provider and returns a single
|
|
9
|
+
* completion. Use this endpoint when you want direct, low-level access to the
|
|
10
|
+
* underlying model without any workflow or agent orchestration.
|
|
11
|
+
* The authenticated app must have the `llm_calls` entitlement enabled on its
|
|
12
|
+
* plan. Requests that exceed the plan quota are rejected with `402`. Token
|
|
13
|
+
* usage is recorded against the authenticated app and organization.
|
|
14
|
+
* Supply `tools` and `tool_choice` to enable OpenAI-compatible function
|
|
15
|
+
* calling. Use `server_tools` to activate platform-managed tools such as
|
|
16
|
+
* search that run on the server side before the response is returned.
|
|
17
|
+
* @param input - Request body.
|
|
18
|
+
* @param input.context - Key-value map used to resolve template variables in message content. Omit if messages contain no templates.
|
|
19
|
+
* @param input.messages - Ordered list of conversation messages to send to the model.
|
|
20
|
+
* @param input.opts - Model and sampling configuration for this request.
|
|
21
|
+
* @returns The completed AI response, including the generated message, finish reason, and token usage.
|
|
22
|
+
*/
|
|
6
23
|
completions(input: {
|
|
7
24
|
context?: Record<string, unknown> | undefined;
|
|
8
25
|
messages: {
|
|
@@ -29,6 +46,7 @@ export declare class ChatResource {
|
|
|
29
46
|
model: string;
|
|
30
47
|
server_tools?: Record<string, unknown>[] | undefined;
|
|
31
48
|
temperature?: number | undefined;
|
|
49
|
+
tool_choice?: string | undefined;
|
|
32
50
|
tools?: {
|
|
33
51
|
function: {
|
|
34
52
|
description?: string | undefined;
|
|
@@ -39,15 +57,52 @@ export declare class ChatResource {
|
|
|
39
57
|
}[] | undefined;
|
|
40
58
|
};
|
|
41
59
|
}): Promise<AICompletionResult>;
|
|
60
|
+
/**
|
|
61
|
+
* List available AI models
|
|
62
|
+
* Returns the set of AI models that can be used with the chat completion and
|
|
63
|
+
* workflow endpoints. The list reflects models currently enabled for the
|
|
64
|
+
* platform and includes each model's identifier and whether it is the default.
|
|
65
|
+
* Use the `model` field from any entry in `data` as the value for
|
|
66
|
+
* `opts.model` when calling the completions or workflows endpoint.
|
|
67
|
+
* @returns Successful response
|
|
68
|
+
*/
|
|
42
69
|
models(): Promise<{
|
|
43
70
|
data: {
|
|
71
|
+
default: boolean;
|
|
44
72
|
id: string;
|
|
73
|
+
name: string;
|
|
45
74
|
}[];
|
|
46
75
|
}>;
|
|
47
76
|
}
|
|
48
77
|
export declare class ImageResource {
|
|
49
78
|
private http;
|
|
50
79
|
constructor(http: HttpClient);
|
|
80
|
+
/**
|
|
81
|
+
* Edit an image with a text prompt
|
|
82
|
+
* Applies a text-guided edit to one or more source images and returns the
|
|
83
|
+
* resulting image. Pass the source images as base64-encoded objects in the
|
|
84
|
+
* `images` array alongside a `prompt` describing the desired modification.
|
|
85
|
+
* The underlying provider is selected by the `model` parameter. Omit `model`
|
|
86
|
+
* to use the platform default. Size, quality, style, and format options are
|
|
87
|
+
* forwarded to the provider as-is; unsupported combinations for a given model
|
|
88
|
+
* return a 422 error with the provider's error message.
|
|
89
|
+
* This endpoint requires authentication. The request is billed against the
|
|
90
|
+
* workspace associated with the authenticated user.
|
|
91
|
+
* @param input - Request body.
|
|
92
|
+
* @param input.aspect_ratio - Desired aspect ratio of the output, e.g. `"1:1"` or `"16:9"`. Not supported by all models; omit to use the model's default.
|
|
93
|
+
* @param input.background - Background treatment for the output. Accepted values and behavior are model-dependent.
|
|
94
|
+
* @param input.height - Explicit output height in pixels. Takes precedence over `size` when both are provided. Not supported by all models.
|
|
95
|
+
* @param input.image_size - Output resolution tier for Gemini models, e.g. `"1K"`, `"2K"`, or `"4K"`. Ignored by non-Gemini models.
|
|
96
|
+
* @param input.images - One or more source images to edit. Each image must be supplied as a base64-encoded object.
|
|
97
|
+
* @param input.model - Model identifier to use for editing. Omit to use the platform default image model.
|
|
98
|
+
* @param input.output_format - Desired MIME type or format for the returned image. Common values: `"png"`, `"jpeg"`, `"webp"`. Defaults to the model's native format.
|
|
99
|
+
* @param input.prompt - Natural-language description of the edit to apply to the source image(s).
|
|
100
|
+
* @param input.quality - Quality preset for the output image. Accepted values and behavior are model-dependent.
|
|
101
|
+
* @param input.size - Output dimensions as a WxH string, e.g. `"1024x1024"`. Applies to OpenAI-compatible models. Omit to use the model's default.
|
|
102
|
+
* @param input.style - Style preset applied to the edit. Accepted values and behavior are model-dependent.
|
|
103
|
+
* @param input.width - Explicit output width in pixels. Takes precedence over `size` when both are provided. Not supported by all models.
|
|
104
|
+
* @returns The resulting edited image, including base64 data or a URL depending on the model.
|
|
105
|
+
*/
|
|
51
106
|
edits(input: {
|
|
52
107
|
aspect_ratio?: string | undefined;
|
|
53
108
|
background?: string | undefined;
|
|
@@ -65,6 +120,32 @@ export declare class ImageResource {
|
|
|
65
120
|
style?: string | undefined;
|
|
66
121
|
width?: number | undefined;
|
|
67
122
|
}): Promise<AIImageResult>;
|
|
123
|
+
/**
|
|
124
|
+
* Generate an image from a text prompt
|
|
125
|
+
* Generates one or more images from a natural-language `prompt` using the
|
|
126
|
+
* specified AI image model. The response contains the first generated image;
|
|
127
|
+
* use `n` to request additional images (where supported by the model).
|
|
128
|
+
* The underlying provider is selected by the `model` parameter. Omit `model`
|
|
129
|
+
* to use the platform default. Size, quality, style, and format options are
|
|
130
|
+
* forwarded to the provider as-is; unsupported combinations for a given model
|
|
131
|
+
* return a 422 error with the provider's error message.
|
|
132
|
+
* This endpoint requires authentication. The request is billed against the
|
|
133
|
+
* workspace associated with the authenticated user.
|
|
134
|
+
* @param input - Request body.
|
|
135
|
+
* @param input.aspect_ratio - Desired aspect ratio of the output, e.g. `"1:1"` or `"16:9"`. Not supported by all models; omit to use the model's default.
|
|
136
|
+
* @param input.background - Background treatment for the output. Accepted values and behavior are model-dependent.
|
|
137
|
+
* @param input.height - Explicit output height in pixels. Takes precedence over `size` when both are provided. Not supported by all models.
|
|
138
|
+
* @param input.image_size - Output resolution tier for Gemini models, e.g. `"1K"`, `"2K"`, or `"4K"`. Ignored by non-Gemini models.
|
|
139
|
+
* @param input.model - Model identifier to use for generation. Omit to use the platform default image model.
|
|
140
|
+
* @param input.n - Number of images to generate. Defaults to `1`. Values greater than `1` are only supported by models that allow batch generation.
|
|
141
|
+
* @param input.output_format - Desired MIME type or format for the returned image. Common values: `"png"`, `"jpeg"`, `"webp"`. Defaults to the model's native format.
|
|
142
|
+
* @param input.prompt - Natural-language description of the image to generate.
|
|
143
|
+
* @param input.quality - Quality preset for the output image. Accepted values and behavior are model-dependent.
|
|
144
|
+
* @param input.size - Output dimensions as a WxH string, e.g. `"1024x1024"`. Applies to OpenAI-compatible models. Omit to use the model's default.
|
|
145
|
+
* @param input.style - Style preset applied to the generated image. Accepted values and behavior are model-dependent.
|
|
146
|
+
* @param input.width - Explicit output width in pixels. Takes precedence over `size` when both are provided. Not supported by all models.
|
|
147
|
+
* @returns The generated image, including base64 data or a URL depending on the model.
|
|
148
|
+
*/
|
|
68
149
|
generations(input: {
|
|
69
150
|
aspect_ratio?: string | undefined;
|
|
70
151
|
background?: string | undefined;
|
|
@@ -79,9 +160,21 @@ export declare class ImageResource {
|
|
|
79
160
|
style?: string | undefined;
|
|
80
161
|
width?: number | undefined;
|
|
81
162
|
}): Promise<AIImageResult>;
|
|
163
|
+
/**
|
|
164
|
+
* List available image generation models
|
|
165
|
+
* Returns the list of image generation models available on the platform.
|
|
166
|
+
* Exactly one entry in the list carries `default: true`, indicating the model
|
|
167
|
+
* used when no `model` parameter is supplied to the generation or editing
|
|
168
|
+
* endpoints.
|
|
169
|
+
* This endpoint requires authentication and reflects the models enabled for
|
|
170
|
+
* the authenticated user's workspace.
|
|
171
|
+
* @returns Successful response
|
|
172
|
+
*/
|
|
82
173
|
models(): Promise<{
|
|
83
174
|
data: {
|
|
175
|
+
default: boolean;
|
|
84
176
|
id: string;
|
|
177
|
+
name: string;
|
|
85
178
|
}[];
|
|
86
179
|
}>;
|
|
87
180
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ai.d.ts","sourceRoot":"","sources":["../../../src/v1/resources/ai.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,UAAU,EAAE,MAAM,8BAA8B,CAAC;AAC1D,OAAO,KAAK,EAAE,kBAAkB,EAAE,aAAa,EAAE,MAAM,mBAAmB,CAAC;AAE3E,qBAAa,YAAY;IACX,OAAO,CAAC,IAAI;gBAAJ,IAAI,EAAE,UAAU;
|
|
1
|
+
{"version":3,"file":"ai.d.ts","sourceRoot":"","sources":["../../../src/v1/resources/ai.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,UAAU,EAAE,MAAM,8BAA8B,CAAC;AAC1D,OAAO,KAAK,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. All Rights Reserved.
|
|
2
2
|
// This file is auto-generated by @archastro/sdk-generator. Do not edit.
|
|
3
|
-
// Content hash:
|
|
3
|
+
// Content hash: 7e929808992d
|
|
4
4
|
export class ChatResource {
|
|
5
5
|
http;
|
|
6
6
|
constructor(http) {
|
|
7
7
|
this.http = http;
|
|
8
8
|
}
|
|
9
|
+
/**
|
|
10
|
+
* Create a chat completion
|
|
11
|
+
* Sends a list of messages to the configured AI provider and returns a single
|
|
12
|
+
* completion. Use this endpoint when you want direct, low-level access to the
|
|
13
|
+
* underlying model without any workflow or agent orchestration.
|
|
14
|
+
* The authenticated app must have the `llm_calls` entitlement enabled on its
|
|
15
|
+
* plan. Requests that exceed the plan quota are rejected with `402`. Token
|
|
16
|
+
* usage is recorded against the authenticated app and organization.
|
|
17
|
+
* Supply `tools` and `tool_choice` to enable OpenAI-compatible function
|
|
18
|
+
* calling. Use `server_tools` to activate platform-managed tools such as
|
|
19
|
+
* search that run on the server side before the response is returned.
|
|
20
|
+
* @param input - Request body.
|
|
21
|
+
* @param input.context - Key-value map used to resolve template variables in message content. Omit if messages contain no templates.
|
|
22
|
+
* @param input.messages - Ordered list of conversation messages to send to the model.
|
|
23
|
+
* @param input.opts - Model and sampling configuration for this request.
|
|
24
|
+
* @returns The completed AI response, including the generated message, finish reason, and token usage.
|
|
25
|
+
*/
|
|
9
26
|
async completions(input) {
|
|
10
27
|
return this.http.request(`/api/v1/ai/chat/completions`, { method: "POST", body: input });
|
|
11
28
|
}
|
|
29
|
+
/**
|
|
30
|
+
* List available AI models
|
|
31
|
+
* Returns the set of AI models that can be used with the chat completion and
|
|
32
|
+
* workflow endpoints. The list reflects models currently enabled for the
|
|
33
|
+
* platform and includes each model's identifier and whether it is the default.
|
|
34
|
+
* Use the `model` field from any entry in `data` as the value for
|
|
35
|
+
* `opts.model` when calling the completions or workflows endpoint.
|
|
36
|
+
* @returns Successful response
|
|
37
|
+
*/
|
|
12
38
|
async models() {
|
|
13
39
|
return this.http.request(`/api/v1/ai/chat/models`);
|
|
14
40
|
}
|
|
@@ -18,12 +44,74 @@ export class ImageResource {
|
|
|
18
44
|
constructor(http) {
|
|
19
45
|
this.http = http;
|
|
20
46
|
}
|
|
47
|
+
/**
|
|
48
|
+
* Edit an image with a text prompt
|
|
49
|
+
* Applies a text-guided edit to one or more source images and returns the
|
|
50
|
+
* resulting image. Pass the source images as base64-encoded objects in the
|
|
51
|
+
* `images` array alongside a `prompt` describing the desired modification.
|
|
52
|
+
* The underlying provider is selected by the `model` parameter. Omit `model`
|
|
53
|
+
* to use the platform default. Size, quality, style, and format options are
|
|
54
|
+
* forwarded to the provider as-is; unsupported combinations for a given model
|
|
55
|
+
* return a 422 error with the provider's error message.
|
|
56
|
+
* This endpoint requires authentication. The request is billed against the
|
|
57
|
+
* workspace associated with the authenticated user.
|
|
58
|
+
* @param input - Request body.
|
|
59
|
+
* @param input.aspect_ratio - Desired aspect ratio of the output, e.g. `"1:1"` or `"16:9"`. Not supported by all models; omit to use the model's default.
|
|
60
|
+
* @param input.background - Background treatment for the output. Accepted values and behavior are model-dependent.
|
|
61
|
+
* @param input.height - Explicit output height in pixels. Takes precedence over `size` when both are provided. Not supported by all models.
|
|
62
|
+
* @param input.image_size - Output resolution tier for Gemini models, e.g. `"1K"`, `"2K"`, or `"4K"`. Ignored by non-Gemini models.
|
|
63
|
+
* @param input.images - One or more source images to edit. Each image must be supplied as a base64-encoded object.
|
|
64
|
+
* @param input.model - Model identifier to use for editing. Omit to use the platform default image model.
|
|
65
|
+
* @param input.output_format - Desired MIME type or format for the returned image. Common values: `"png"`, `"jpeg"`, `"webp"`. Defaults to the model's native format.
|
|
66
|
+
* @param input.prompt - Natural-language description of the edit to apply to the source image(s).
|
|
67
|
+
* @param input.quality - Quality preset for the output image. Accepted values and behavior are model-dependent.
|
|
68
|
+
* @param input.size - Output dimensions as a WxH string, e.g. `"1024x1024"`. Applies to OpenAI-compatible models. Omit to use the model's default.
|
|
69
|
+
* @param input.style - Style preset applied to the edit. Accepted values and behavior are model-dependent.
|
|
70
|
+
* @param input.width - Explicit output width in pixels. Takes precedence over `size` when both are provided. Not supported by all models.
|
|
71
|
+
* @returns The resulting edited image, including base64 data or a URL depending on the model.
|
|
72
|
+
*/
|
|
21
73
|
async edits(input) {
|
|
22
74
|
return this.http.request(`/api/v1/ai/image/edits`, { method: "POST", body: input });
|
|
23
75
|
}
|
|
76
|
+
/**
|
|
77
|
+
* Generate an image from a text prompt
|
|
78
|
+
* Generates one or more images from a natural-language `prompt` using the
|
|
79
|
+
* specified AI image model. The response contains the first generated image;
|
|
80
|
+
* use `n` to request additional images (where supported by the model).
|
|
81
|
+
* The underlying provider is selected by the `model` parameter. Omit `model`
|
|
82
|
+
* to use the platform default. Size, quality, style, and format options are
|
|
83
|
+
* forwarded to the provider as-is; unsupported combinations for a given model
|
|
84
|
+
* return a 422 error with the provider's error message.
|
|
85
|
+
* This endpoint requires authentication. The request is billed against the
|
|
86
|
+
* workspace associated with the authenticated user.
|
|
87
|
+
* @param input - Request body.
|
|
88
|
+
* @param input.aspect_ratio - Desired aspect ratio of the output, e.g. `"1:1"` or `"16:9"`. Not supported by all models; omit to use the model's default.
|
|
89
|
+
* @param input.background - Background treatment for the output. Accepted values and behavior are model-dependent.
|
|
90
|
+
* @param input.height - Explicit output height in pixels. Takes precedence over `size` when both are provided. Not supported by all models.
|
|
91
|
+
* @param input.image_size - Output resolution tier for Gemini models, e.g. `"1K"`, `"2K"`, or `"4K"`. Ignored by non-Gemini models.
|
|
92
|
+
* @param input.model - Model identifier to use for generation. Omit to use the platform default image model.
|
|
93
|
+
* @param input.n - Number of images to generate. Defaults to `1`. Values greater than `1` are only supported by models that allow batch generation.
|
|
94
|
+
* @param input.output_format - Desired MIME type or format for the returned image. Common values: `"png"`, `"jpeg"`, `"webp"`. Defaults to the model's native format.
|
|
95
|
+
* @param input.prompt - Natural-language description of the image to generate.
|
|
96
|
+
* @param input.quality - Quality preset for the output image. Accepted values and behavior are model-dependent.
|
|
97
|
+
* @param input.size - Output dimensions as a WxH string, e.g. `"1024x1024"`. Applies to OpenAI-compatible models. Omit to use the model's default.
|
|
98
|
+
* @param input.style - Style preset applied to the generated image. Accepted values and behavior are model-dependent.
|
|
99
|
+
* @param input.width - Explicit output width in pixels. Takes precedence over `size` when both are provided. Not supported by all models.
|
|
100
|
+
* @returns The generated image, including base64 data or a URL depending on the model.
|
|
101
|
+
*/
|
|
24
102
|
async generations(input) {
|
|
25
103
|
return this.http.request(`/api/v1/ai/image/generations`, { method: "POST", body: input });
|
|
26
104
|
}
|
|
105
|
+
/**
|
|
106
|
+
* List available image generation models
|
|
107
|
+
* Returns the list of image generation models available on the platform.
|
|
108
|
+
* Exactly one entry in the list carries `default: true`, indicating the model
|
|
109
|
+
* used when no `model` parameter is supplied to the generation or editing
|
|
110
|
+
* endpoints.
|
|
111
|
+
* This endpoint requires authentication and reflects the models enabled for
|
|
112
|
+
* the authenticated user's workspace.
|
|
113
|
+
* @returns Successful response
|
|
114
|
+
*/
|
|
27
115
|
async models() {
|
|
28
116
|
return this.http.request(`/api/v1/ai/image/models`);
|
|
29
117
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ai.js","sourceRoot":"","sources":["../../../src/v1/resources/ai.ts"],"names":[],"mappings":"AAAA,yDAAyD;AACzD,wEAAwE;AACxE,6BAA6B;AAK7B,MAAM,OAAO,YAAY;IACH;IAApB,YAAoB,IAAgB;QAAhB,SAAI,GAAJ,IAAI,CAAY;IAAG,CAAC;IAExC,KAAK,CAAC,WAAW,CAAC,
|
|
1
|
+
{"version":3,"file":"ai.js","sourceRoot":"","sources":["../../../src/v1/resources/ai.ts"],"names":[],"mappings":"AAAA,yDAAyD;AACzD,wEAAwE;AACxE,6BAA6B;AAK7B,MAAM,OAAO,YAAY;IACH;IAApB,YAAoB,IAAgB;QAAhB,SAAI,GAAJ,IAAI,CAAY;IAAG,CAAC;IAExC;;;;;;;;;;;;;;;;OAgBG;IACH,KAAK,CAAC,WA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+3,90 @@ import type { Artifact } from "../../types/artifacts.js";
|
|
|
3
3
|
export declare class ArtifactResource {
|
|
4
4
|
private http;
|
|
5
5
|
constructor(http: HttpClient);
|
|
6
|
+
/**
|
|
7
|
+
* Delete an artifact
|
|
8
|
+
* Permanently deletes the artifact and all associated file versions. This
|
|
9
|
+
* operation is irreversible — deleted artifacts and their file content cannot
|
|
10
|
+
* be recovered.
|
|
11
|
+
* The authenticated user must have write access to the artifact's owning team
|
|
12
|
+
* or organization. Returns 404 if the artifact does not exist or is not
|
|
13
|
+
* accessible to the caller.
|
|
14
|
+
* @param artifact - Artifact ID (`art_...`) of the artifact to delete.
|
|
15
|
+
* @returns Empty body. HTTP 204 indicates the artifact and all associated file versions were permanently deleted.
|
|
16
|
+
*/
|
|
6
17
|
delete(artifact: string): Promise<void>;
|
|
18
|
+
/**
|
|
19
|
+
* Retrieve an artifact
|
|
20
|
+
* Returns the artifact identified by `artifact`. The response includes metadata
|
|
21
|
+
* such as name, description, version, and a signed `file_url` for downloading
|
|
22
|
+
* the current file version. Image artifacts also include an `image_source` object
|
|
23
|
+
* with display-ready metadata.
|
|
24
|
+
* The authenticated user must have read access to the artifact's owning team or
|
|
25
|
+
* organization. Returns 404 if the artifact does not exist or is not accessible
|
|
26
|
+
* to the caller.
|
|
27
|
+
* @param artifact - Artifact ID (`art_...`) of the artifact to retrieve.
|
|
28
|
+
* @returns The requested artifact, including its current version's file metadata and signed download URL.
|
|
29
|
+
*/
|
|
7
30
|
get(artifact: string): Promise<Artifact>;
|
|
31
|
+
/**
|
|
32
|
+
* Update an artifact
|
|
33
|
+
* Updates the metadata and, optionally, the file content of an existing artifact.
|
|
34
|
+
* This endpoint uses optimistic concurrency control: you must supply the artifact's
|
|
35
|
+
* current `version` number as `from_version`. If another update has incremented the
|
|
36
|
+
* version since you last fetched the artifact, the request returns 409.
|
|
37
|
+
* To replace the artifact's file, include a nested `file` object with Base64
|
|
38
|
+
* `data`, `filename`, and `mime_type`. Omitting `file` leaves the existing file
|
|
39
|
+
* unchanged. The authenticated user or developer must have write access to the
|
|
40
|
+
* artifact's owner.
|
|
41
|
+
* @param artifact - Artifact ID (`art_...`) of the artifact to update.
|
|
42
|
+
* @param input - Request body.
|
|
43
|
+
* @param input.description - New description for the artifact. Omit to leave the existing description unchanged.
|
|
44
|
+
* @param input.file - Replacement file payload. Omit to leave the current file unchanged.
|
|
45
|
+
* @param input.file_content - Legacy flat Base64 file content. Prefer `file.data`.
|
|
46
|
+
* @param input.file_content_type - Legacy flat MIME type. Prefer `file.mime_type`.
|
|
47
|
+
* @param input.file_name - Legacy flat filename. Prefer `file.filename`.
|
|
48
|
+
* @param input.from_version - The artifact's current version number, used for optimistic concurrency control. Returns 409 if this value does not match the server's current version.
|
|
49
|
+
* @param input.name - New display name for the artifact. Omit to leave the existing name unchanged.
|
|
50
|
+
* @returns The artifact after applying the update, reflecting the new version number and any changed metadata or file.
|
|
51
|
+
*/
|
|
8
52
|
replace(artifact: string, input: {
|
|
9
53
|
description?: string | undefined;
|
|
54
|
+
file?: {
|
|
55
|
+
data: string;
|
|
56
|
+
filename?: string | undefined;
|
|
57
|
+
mime_type?: string | undefined;
|
|
58
|
+
} | undefined;
|
|
10
59
|
file_content?: string | undefined;
|
|
11
60
|
file_content_type?: string | undefined;
|
|
12
61
|
file_name?: string | undefined;
|
|
13
62
|
from_version: number;
|
|
14
63
|
name?: string | undefined;
|
|
15
64
|
}): Promise<Artifact>;
|
|
65
|
+
/**
|
|
66
|
+
* Archive an artifact
|
|
67
|
+
* Soft-deletes the artifact identified by `artifact`. The artifact record is
|
|
68
|
+
* retained in storage but is no longer returned by the list or show endpoints.
|
|
69
|
+
* The authenticated user must have write access to the artifact's owning team or
|
|
70
|
+
* organization. Attempting to archive an artifact you do not own returns 403.
|
|
71
|
+
* Attempting to archive an artifact that does not exist or is already archived
|
|
72
|
+
* returns 404.
|
|
73
|
+
* @param artifact - Artifact ID (`art_...`) of the artifact to archive.
|
|
74
|
+
* @returns Returns 204 No Content on success. The artifact is soft-deleted and no longer accessible through the API.
|
|
75
|
+
*/
|
|
16
76
|
archive(artifact: string): Promise<void>;
|
|
77
|
+
/**
|
|
78
|
+
* Retrieve raw artifact file content
|
|
79
|
+
* Returns the raw binary content of the file stored for the specified artifact.
|
|
80
|
+
* The response `Content-Type` header reflects the artifact file's MIME type, so
|
|
81
|
+
* you can pipe the response body directly to disk or display it in a browser.
|
|
82
|
+
* By default the endpoint serves the artifact's current version. Pass the
|
|
83
|
+
* `version` parameter to retrieve a specific historical version. The authenticated
|
|
84
|
+
* user must have read access to the artifact's owning team or organization.
|
|
85
|
+
* @param artifact - Artifact ID (`art_...`) of the artifact whose content to retrieve.
|
|
86
|
+
* @param params - Query parameters.
|
|
87
|
+
* @param params.version - Version number to retrieve. Omit to return the artifact's current version.
|
|
88
|
+
* @returns Raw binary content of the artifact file. The `Content-Type` header is set to the artifact's stored MIME type.
|
|
89
|
+
*/
|
|
17
90
|
content(artifact: string, params?: {
|
|
18
91
|
version?: number;
|
|
19
92
|
}): Promise<{
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"artifacts.d.ts","sourceRoot":"","sources":["../../../src/v1/resources/artifacts.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,UAAU,EAAE,MAAM,8BAA8B,CAAC;AAC1D,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,0BAA0B,CAAC;AAEzD,qBAAa,gBAAgB;IACf,OAAO,CAAC,IAAI;gBAAJ,IAAI,EAAE,UAAU;
|
|
1
|
+
{"version":3,"file":"artifacts.d.ts","sourceRoot":"","sources":["../../../src/v1/resources/artifacts.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,UAAU,EAAE,MAAM,8BAA8B,CAAC;AAC1D,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,0BAA0B,CAAC;AAEzD,qBAAa,gBAAgB;IACf,OAAO,CAAC,IAAI;gBAAJ,IAAI,EAAE,UAAU;IAEpC;;;;;;;;;;OAU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
|
|
4
4
|
export class ArtifactResource {
|
|
5
5
|
http;
|
|
6
6
|
constructor(http) {
|
|
7
7
|
this.http = http;
|
|
8
8
|
}
|
|
9
|
+
/**
|
|
10
|
+
* Delete an artifact
|
|
11
|
+
* Permanently deletes the artifact and all associated file versions. This
|
|
12
|
+
* operation is irreversible — deleted artifacts and their file content cannot
|
|
13
|
+
* be recovered.
|
|
14
|
+
* The authenticated user must have write access to the artifact's owning team
|
|
15
|
+
* or organization. Returns 404 if the artifact does not exist or is not
|
|
16
|
+
* accessible to the caller.
|
|
17
|
+
* @param artifact - Artifact ID (`art_...`) of the artifact to delete.
|
|
18
|
+
* @returns Empty body. HTTP 204 indicates the artifact and all associated file versions were permanently deleted.
|
|
19
|
+
*/
|
|
9
20
|
async delete(artifact) {
|
|
10
21
|
await this.http.request(`/api/v1/artifacts/${artifact}`, { method: "DELETE" });
|
|
11
22
|
}
|
|
23
|
+
/**
|
|
24
|
+
* Retrieve an artifact
|
|
25
|
+
* Returns the artifact identified by `artifact`. The response includes metadata
|
|
26
|
+
* such as name, description, version, and a signed `file_url` for downloading
|
|
27
|
+
* the current file version. Image artifacts also include an `image_source` object
|
|
28
|
+
* with display-ready metadata.
|
|
29
|
+
* The authenticated user must have read access to the artifact's owning team or
|
|
30
|
+
* organization. Returns 404 if the artifact does not exist or is not accessible
|
|
31
|
+
* to the caller.
|
|
32
|
+
* @param artifact - Artifact ID (`art_...`) of the artifact to retrieve.
|
|
33
|
+
* @returns The requested artifact, including its current version's file metadata and signed download URL.
|
|
34
|
+
*/
|
|
12
35
|
async get(artifact) {
|
|
13
36
|
return this.http.request(`/api/v1/artifacts/${artifact}`);
|
|
14
37
|
}
|
|
38
|
+
/**
|
|
39
|
+
* Update an artifact
|
|
40
|
+
* Updates the metadata and, optionally, the file content of an existing artifact.
|
|
41
|
+
* This endpoint uses optimistic concurrency control: you must supply the artifact's
|
|
42
|
+
* current `version` number as `from_version`. If another update has incremented the
|
|
43
|
+
* version since you last fetched the artifact, the request returns 409.
|
|
44
|
+
* To replace the artifact's file, include a nested `file` object with Base64
|
|
45
|
+
* `data`, `filename`, and `mime_type`. Omitting `file` leaves the existing file
|
|
46
|
+
* unchanged. The authenticated user or developer must have write access to the
|
|
47
|
+
* artifact's owner.
|
|
48
|
+
* @param artifact - Artifact ID (`art_...`) of the artifact to update.
|
|
49
|
+
* @param input - Request body.
|
|
50
|
+
* @param input.description - New description for the artifact. Omit to leave the existing description unchanged.
|
|
51
|
+
* @param input.file - Replacement file payload. Omit to leave the current file unchanged.
|
|
52
|
+
* @param input.file_content - Legacy flat Base64 file content. Prefer `file.data`.
|
|
53
|
+
* @param input.file_content_type - Legacy flat MIME type. Prefer `file.mime_type`.
|
|
54
|
+
* @param input.file_name - Legacy flat filename. Prefer `file.filename`.
|
|
55
|
+
* @param input.from_version - The artifact's current version number, used for optimistic concurrency control. Returns 409 if this value does not match the server's current version.
|
|
56
|
+
* @param input.name - New display name for the artifact. Omit to leave the existing name unchanged.
|
|
57
|
+
* @returns The artifact after applying the update, reflecting the new version number and any changed metadata or file.
|
|
58
|
+
*/
|
|
15
59
|
async replace(artifact, input) {
|
|
16
60
|
return this.http.request(`/api/v1/artifacts/${artifact}`, { method: "PUT", body: input });
|
|
17
61
|
}
|
|
62
|
+
/**
|
|
63
|
+
* Archive an artifact
|
|
64
|
+
* Soft-deletes the artifact identified by `artifact`. The artifact record is
|
|
65
|
+
* retained in storage but is no longer returned by the list or show endpoints.
|
|
66
|
+
* The authenticated user must have write access to the artifact's owning team or
|
|
67
|
+
* organization. Attempting to archive an artifact you do not own returns 403.
|
|
68
|
+
* Attempting to archive an artifact that does not exist or is already archived
|
|
69
|
+
* returns 404.
|
|
70
|
+
* @param artifact - Artifact ID (`art_...`) of the artifact to archive.
|
|
71
|
+
* @returns Returns 204 No Content on success. The artifact is soft-deleted and no longer accessible through the API.
|
|
72
|
+
*/
|
|
18
73
|
async archive(artifact) {
|
|
19
74
|
await this.http.request(`/api/v1/artifacts/${artifact}/archive`, { method: "POST" });
|
|
20
75
|
}
|
|
76
|
+
/**
|
|
77
|
+
* Retrieve raw artifact file content
|
|
78
|
+
* Returns the raw binary content of the file stored for the specified artifact.
|
|
79
|
+
* The response `Content-Type` header reflects the artifact file's MIME type, so
|
|
80
|
+
* you can pipe the response body directly to disk or display it in a browser.
|
|
81
|
+
* By default the endpoint serves the artifact's current version. Pass the
|
|
82
|
+
* `version` parameter to retrieve a specific historical version. The authenticated
|
|
83
|
+
* user must have read access to the artifact's owning team or organization.
|
|
84
|
+
* @param artifact - Artifact ID (`art_...`) of the artifact whose content to retrieve.
|
|
85
|
+
* @param params - Query parameters.
|
|
86
|
+
* @param params.version - Version number to retrieve. Omit to return the artifact's current version.
|
|
87
|
+
* @returns Raw binary content of the artifact file. The `Content-Type` header is set to the artifact's stored MIME type.
|
|
88
|
+
*/
|
|
21
89
|
async content(artifact, params) {
|
|
22
|
-
|
|
90
|
+
const query = {};
|
|
91
|
+
if (params?.version !== undefined) {
|
|
92
|
+
query["version"] = params?.version;
|
|
93
|
+
}
|
|
94
|
+
return this.http.requestRaw(`/api/v1/artifacts/${artifact}/content`, { query });
|
|
23
95
|
}
|
|
24
96
|
}
|
|
25
97
|
//# sourceMappingURL=artifacts.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"artifacts.js","sourceRoot":"","sources":["../../../src/v1/resources/artifacts.ts"],"names":[],"mappings":"AAAA,yDAAyD;AACzD,wEAAwE;AACxE,6BAA6B;AAK7B,MAAM,OAAO,gBAAgB;IACP;IAApB,YAAoB,IAAgB;QAAhB,SAAI,GAAJ,IAAI,CAAY;IAAG,CAAC;IAExC,KAAK,CAAC,MAAM,CAAC,QAAgB;QAC3B,MAAM,IAAI,CAAC,IAAI,CAAC,OAAO,CAAC,qBAAqB,QAAQ,EAAE,EAAE,EAAE,MAAM,EAAE,QAAQ,EAAE,CAAC,CAAC;IACjF,CAAC;IAED,KAAK,CAAC,GAAG,CAAC,QAAgB;QACxB,OA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AE,CAAC;QAC3G,IAAI,MAAM,EAAE,OAAO,KAAK,SAAS,EAAE,CAAC;YAClC,KAAK,CAAC,SAAS,CAAC,GAAG,MAAM,EAAE,OAAO,CAAC;QACrC,CAAC;QAED,OAAO,IAAI,CAAC,IAAI,CAAC,UAAU,CAAC,qBAAqB,QAAQ,UAAU,EAAE,EAAE,KAAK,EAAE,CAAC,CAAC;IAClF,CAAC;CACF"}
|
|
@@ -4,10 +4,14 @@ export declare class AutomationRunResource {
|
|
|
4
4
|
private http;
|
|
5
5
|
constructor(http: HttpClient);
|
|
6
6
|
/**
|
|
7
|
-
*
|
|
8
|
-
*
|
|
9
|
-
* This
|
|
10
|
-
* `type:
|
|
7
|
+
* Retrieve an automation run
|
|
8
|
+
* Returns a single run created by an invoked automation.
|
|
9
|
+
* This endpoint is restricted to runs whose parent automation has
|
|
10
|
+
* `type: "invoked"`. Attempting to retrieve a run from a non-invoked
|
|
11
|
+
* automation returns 404. The authenticated user must have access to the
|
|
12
|
+
* automation run's parent automation within their workspace.
|
|
13
|
+
* @param automationRun - Automation run ID (`arun_...`). Must belong to an invoked automation accessible to the authenticated user.
|
|
14
|
+
* @returns The requested automation run.
|
|
11
15
|
*/
|
|
12
16
|
get(automationRun: string): Promise<AutomationRun>;
|
|
13
17
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"automation_runs.d.ts","sourceRoot":"","sources":["../../../src/v1/resources/automation_runs.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,UAAU,EAAE,MAAM,8BAA8B,CAAC;AAC1D,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,4BAA4B,CAAC;AAEhE,qBAAa,qBAAqB;IACpB,OAAO,CAAC,IAAI;gBAAJ,IAAI,EAAE,UAAU;IAEpC
|
|
1
|
+
{"version":3,"file":"automation_runs.d.ts","sourceRoot":"","sources":["../../../src/v1/resources/automation_runs.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,UAAU,EAAE,MAAM,8BAA8B,CAAC;AAC1D,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,4BAA4B,CAAC;AAEhE,qBAAa,qBAAqB;IACpB,OAAO,CAAC,IAAI;gBAAJ,IAAI,EAAE,UAAU;IAEpC;;;;;;;;;OASG;IACG,GAAG,CAAC,aAAa,EAAE,MAAM,GAAG,OAAO,CAAC,aAAa,CAAC;CAGzD"}
|
|
@@ -1,16 +1,20 @@
|
|
|
1
1
|
// Copyright (c) 2026 ArchAstro Inc. All Rights Reserved.
|
|
2
2
|
// This file is auto-generated by @archastro/sdk-generator. Do not edit.
|
|
3
|
-
// Content hash:
|
|
3
|
+
// Content hash: 99110a203b3c
|
|
4
4
|
export class AutomationRunResource {
|
|
5
5
|
http;
|
|
6
6
|
constructor(http) {
|
|
7
7
|
this.http = http;
|
|
8
8
|
}
|
|
9
9
|
/**
|
|
10
|
-
*
|
|
11
|
-
*
|
|
12
|
-
* This
|
|
13
|
-
* `type:
|
|
10
|
+
* Retrieve an automation run
|
|
11
|
+
* Returns a single run created by an invoked automation.
|
|
12
|
+
* This endpoint is restricted to runs whose parent automation has
|
|
13
|
+
* `type: "invoked"`. Attempting to retrieve a run from a non-invoked
|
|
14
|
+
* automation returns 404. The authenticated user must have access to the
|
|
15
|
+
* automation run's parent automation within their workspace.
|
|
16
|
+
* @param automationRun - Automation run ID (`arun_...`). Must belong to an invoked automation accessible to the authenticated user.
|
|
17
|
+
* @returns The requested automation run.
|
|
14
18
|
*/
|
|
15
19
|
async get(automationRun) {
|
|
16
20
|
return this.http.request(`/api/v1/automation_runs/${automationRun}`);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"automation_runs.js","sourceRoot":"","sources":["../../../src/v1/resources/automation_runs.ts"],"names":[],"mappings":"AAAA,yDAAyD;AACzD,wEAAwE;AACxE,6BAA6B;AAK7B,MAAM,OAAO,qBAAqB;IACZ;IAApB,YAAoB,IAAgB;QAAhB,SAAI,GAAJ,IAAI,CAAY;IAAG,CAAC;IAExC
|
|
1
|
+
{"version":3,"file":"automation_runs.js","sourceRoot":"","sources":["../../../src/v1/resources/automation_runs.ts"],"names":[],"mappings":"AAAA,yDAAyD;AACzD,wEAAwE;AACxE,6BAA6B;AAK7B,MAAM,OAAO,qBAAqB;IACZ;IAApB,YAAoB,IAAgB;QAAhB,SAAI,GAAJ,IAAI,CAAY;IAAG,CAAC;IAExC;;;;;;;;;OASG;IACH,KAAK,CAAC,GAAG,CAAC,aAAqB;QAC7B,OAAO,IAAI,CAAC,IAAI,CAAC,OAAO,CAAC,2BAA2B,aAAa,EAAE,CAAC,CAAC;IACvE,CAAC;CACF"}
|
|
@@ -3,6 +3,26 @@ import type { AutomationRun } from "../../types/automations.js";
|
|
|
3
3
|
export declare class AutomationResource {
|
|
4
4
|
private http;
|
|
5
5
|
constructor(http: HttpClient);
|
|
6
|
+
/**
|
|
7
|
+
* Invoke an automation
|
|
8
|
+
* Triggers a single run of an automation that has `type: "invoked"`. Returns
|
|
9
|
+
* the resulting automation run object, which you can use to poll or display
|
|
10
|
+
* run status.
|
|
11
|
+
* Both server-to-server (secret key) and user (publishable key + JWT) auth
|
|
12
|
+
* are supported. The automation's `invoke_auth` setting controls which auth
|
|
13
|
+
* modes are accepted; requests using an unsupported mode are rejected with
|
|
14
|
+
* 403. For server-to-server callers the run executes under the identity
|
|
15
|
+
* configured in the automation's `run_as_user` or `run_as_agent` fields. For
|
|
16
|
+
* authenticated user callers the invoking user's identity is used
|
|
17
|
+
* automatically.
|
|
18
|
+
* If you supply an `idempotency_key`, a second request with the same key
|
|
19
|
+
* returns the existing run rather than creating a new one.
|
|
20
|
+
* @param automation - Automation ID (`auto_...`) or `lookup_key` of the automation to invoke.
|
|
21
|
+
* @param input - Request body.
|
|
22
|
+
* @param input.idempotency_key - Unique key to deduplicate concurrent or retried invocations. A second request with the same key returns the existing run instead of creating a new one.
|
|
23
|
+
* @param input.payload - Arbitrary input data passed to the automation. Validated against the automation's `input_schema` when one is configured; the request is rejected with 422 if validation fails.
|
|
24
|
+
* @returns The automation run created by this invocation.
|
|
25
|
+
*/
|
|
6
26
|
invoke(automation: string, input: {
|
|
7
27
|
idempotency_key?: string | undefined;
|
|
8
28
|
payload?: Record<string, unknown> | undefined;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"automations.d.ts","sourceRoot":"","sources":["../../../src/v1/resources/automations.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,UAAU,EAAE,MAAM,8BAA8B,CAAC;AAC1D,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,4BAA4B,CAAC;AAEhE,qBAAa,kBAAkB;IACjB,OAAO,CAAC,IAAI;gBAAJ,IAAI,EAAE,UAAU;
|
|
1
|
+
{"version":3,"file":"automations.d.ts","sourceRoot":"","sources":["../../../src/v1/resources/automations.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,UAAU,EAAE,MAAM,8BAA8B,CAAC;AAC1D,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,4BAA4B,CAAC;AAEhE,qBAAa,kBAAkB;IACjB,OAAO,CAAC,IAAI;gBAAJ,IAAI,EAAE,UAAU;IAEpC;;;;;;;;;;;;;;;;;;;OAmBG;IACG,MAAM,CAAC,UAAU,EAAE,MAAM,EAAE,KAAK,EAAE;QAAE,eAAe,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;QAAC,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,SAAS,CAAA;KAAE,GAAG,OAAO,CAAC,aAAa,CAAC;CAGzJ"}
|