unfazed 0.4.0 → 0.5.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/README.md CHANGED
@@ -197,7 +197,8 @@ The chains an agent actually performs. Reach `client` from it any time:
197
197
  **Agent runs**
198
198
  | Method | Notes |
199
199
  | --- | --- |
200
- | `createRun(opts)` | `wait: true` polls to a terminal status; a boot-failed or exit-nonzero run comes back as a value, never thrown. `verify: [...]` commands run after the agent and decide whether the task is done |
200
+ | `createRun(opts)` | `wait: true` polls to a terminal status; a boot-failed or exit-nonzero run comes back as a value, never thrown. `verify: [...]` commands run after the agent and decide whether the task is done. `access: "read-write"` lifts the read-only default (read-only integration credentials, read MCP tools, no deploy); `alias` picks the app whose integrations the run gets |
201
+ | `listRunHarnesses()` | the harness presets `createRun({ harness })` accepts, with the secrets each needs |
201
202
  | `waitForRun(id, opts?)` | standalone poller; only a timeout throws |
202
203
  | `getRun(id)` / `listRuns(filter?)` | |
203
204
  | `cancelRun(id)` | idempotent on a CANCELLED run; a finished run is refused |
package/dist/client.d.ts CHANGED
@@ -1,5 +1,5 @@
1
1
  /** SDK version, sent as the User-Agent. Keep in sync with package.json. */
2
- export declare const VERSION = "0.4.0";
2
+ export declare const VERSION = "0.5.0";
3
3
  /**
4
4
  * Default GraphQL endpoint.
5
5
  *
package/dist/client.js CHANGED
@@ -1,6 +1,6 @@
1
1
  import { UnfazedAuthError, UnfazedConfigError, UnfazedGraphQLError, UnfazedHTTPError, UnfazedTimeoutError, } from "./errors.js";
2
2
  /** SDK version, sent as the User-Agent. Keep in sync with package.json. */
3
- export const VERSION = "0.4.0";
3
+ export const VERSION = "0.5.0";
4
4
  /**
5
5
  * Default GraphQL endpoint.
6
6
  *
@@ -1 +1 @@
1
- {"version":3,"file":"client.js","sourceRoot":"","sources":["../src/client.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,gBAAgB,EAChB,kBAAkB,EAClB,mBAAmB,EACnB,gBAAgB,EACh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G,GAAG,EAAE,CAAC,UAAU,CAAC,KAAK,EAAE,CAAC;IACjD,IAAI,QAAQ,EAAE,CAAC;QACb,IAAI,QAAQ,CAAC,OAAO;YAAE,UAAU,CAAC,KAAK,EAAE,CAAC;;YACpC,QAAQ,CAAC,gBAAgB,CAAC,OAAO,EAAE,eAAe,EAAE,EAAE,IAAI,EAAE,IAAI,EAAE,CAAC,CAAC;IAC3E,CAAC;IAED,OAAO;QACL,MAAM,EAAE,UAAU,CAAC,MAAM;QACzB,OAAO,EAAE,GAAG,EAAE;YACZ,IAAI,KAAK,KAAK,SAAS;gBAAE,YAAY,CAAC,KAAK,CAAC,CAAC;YAC7C,QAAQ,EAAE,mBAAmB,CAAC,OAAO,EAAE,eAAe,CAAC,CAAC;QAC1D,CAAC;QACD,UAAU,EAAE,GAAG,EAAE,CAAC,QAAQ;KAC3B,CAAC;AACJ,CAAC","sourcesContent":["import {\n UnfazedAuthError,\n UnfazedConfigError,\n UnfazedGraphQLError,\n UnfazedHTTPError,\n UnfazedTimeoutError,\n type GraphQLResponseError,\n} from \"./errors.js\";\n\n/** SDK version, sent as the User-Agent. Keep in sync with package.json. */\nexport const VERSION = \"0.4.0\";\n\n/**\n * Default GraphQL endpoint.\n *\n * Note this is the FULL endpoint, not an origin: the platform's own documented\n * convention (`UNFZ_API_URL=\"https://unfazed.dev/query\"`, and cmd/showcase-deploy\n * in the unfazed repo) treats the /query URL as the configurable unit, so the\n * SDK matches it rather than inventing a base-URL convention.\n */\nexport const DEFAULT_ENDPOINT = \"https://unfazed.dev/query\";\n\n/** Platform origin, used to derive the endpoint when only `baseUrl` is given. */\nexport const DEFAULT_BASE_URL = \"https://unfazed.dev\";\n\n/** Path of the GraphQL endpoint under an origin. */\nexport const GRAPHQL_PATH = \"/query\";\n\n/**\n * Environment variable holding the bearer token.\n *\n * This is the platform's documented name (docs/agent-deployments.md,\n * internal/agentdocs/reference.md). It accepts either an operator API token or\n * an agent access token from POST /agents/register — /query takes both as\n * plain bearers.\n */\nexport const TOKEN_ENV_VAR = \"UNFZ_API_TOKEN\";\n\n/** Environment variable holding the full GraphQL endpoint URL. */\nexport const ENDPOINT_ENV_VAR = \"UNFZ_API_URL\";\n\n/** Minimal structural type of the `fetch` the transport needs. */\nexport type FetchLike = (\n input: string,\n init: {\n method: string;\n headers: Record<string, string>;\n body: string;\n signal?: AbortSignal;\n },\n) => Promise<{\n ok: boolean;\n status: number;\n text(): Promise<string>;\n}>;\n\nexport interface ClientOptions {\n /**\n * Bearer token. Falls back to `UNFZ_API_TOKEN`. Get one from\n * https://unfazed.dev/auth.md — the same token the MCP server uses.\n */\n token?: string;\n /**\n * Full GraphQL endpoint URL. Wins over `baseUrl`. Falls back to\n * `UNFZ_API_URL`, then {@link DEFAULT_ENDPOINT}.\n */\n endpoint?: string;\n /**\n * Platform origin; `/query` is appended. Convenience for self-hosted or\n * staging control planes where only the host differs.\n */\n baseUrl?: string;\n /** Extra headers merged into every request. Authorization always wins. */\n headers?: Record<string, string>;\n /**\n * Per-request timeout in ms. Default 60_000. Pass 0 to disable.\n *\n * Bounds the WHOLE request — connect, headers and reading the response body —\n * so a proxy that answers with headers and then stalls still fails on time.\n */\n timeoutMs?: number;\n /** Injection point for tests and instrumented/proxied transports. */\n fetch?: FetchLike;\n /** Overrides the default `unfazed-sdk/<version>` User-Agent. */\n userAgent?: string;\n}\n\n/**\n * A GraphQL document.\n *\n * Structural rather than `string & {...}` on purpose: graphql-codegen emits\n * `TypedDocumentString`, a String SUBCLASS, which is not assignable to the\n * primitive `string`. Requiring only `toString()` plus the optional phantom\n * `__apiType` lets three things through with full inference:\n *\n * - generated `TypedDocumentString` documents (types inferred),\n * - documents assembled at runtime, like the batched writeFiles mutation,\n * - plain template-literal strings a caller wrote by hand.\n */\nexport interface GraphQLDocument<TResult, TVariables> {\n /** Phantom type carrier. Never called; present only to bind the generics. */\n __apiType?: (variables: TVariables) => TResult;\n toString(): string;\n}\n\n/** Result type carried by a typed document. */\nexport type ResultOf<T> = T extends GraphQLDocument<infer R, infer _V> ? R : unknown;\n\n/** Variables type carried by a typed document. */\nexport type VariablesOf<T> = T extends GraphQLDocument<infer _R, infer V> ? V : never;\n\n/** Per-request knobs. */\nexport interface RequestOptions {\n signal?: AbortSignal;\n timeoutMs?: number;\n operationName?: string;\n}\n\n/**\n * Layer 1 — a typed, dependency-free GraphQL transport over `fetch`.\n *\n * This is the SDK's entire networking surface. It understands auth, timeouts\n * and the GraphQL error envelope, and nothing about deployments. The workflow\n * layer ({@link import(\"./unfazed.js\").Unfazed}) is built strictly on top of\n * it, so you can always drop down here for any operation the workflow layer\n * does not wrap — the schema has ~660 fields and the workflow layer\n * deliberately covers only the agent-facing ones.\n *\n * ```ts\n * const client = new UnfazedClient(); // reads UNFZ_API_TOKEN\n * const data = await client.query<{ whoami: { name: string } }, never>(\n * `query { whoami { name } }`,\n * );\n * ```\n */\nexport class UnfazedClient {\n /** Resolved GraphQL endpoint URL. */\n readonly endpoint: string;\n\n readonly #token: string;\n readonly #headers: Record<string, string>;\n readonly #timeoutMs: number;\n readonly #fetch: FetchLike;\n\n constructor(options: ClientOptions = {}) {\n const token = options.token ?? readEnv(TOKEN_ENV_VAR);\n if (!token) {\n throw new UnfazedAuthError(\n `unfazed: no API token. Pass { token } or set ${TOKEN_ENV_VAR}. ` +\n `Get one at ${DEFAULT_BASE_URL}/auth.md`,\n );\n }\n this.#token = token.trim();\n\n this.endpoint = resolveEndpoint(options);\n\n this.#headers = { ...(options.headers ?? {}) };\n this.#timeoutMs = options.timeoutMs ?? 60_000;\n\n const injected = options.fetch;\n if (injected) {\n this.#fetch = injected;\n } else {\n const globalFetch = (globalThis as { fetch?: unknown }).fetch;\n if (typeof globalFetch !== \"function\") {\n throw new UnfazedConfigError(\n \"unfazed: no global fetch. Use Bun, Node >= 20, or pass { fetch } to the client.\",\n );\n }\n this.#fetch = globalFetch.bind(globalThis) as FetchLike;\n }\n\n const ua = options.userAgent ?? `unfazed-sdk/${VERSION}`;\n if (ua) this.#headers[\"User-Agent\"] = ua;\n }\n\n /** Runs a query document. Identical wire behaviour to {@link mutate}. */\n query<TResult, TVariables>(\n document: GraphQLDocument<TResult, TVariables>,\n variables?: TVariables,\n options?: RequestOptions,\n ): Promise<TResult> {\n return this.request(document, variables, options);\n }\n\n /**\n * Runs a mutation document. Distinct from {@link query} for call-site\n * readability only — GraphQL over HTTP POST makes no distinction.\n */\n mutate<TResult, TVariables>(\n document: GraphQLDocument<TResult, TVariables>,\n variables?: TVariables,\n options?: RequestOptions,\n ): Promise<TResult> {\n return this.request(document, variables, options);\n }\n\n /**\n * The single code path behind {@link query} and {@link mutate}.\n *\n * Throws {@link UnfazedHTTPError} on non-2xx, {@link UnfazedGraphQLError}\n * when the body carries `errors`, {@link UnfazedTimeoutError} on timeout or\n * abort. Resolves to the `data` object on success.\n */\n async request<TResult = unknown>(\n document: string | { toString(): string },\n variables?: unknown,\n options: RequestOptions = {},\n ): Promise<TResult> {\n const timeoutMs = options.timeoutMs ?? this.#timeoutMs;\n const { signal, cleanup, didTimeout } = makeSignal(timeoutMs, options.signal);\n\n // `document` may be a TypedDocumentString (a String object). JSON.stringify\n // would serialise that fine, but String(...) keeps the wire body a plain\n // primitive regardless of how the caller obtained the document.\n const body = JSON.stringify({\n query: String(document),\n ...(variables === undefined ? {} : { variables }),\n ...(options.operationName ? { operationName: options.operationName } : {}),\n });\n\n // The deadline covers BOTH phases — headers AND body. A proxy that answers\n // with headers and then stalls the body is a real failure mode, and\n // stopping the clock at the end of `fetch()` would leave `response.text()`\n // hanging forever. `untilAborted` additionally races the signal itself, so\n // an injected transport that ignores `signal` still cannot outlive the\n // timeout.\n let response: Awaited<ReturnType<FetchLike>>;\n let text: string;\n try {\n response = await untilAborted(\n this.#fetch(this.endpoint, {\n method: \"POST\",\n headers: {\n ...this.#headers,\n \"Content-Type\": \"application/json\",\n Accept: \"application/json\",\n Authorization: `Bearer ${this.#token}`,\n },\n body,\n ...(signal ? { signal } : {}),\n }),\n signal,\n );\n text = await untilAborted(response.text(), signal);\n } catch (cause) {\n if (didTimeout()) {\n throw new UnfazedTimeoutError(`unfazed: request timed out after ${timeoutMs}ms`, { cause });\n }\n if (isAbort(cause)) {\n throw new UnfazedTimeoutError(\"unfazed: request aborted\", { cause });\n }\n throw cause;\n } finally {\n cleanup();\n }\n\n if (!response.ok) {\n throw new UnfazedHTTPError(response.status, text, this.endpoint);\n }\n\n let parsed: { data?: TResult; errors?: GraphQLResponseError[] };\n try {\n parsed = JSON.parse(text) as typeof parsed;\n } catch {\n throw new UnfazedHTTPError(response.status, text, this.endpoint);\n }\n\n // A GraphQL 200 can still be a failure, and can be a PARTIAL failure: the\n // batched writeFiles document resolves each aliased field independently.\n // Attaching `data` to the error is what lets a caller see which writes\n // landed before the failing one.\n if (parsed.errors?.length) {\n throw new UnfazedGraphQLError(parsed.errors, parsed.data);\n }\n if (parsed.data === undefined || parsed.data === null) {\n throw new UnfazedGraphQLError(\n [{ message: \"response contained neither data nor errors\" }],\n undefined,\n );\n }\n return parsed.data;\n }\n}\n\nfunction resolveEndpoint(options: ClientOptions): string {\n if (options.endpoint) return options.endpoint;\n if (options.baseUrl) return trimSlash(options.baseUrl) + GRAPHQL_PATH;\n const env = readEnv(ENDPOINT_ENV_VAR);\n // UNFZ_API_URL is documented as the full /query URL and is used verbatim.\n // Tolerate a bare origin anyway, since that is the obvious mistake and\n // guessing right costs nothing.\n if (env) {\n const trimmed = trimSlash(env);\n return /\\/query$|\\/graphql$/.test(trimmed) ? trimmed : trimmed + GRAPHQL_PATH;\n }\n return DEFAULT_ENDPOINT;\n}\n\nfunction readEnv(name: string): string | undefined {\n // Guarded: the SDK must also work in a browser or worker, where there is no\n // `process` at all.\n const env = (globalThis as { process?: { env?: Record<string, string | undefined> } }).process\n ?.env;\n return env?.[name] || undefined;\n}\n\nfunction trimSlash(u: string): string {\n return u.replace(/\\/+$/, \"\");\n}\n\nfunction isAbort(e: unknown): boolean {\n return typeof e === \"object\" && e !== null && (e as { name?: string }).name === \"AbortError\";\n}\n\nfunction abortError(): Error {\n const e = new Error(\"The operation was aborted.\");\n e.name = \"AbortError\";\n return e;\n}\n\n/**\n * Settles with `promise`, or rejects the moment `signal` aborts.\n *\n * A global `fetch` honours the signal for headers and body alike, but an\n * injected {@link FetchLike} — a proxy, an instrumented transport, a test\n * double — need not. Racing the signal makes the timeout an upper bound on the\n * whole request regardless of what the transport does with it. The loser's\n * rejection is swallowed by the already-settled promise rather than surfacing\n * as an unhandled rejection.\n */\nfunction untilAborted<T>(promise: Promise<T>, signal: AbortSignal | undefined): Promise<T> {\n if (!signal) return promise;\n if (signal.aborted) return Promise.reject(abortError());\n return new Promise<T>((resolve, reject) => {\n const onAbort = () => reject(abortError());\n signal.addEventListener(\"abort\", onAbort, { once: true });\n const done = () => signal.removeEventListener(\"abort\", onAbort);\n promise.then(\n (value) => {\n done();\n resolve(value);\n },\n (error: unknown) => {\n done();\n reject(error as Error);\n },\n );\n });\n}\n\n/**\n * Combines the request timeout with any caller-supplied signal.\n *\n * `didTimeout` is tracked separately from the abort so a caller's own\n * cancellation is not mislabelled as a timeout in the thrown message.\n */\nfunction makeSignal(\n timeoutMs: number,\n external?: AbortSignal,\n): { signal?: AbortSignal; cleanup: () => void; didTimeout: () => boolean } {\n if (!timeoutMs && !external) return { cleanup: () => {}, didTimeout: () => false };\n if (typeof AbortController !== \"function\") {\n return {\n ...(external ? { signal: external } : {}),\n cleanup: () => {},\n didTimeout: () => false,\n };\n }\n\n const controller = new AbortController();\n let timedOut = false;\n let timer: ReturnType<typeof setTimeout> | undefined;\n\n if (timeoutMs > 0) {\n timer = setTimeout(() => {\n timedOut = true;\n controller.abort();\n }, timeoutMs);\n }\n\n const onExternalAbort = () => controller.abort();\n if (external) {\n if (external.aborted) controller.abort();\n else external.addEventListener(\"abort\", onExternalAbort, { once: true });\n }\n\n return {\n signal: controller.signal,\n cleanup: () => {\n if (timer !== undefined) clearTimeout(timer);\n external?.removeEventListener(\"abort\", onExternalAbort);\n },\n did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G,UAAU,CAAC,GAAG,EAAE;YACtB,QAAQ,GAAG,IAAI,CAAC;YAChB,UAAU,CAAC,KAAK,EAAE,CAAC;QACrB,CAAC,EAAE,SAAS,CAAC,CAAC;IAChB,CAAC;IAED,MAAM,eAAe,GAAG,GAAG,EAAE,CAAC,UAAU,CAAC,KAAK,EAAE,CAAC;IACjD,IAAI,QAAQ,EAAE,CAAC;QACb,IAAI,QAAQ,CAAC,OAAO;YAAE,UAAU,CAAC,KAAK,EAAE,CAAC;;YACpC,QAAQ,CAAC,gBAAgB,CAAC,OAAO,EAAE,eAAe,EAAE,EAAE,IAAI,EAAE,IAAI,EAAE,CAAC,CAAC;IAC3E,CAAC;IAED,OAAO;QACL,MAAM,EAAE,UAAU,CAAC,MAAM;QACzB,OAAO,EAAE,GAAG,EAAE;YACZ,IAAI,KAAK,KAAK,SAAS;gBAAE,YAAY,CAAC,KAAK,CAAC,CAAC;YAC7C,QAAQ,EAAE,mBAAmB,CAAC,OAAO,EAAE,eAAe,CAAC,CAAC;QAC1D,CAAC;QACD,UAAU,EAAE,GAAG,EAAE,CAAC,QAAQ;KAC3B,CAAC;AACJ,CAAC","sourcesContent":["import {\n UnfazedAuthError,\n UnfazedConfigError,\n UnfazedGraphQLError,\n UnfazedHTTPError,\n UnfazedTimeoutError,\n type GraphQLResponseError,\n} from \"./errors.js\";\n\n/** SDK version, sent as the User-Agent. Keep in sync with package.json. */\nexport const VERSION = \"0.5.0\";\n\n/**\n * Default GraphQL endpoint.\n *\n * Note this is the FULL endpoint, not an origin: the platform's own documented\n * convention (`UNFZ_API_URL=\"https://unfazed.dev/query\"`, and cmd/showcase-deploy\n * in the unfazed repo) treats the /query URL as the configurable unit, so the\n * SDK matches it rather than inventing a base-URL convention.\n */\nexport const DEFAULT_ENDPOINT = \"https://unfazed.dev/query\";\n\n/** Platform origin, used to derive the endpoint when only `baseUrl` is given. */\nexport const DEFAULT_BASE_URL = \"https://unfazed.dev\";\n\n/** Path of the GraphQL endpoint under an origin. */\nexport const GRAPHQL_PATH = \"/query\";\n\n/**\n * Environment variable holding the bearer token.\n *\n * This is the platform's documented name (docs/agent-deployments.md,\n * internal/agentdocs/reference.md). It accepts either an operator API token or\n * an agent access token from POST /agents/register — /query takes both as\n * plain bearers.\n */\nexport const TOKEN_ENV_VAR = \"UNFZ_API_TOKEN\";\n\n/** Environment variable holding the full GraphQL endpoint URL. */\nexport const ENDPOINT_ENV_VAR = \"UNFZ_API_URL\";\n\n/** Minimal structural type of the `fetch` the transport needs. */\nexport type FetchLike = (\n input: string,\n init: {\n method: string;\n headers: Record<string, string>;\n body: string;\n signal?: AbortSignal;\n },\n) => Promise<{\n ok: boolean;\n status: number;\n text(): Promise<string>;\n}>;\n\nexport interface ClientOptions {\n /**\n * Bearer token. Falls back to `UNFZ_API_TOKEN`. Get one from\n * https://unfazed.dev/auth.md — the same token the MCP server uses.\n */\n token?: string;\n /**\n * Full GraphQL endpoint URL. Wins over `baseUrl`. Falls back to\n * `UNFZ_API_URL`, then {@link DEFAULT_ENDPOINT}.\n */\n endpoint?: string;\n /**\n * Platform origin; `/query` is appended. Convenience for self-hosted or\n * staging control planes where only the host differs.\n */\n baseUrl?: string;\n /** Extra headers merged into every request. Authorization always wins. */\n headers?: Record<string, string>;\n /**\n * Per-request timeout in ms. Default 60_000. Pass 0 to disable.\n *\n * Bounds the WHOLE request — connect, headers and reading the response body —\n * so a proxy that answers with headers and then stalls still fails on time.\n */\n timeoutMs?: number;\n /** Injection point for tests and instrumented/proxied transports. */\n fetch?: FetchLike;\n /** Overrides the default `unfazed-sdk/<version>` User-Agent. */\n userAgent?: string;\n}\n\n/**\n * A GraphQL document.\n *\n * Structural rather than `string & {...}` on purpose: graphql-codegen emits\n * `TypedDocumentString`, a String SUBCLASS, which is not assignable to the\n * primitive `string`. Requiring only `toString()` plus the optional phantom\n * `__apiType` lets three things through with full inference:\n *\n * - generated `TypedDocumentString` documents (types inferred),\n * - documents assembled at runtime, like the batched writeFiles mutation,\n * - plain template-literal strings a caller wrote by hand.\n */\nexport interface GraphQLDocument<TResult, TVariables> {\n /** Phantom type carrier. Never called; present only to bind the generics. */\n __apiType?: (variables: TVariables) => TResult;\n toString(): string;\n}\n\n/** Result type carried by a typed document. */\nexport type ResultOf<T> = T extends GraphQLDocument<infer R, infer _V> ? R : unknown;\n\n/** Variables type carried by a typed document. */\nexport type VariablesOf<T> = T extends GraphQLDocument<infer _R, infer V> ? V : never;\n\n/** Per-request knobs. */\nexport interface RequestOptions {\n signal?: AbortSignal;\n timeoutMs?: number;\n operationName?: string;\n}\n\n/**\n * Layer 1 — a typed, dependency-free GraphQL transport over `fetch`.\n *\n * This is the SDK's entire networking surface. It understands auth, timeouts\n * and the GraphQL error envelope, and nothing about deployments. The workflow\n * layer ({@link import(\"./unfazed.js\").Unfazed}) is built strictly on top of\n * it, so you can always drop down here for any operation the workflow layer\n * does not wrap — the schema has ~660 fields and the workflow layer\n * deliberately covers only the agent-facing ones.\n *\n * ```ts\n * const client = new UnfazedClient(); // reads UNFZ_API_TOKEN\n * const data = await client.query<{ whoami: { name: string } }, never>(\n * `query { whoami { name } }`,\n * );\n * ```\n */\nexport class UnfazedClient {\n /** Resolved GraphQL endpoint URL. */\n readonly endpoint: string;\n\n readonly #token: string;\n readonly #headers: Record<string, string>;\n readonly #timeoutMs: number;\n readonly #fetch: FetchLike;\n\n constructor(options: ClientOptions = {}) {\n const token = options.token ?? readEnv(TOKEN_ENV_VAR);\n if (!token) {\n throw new UnfazedAuthError(\n `unfazed: no API token. Pass { token } or set ${TOKEN_ENV_VAR}. ` +\n `Get one at ${DEFAULT_BASE_URL}/auth.md`,\n );\n }\n this.#token = token.trim();\n\n this.endpoint = resolveEndpoint(options);\n\n this.#headers = { ...(options.headers ?? {}) };\n this.#timeoutMs = options.timeoutMs ?? 60_000;\n\n const injected = options.fetch;\n if (injected) {\n this.#fetch = injected;\n } else {\n const globalFetch = (globalThis as { fetch?: unknown }).fetch;\n if (typeof globalFetch !== \"function\") {\n throw new UnfazedConfigError(\n \"unfazed: no global fetch. Use Bun, Node >= 20, or pass { fetch } to the client.\",\n );\n }\n this.#fetch = globalFetch.bind(globalThis) as FetchLike;\n }\n\n const ua = options.userAgent ?? `unfazed-sdk/${VERSION}`;\n if (ua) this.#headers[\"User-Agent\"] = ua;\n }\n\n /** Runs a query document. Identical wire behaviour to {@link mutate}. */\n query<TResult, TVariables>(\n document: GraphQLDocument<TResult, TVariables>,\n variables?: TVariables,\n options?: RequestOptions,\n ): Promise<TResult> {\n return this.request(document, variables, options);\n }\n\n /**\n * Runs a mutation document. Distinct from {@link query} for call-site\n * readability only — GraphQL over HTTP POST makes no distinction.\n */\n mutate<TResult, TVariables>(\n document: GraphQLDocument<TResult, TVariables>,\n variables?: TVariables,\n options?: RequestOptions,\n ): Promise<TResult> {\n return this.request(document, variables, options);\n }\n\n /**\n * The single code path behind {@link query} and {@link mutate}.\n *\n * Throws {@link UnfazedHTTPError} on non-2xx, {@link UnfazedGraphQLError}\n * when the body carries `errors`, {@link UnfazedTimeoutError} on timeout or\n * abort. Resolves to the `data` object on success.\n */\n async request<TResult = unknown>(\n document: string | { toString(): string },\n variables?: unknown,\n options: RequestOptions = {},\n ): Promise<TResult> {\n const timeoutMs = options.timeoutMs ?? this.#timeoutMs;\n const { signal, cleanup, didTimeout } = makeSignal(timeoutMs, options.signal);\n\n // `document` may be a TypedDocumentString (a String object). JSON.stringify\n // would serialise that fine, but String(...) keeps the wire body a plain\n // primitive regardless of how the caller obtained the document.\n const body = JSON.stringify({\n query: String(document),\n ...(variables === undefined ? {} : { variables }),\n ...(options.operationName ? { operationName: options.operationName } : {}),\n });\n\n // The deadline covers BOTH phases — headers AND body. A proxy that answers\n // with headers and then stalls the body is a real failure mode, and\n // stopping the clock at the end of `fetch()` would leave `response.text()`\n // hanging forever. `untilAborted` additionally races the signal itself, so\n // an injected transport that ignores `signal` still cannot outlive the\n // timeout.\n let response: Awaited<ReturnType<FetchLike>>;\n let text: string;\n try {\n response = await untilAborted(\n this.#fetch(this.endpoint, {\n method: \"POST\",\n headers: {\n ...this.#headers,\n \"Content-Type\": \"application/json\",\n Accept: \"application/json\",\n Authorization: `Bearer ${this.#token}`,\n },\n body,\n ...(signal ? { signal } : {}),\n }),\n signal,\n );\n text = await untilAborted(response.text(), signal);\n } catch (cause) {\n if (didTimeout()) {\n throw new UnfazedTimeoutError(`unfazed: request timed out after ${timeoutMs}ms`, { cause });\n }\n if (isAbort(cause)) {\n throw new UnfazedTimeoutError(\"unfazed: request aborted\", { cause });\n }\n throw cause;\n } finally {\n cleanup();\n }\n\n if (!response.ok) {\n throw new UnfazedHTTPError(response.status, text, this.endpoint);\n }\n\n let parsed: { data?: TResult; errors?: GraphQLResponseError[] };\n try {\n parsed = JSON.parse(text) as typeof parsed;\n } catch {\n throw new UnfazedHTTPError(response.status, text, this.endpoint);\n }\n\n // A GraphQL 200 can still be a failure, and can be a PARTIAL failure: the\n // batched writeFiles document resolves each aliased field independently.\n // Attaching `data` to the error is what lets a caller see which writes\n // landed before the failing one.\n if (parsed.errors?.length) {\n throw new UnfazedGraphQLError(parsed.errors, parsed.data);\n }\n if (parsed.data === undefined || parsed.data === null) {\n throw new UnfazedGraphQLError(\n [{ message: \"response contained neither data nor errors\" }],\n undefined,\n );\n }\n return parsed.data;\n }\n}\n\nfunction resolveEndpoint(options: ClientOptions): string {\n if (options.endpoint) return options.endpoint;\n if (options.baseUrl) return trimSlash(options.baseUrl) + GRAPHQL_PATH;\n const env = readEnv(ENDPOINT_ENV_VAR);\n // UNFZ_API_URL is documented as the full /query URL and is used verbatim.\n // Tolerate a bare origin anyway, since that is the obvious mistake and\n // guessing right costs nothing.\n if (env) {\n const trimmed = trimSlash(env);\n return /\\/query$|\\/graphql$/.test(trimmed) ? trimmed : trimmed + GRAPHQL_PATH;\n }\n return DEFAULT_ENDPOINT;\n}\n\nfunction readEnv(name: string): string | undefined {\n // Guarded: the SDK must also work in a browser or worker, where there is no\n // `process` at all.\n const env = (globalThis as { process?: { env?: Record<string, string | undefined> } }).process\n ?.env;\n return env?.[name] || undefined;\n}\n\nfunction trimSlash(u: string): string {\n return u.replace(/\\/+$/, \"\");\n}\n\nfunction isAbort(e: unknown): boolean {\n return typeof e === \"object\" && e !== null && (e as { name?: string }).name === \"AbortError\";\n}\n\nfunction abortError(): Error {\n const e = new Error(\"The operation was aborted.\");\n e.name = \"AbortError\";\n return e;\n}\n\n/**\n * Settles with `promise`, or rejects the moment `signal` aborts.\n *\n * A global `fetch` honours the signal for headers and body alike, but an\n * injected {@link FetchLike} — a proxy, an instrumented transport, a test\n * double — need not. Racing the signal makes the timeout an upper bound on the\n * whole request regardless of what the transport does with it. The loser's\n * rejection is swallowed by the already-settled promise rather than surfacing\n * as an unhandled rejection.\n */\nfunction untilAborted<T>(promise: Promise<T>, signal: AbortSignal | undefined): Promise<T> {\n if (!signal) return promise;\n if (signal.aborted) return Promise.reject(abortError());\n return new Promise<T>((resolve, reject) => {\n const onAbort = () => reject(abortError());\n signal.addEventListener(\"abort\", onAbort, { once: true });\n const done = () => signal.removeEventListener(\"abort\", onAbort);\n promise.then(\n (value) => {\n done();\n resolve(value);\n },\n (error: unknown) => {\n done();\n reject(error as Error);\n },\n );\n });\n}\n\n/**\n * Combines the request timeout with any caller-supplied signal.\n *\n * `didTimeout` is tracked separately from the abort so a caller's own\n * cancellation is not mislabelled as a timeout in the thrown message.\n */\nfunction makeSignal(\n timeoutMs: number,\n external?: AbortSignal,\n): { signal?: AbortSignal; cleanup: () => void; didTimeout: () => boolean } {\n if (!timeoutMs && !external) return { cleanup: () => {}, didTimeout: () => false };\n if (typeof AbortController !== \"function\") {\n return {\n ...(external ? { signal: external } : {}),\n cleanup: () => {},\n didTimeout: () => false,\n };\n }\n\n const controller = new AbortController();\n let timedOut = false;\n let timer: ReturnType<typeof setTimeout> | undefined;\n\n if (timeoutMs > 0) {\n timer = setTimeout(() => {\n timedOut = true;\n controller.abort();\n }, timeoutMs);\n }\n\n const onExternalAbort = () => controller.abort();\n if (external) {\n if (external.aborted) controller.abort();\n else external.addEventListener(\"abort\", onExternalAbort, { once: true });\n }\n\n return {\n signal: controller.signal,\n cleanup: () => {\n if (timer !== undefined) clearTimeout(timer);\n external?.removeEventListener(\"abort\", onExternalAbort);\n },\n didTimeout: () => timedOut,\n };\n}\n"]}
@@ -133,7 +133,7 @@ export declare function graphql(source: "\n query SdkListAppEnv($workspaceID: I
133
133
  /**
134
134
  * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.
135
135
  */
136
- export declare function graphql(source: "\n fragment RunFields on Run {\n id\n workspaceID\n ownerId\n status\n rawStatus\n command\n harness\n prompt\n setup\n skills\n verify\n approval\n mode\n parentRunID\n depth\n question {\n id\n text\n options\n askedAt\n }\n memoryMiB\n maxSeconds\n metadata\n error\n exitCode\n result {\n status\n detail\n text\n }\n verifyExitCode\n vmID\n transcriptAvailable\n usage {\n vmSeconds\n memoryMiB\n mibSeconds\n }\n createdAt\n startedAt\n settledAt\n }\n"): typeof import('./graphql.js').RunFieldsFragmentDoc;
136
+ export declare function graphql(source: "\n fragment RunFields on Run {\n id\n workspaceID\n ownerId\n status\n rawStatus\n command\n harness\n prompt\n setup\n skills\n verify\n approval\n mode\n access\n alias\n integrations {\n kind\n bindingID\n env\n skills\n mcpServers {\n name\n transport\n readOnly\n }\n }\n parentRunID\n depth\n question {\n id\n text\n options\n askedAt\n }\n memoryMiB\n maxSeconds\n metadata\n error\n exitCode\n result {\n status\n detail\n text\n }\n verifyExitCode\n vmID\n transcriptAvailable\n usage {\n vmSeconds\n memoryMiB\n mibSeconds\n }\n createdAt\n startedAt\n settledAt\n }\n"): typeof import('./graphql.js').RunFieldsFragmentDoc;
137
137
  /**
138
138
  * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.
139
139
  */
@@ -174,3 +174,7 @@ export declare function graphql(source: "\n mutation SdkAnswerRun($id: ID!, $an
174
174
  * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.
175
175
  */
176
176
  export declare function graphql(source: "\n mutation SdkFollowUpRun($input: FollowUpRunInput!) {\n followUpRun(input: $input) {\n ...RunFields\n }\n }\n"): typeof import('./graphql.js').SdkFollowUpRunDocument;
177
+ /**
178
+ * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.
179
+ */
180
+ export declare function graphql(source: "\n query SdkRunHarnesses {\n runHarnesses {\n name\n title\n summary\n requires\n }\n }\n"): typeof import('./graphql.js').SdkRunHarnessesDocument;
@@ -34,7 +34,7 @@ const documents = {
34
34
  "\n mutation SdkRemoveAppEnv($workspaceID: ID!, $alias: String!, $name: String!) {\n removeAppEnv(input: { workspaceID: $workspaceID, alias: $alias, name: $name }) {\n ok\n }\n }\n": types.SdkRemoveAppEnvDocument,
35
35
  "\n mutation SdkInheritAppEnv($workspaceID: ID!, $alias: String!, $name: String!) {\n inheritAppEnv(input: { workspaceID: $workspaceID, alias: $alias, name: $name }) {\n ok\n }\n }\n": types.SdkInheritAppEnvDocument,
36
36
  "\n query SdkListAppEnv($workspaceID: ID!, $alias: String!) {\n appEnv(workspaceID: $workspaceID, alias: $alias) {\n name\n value\n secret\n alias\n inherited\n masked\n updatedAt\n }\n }\n": types.SdkListAppEnvDocument,
37
- "\n fragment RunFields on Run {\n id\n workspaceID\n ownerId\n status\n rawStatus\n command\n harness\n prompt\n setup\n skills\n verify\n approval\n mode\n parentRunID\n depth\n question {\n id\n text\n options\n askedAt\n }\n memoryMiB\n maxSeconds\n metadata\n error\n exitCode\n result {\n status\n detail\n text\n }\n verifyExitCode\n vmID\n transcriptAvailable\n usage {\n vmSeconds\n memoryMiB\n mibSeconds\n }\n createdAt\n startedAt\n settledAt\n }\n": types.RunFieldsFragmentDoc,
37
+ "\n fragment RunFields on Run {\n id\n workspaceID\n ownerId\n status\n rawStatus\n command\n harness\n prompt\n setup\n skills\n verify\n approval\n mode\n access\n alias\n integrations {\n kind\n bindingID\n env\n skills\n mcpServers {\n name\n transport\n readOnly\n }\n }\n parentRunID\n depth\n question {\n id\n text\n options\n askedAt\n }\n memoryMiB\n maxSeconds\n metadata\n error\n exitCode\n result {\n status\n detail\n text\n }\n verifyExitCode\n vmID\n transcriptAvailable\n usage {\n vmSeconds\n memoryMiB\n mibSeconds\n }\n createdAt\n startedAt\n settledAt\n }\n": types.RunFieldsFragmentDoc,
38
38
  "\n mutation SdkCreateRun($input: CreateRunInput!) {\n createRun(input: $input) {\n ...RunFields\n }\n }\n": types.SdkCreateRunDocument,
39
39
  "\n query SdkGetRun($id: ID!) {\n run(id: $id) {\n ...RunFields\n }\n }\n": types.SdkGetRunDocument,
40
40
  "\n query SdkPollRun($id: ID!) {\n run(id: $id) {\n id\n status\n error\n exitCode\n }\n }\n": types.SdkPollRunDocument,
@@ -45,6 +45,7 @@ const documents = {
45
45
  "\n query SdkRunTranscript($id: ID!, $tailBytes: Int) {\n runTranscript(id: $id, tailBytes: $tailBytes) {\n runID\n available\n text\n totalBytes\n truncated\n }\n }\n": types.SdkRunTranscriptDocument,
46
46
  "\n mutation SdkAnswerRun($id: ID!, $answer: String!) {\n answerRun(id: $id, answer: $answer) {\n ...RunFields\n }\n }\n": types.SdkAnswerRunDocument,
47
47
  "\n mutation SdkFollowUpRun($input: FollowUpRunInput!) {\n followUpRun(input: $input) {\n ...RunFields\n }\n }\n": types.SdkFollowUpRunDocument,
48
+ "\n query SdkRunHarnesses {\n runHarnesses {\n name\n title\n summary\n requires\n }\n }\n": types.SdkRunHarnessesDocument,
48
49
  };
49
50
  export function graphql(source) {
50
51
  return documents[source] ?? {};
@@ -1 +1 @@
1
- {"version":3,"file":"gql.js","sourceRoot":"","sources":["../../src/generated/gql.ts"],"names":[],"mappings":"AAAA,oBAAoB;AACpB,OAAO,KAAK,KAAK,MAAM,cAAc,CAAC;AA6DtC,MAAM,SAAS,GAAc;IACzB,qXAAqX,EAAE,KAAK,CAAC,2BAA2B;IACxZ,gXAAgX,EAAE,KAAK,CAAC,iBAAiB;IACzY,gPAAgP,EAAE,KAAK,CAAC,0BAA0B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,CAAC,qBAAqB;IACtQ,gmBAAgmB,EAAE,KAAK,CAAC,oBAAoB;IAC5nB,wHAAwH,EAAE,KAAK,CAAC,oBAAoB;IACpJ,uFAAuF,EAAE,KAAK,CAAC,iBAAiB;IAChH,yHAAyH,EAAE,KAAK,CAAC,kBAAkB;IACnJ,gNAAgN,EAAE,KAAK,CAAC,mBAAmB;IAC3O,mGAAmG,EAAE,KAAK,CAAC,oBAAoB;IAC/H,oNAAoN,EAAE,KAAK,CAAC,oBAAoB;IAChP,8JAA8J,EAAE,KAAK,CAAC,qBAAqB;IAC3L,yMAAyM,EAAE,KAAK,CAAC,wBAAwB;IACzO,sIAAsI,EAAE,KAAK,CAAC,oBAAoB;IAClK,8HAA8H,EAAE,KAAK,CAAC,sBAAsB;CAC/J,CAAC;AAoLF,MAAM,UAAU,OAAO,CAAC,MAAc;IACpC,OAAQ,SAAiB,CAAC,MAAM,CAAC,IAAI,EAAE,CAAC;AAC1C,CAAC","sourcesContent":["/* eslint-disable */\nimport * as types from './graphql.js';\n\n\n\n/**\n * Map of all GraphQL operations in the project.\n *\n * This map has several performance disadvantages:\n * 1. It is not tree-shakeable, so it will include all operations in the project.\n * 2. It is not minifiable, so the string of a GraphQL query will be multiple times inside the bundle.\n * 3. It does not support dead code elimination, so it will add unused operations.\n *\n * Therefore it is highly recommended to use the babel or swc plugin for production.\n * Learn more about it here: https://the-guild.dev/graphql/codegen/plugins/presets/preset-client#reducing-bundle-size\n */\ntype Documents = {\n \"\\n fragment DeploymentFields on Deployment {\\n id\\n workspaceID\\n kind\\n runtime\\n alias\\n serviceMode\\n healthPath\\n cronSchedule\\n cronPath\\n url\\n previewUrl\\n sshCommand\\n aliasHeld\\n aliasRevision\\n status\\n error\\n filesCount\\n sizeBytes\\n size\\n spaMode\\n gitRepo\\n gitCommit\\n createdAt\\n }\\n\": typeof types.DeploymentFieldsFragmentDoc,\n \"\\n query SdkWhoami {\\n whoami {\\n kind\\n userID\\n name\\n agentID\\n agentName\\n claimed\\n claimedBy\\n scopes\\n expiresAt\\n usage {\\n month\\n requests\\n limit\\n }\\n resources {\\n workspaces\\n workspaceLimit\\n services\\n serviceLimit\\n }\\n }\\n }\\n\": typeof types.SdkWhoamiDocument,\n \"\\n mutation SdkCreateWorkspace($name: String!) {\\n createWorkspace(input: { name: $name }) {\\n workspace {\\n id\\n name\\n ownerId\\n projectId\\n createdAt\\n updatedAt\\n }\\n }\\n }\\n\": typeof types.SdkCreateWorkspaceDocument,\n \"\\n query SdkListWorkspaces {\\n workspaces {\\n id\\n name\\n ownerId\\n projectId\\n createdAt\\n updatedAt\\n }\\n }\\n\": typeof types.SdkListWorkspacesDocument,\n \"\\n mutation SdkDeleteWorkspace($workspaceID: ID!, $withDeployments: Boolean) {\\n deleteWorkspace(input: { workspaceID: $workspaceID, withDeployments: $withDeployments }) {\\n ok\\n }\\n }\\n\": typeof types.SdkDeleteWorkspaceDocument,\n \"\\n mutation SdkWriteTextFile($workspaceID: ID!, $path: String!, $text: String!) {\\n writeWorkspaceTextFile(input: { workspaceID: $workspaceID, path: $path, text: $text }) {\\n file {\\n path\\n sizeBytes\\n size\\n sha256\\n updatedAt\\n }\\n }\\n }\\n\": typeof types.SdkWriteTextFileDocument,\n \"\\n mutation SdkWriteBase64File($workspaceID: ID!, $path: String!, $contentBase64: String!) {\\n writeWorkspaceBase64File(\\n input: { workspaceID: $workspaceID, path: $path, contentBase64: $contentBase64 }\\n ) {\\n file {\\n path\\n sizeBytes\\n size\\n sha256\\n updatedAt\\n }\\n }\\n }\\n\": typeof types.SdkWriteBase64FileDocument,\n \"\\n query SdkListFiles($input: ListWorkspaceFilesInput!) {\\n workspaceFilesPage(input: $input) {\\n items {\\n path\\n sizeBytes\\n size\\n sha256\\n updatedAt\\n }\\n total\\n limit\\n offset\\n hasMore\\n nextOffset\\n }\\n }\\n\": typeof types.SdkListFilesDocument,\n \"\\n query SdkReadFile($input: ReadWorkspaceFileInput!) {\\n readWorkspaceFile(input: $input) {\\n text\\n offset\\n limit\\n totalBytes\\n truncated\\n nextOffset\\n file {\\n path\\n sizeBytes\\n size\\n sha256\\n updatedAt\\n }\\n }\\n }\\n\": typeof types.SdkReadFileDocument,\n \"\\n mutation SdkDeleteFile($workspaceID: ID!, $path: String!) {\\n deleteWorkspaceFile(input: { workspaceID: $workspaceID, path: $path }) {\\n ok\\n }\\n }\\n\": typeof types.SdkDeleteFileDocument,\n \"\\n mutation SdkCreateDeployment($input: CreateDeploymentInput!) {\\n createDeployment(input: $input) {\\n deployment {\\n ...DeploymentFields\\n }\\n }\\n }\\n\": typeof types.SdkCreateDeploymentDocument,\n \"\\n mutation SdkDeployWorkspace($input: DeployWorkspaceInput!) {\\n deployWorkspace(input: $input) {\\n deployment {\\n ...DeploymentFields\\n }\\n }\\n }\\n\": typeof types.SdkDeployWorkspaceDocument,\n \"\\n query SdkGetDeployment($id: ID!) {\\n deployment(id: $id) {\\n ...DeploymentFields\\n }\\n }\\n\": typeof types.SdkGetDeploymentDocument,\n \"\\n query SdkPollDeployment($id: ID!) {\\n deployment(id: $id) {\\n id\\n status\\n error\\n aliasHeld\\n url\\n previewUrl\\n }\\n }\\n\": typeof types.SdkPollDeploymentDocument,\n \"\\n query SdkGetDeploymentByAlias($alias: String!) {\\n deploymentByAlias(alias: $alias) {\\n ...DeploymentFields\\n }\\n }\\n\": typeof types.SdkGetDeploymentByAliasDocument,\n \"\\n query SdkListDeployments($input: ListDeploymentsInput) {\\n deploymentsPage(input: $input) {\\n items {\\n ...DeploymentFields\\n }\\n total\\n limit\\n offset\\n hasMore\\n nextOffset\\n }\\n }\\n\": typeof types.SdkListDeploymentsDocument,\n \"\\n query SdkListReleases($alias: String!) {\\n deploymentReleases(alias: $alias) {\\n ...DeploymentFields\\n }\\n }\\n\": typeof types.SdkListReleasesDocument,\n \"\\n mutation SdkRollback(\\n $deploymentID: ID!\\n $expectedCurrentDeploymentID: ID!\\n $expectedCurrentAliasRevision: String!\\n ) {\\n rollbackDeployment(\\n input: {\\n deploymentID: $deploymentID\\n expectedCurrentDeploymentID: $expectedCurrentDeploymentID\\n expectedCurrentAliasRevision: $expectedCurrentAliasRevision\\n }\\n ) {\\n ...DeploymentFields\\n }\\n }\\n\": typeof types.SdkRollbackDocument,\n \"\\n query SdkServiceStatus($deploymentID: ID!) {\\n serviceStatus(deploymentID: $deploymentID) {\\n deploymentID\\n alias\\n serviceMode\\n running\\n health\\n vmID\\n inFlight\\n alwaysOn\\n memSizeMiB\\n startedAt\\n lastUsedAt\\n lastStoppedAt\\n restartCount\\n lastError\\n }\\n }\\n\": typeof types.SdkServiceStatusDocument,\n \"\\n query SdkServiceLogs($deploymentID: ID!, $tailBytes: Int) {\\n serviceLogs(deploymentID: $deploymentID, tailBytes: $tailBytes) {\\n deploymentID\\n stdout\\n stderr\\n truncated\\n stdoutBytes\\n stderrBytes\\n tailBytes\\n }\\n }\\n\": typeof types.SdkServiceLogsDocument,\n \"\\n query SdkDeploymentEvents($deploymentID: ID!, $limit: Int) {\\n deploymentEvents(deploymentID: $deploymentID, limit: $limit) {\\n id\\n deploymentID\\n type\\n rawType\\n severity\\n message\\n vmID\\n createdAt\\n }\\n }\\n\": typeof types.SdkDeploymentEventsDocument,\n \"\\n mutation SdkRestartService($deploymentID: ID!) {\\n restartService(input: { deploymentID: $deploymentID }) {\\n deploymentID\\n running\\n health\\n vmID\\n restartCount\\n lastError\\n }\\n }\\n\": typeof types.SdkRestartServiceDocument,\n \"\\n mutation SdkStopService($deploymentID: ID!) {\\n stopService(input: { deploymentID: $deploymentID }) {\\n deploymentID\\n running\\n health\\n vmID\\n restartCount\\n lastError\\n }\\n }\\n\": typeof types.SdkStopServiceDocument,\n \"\\n mutation SdkDeleteDeployment($deploymentID: ID!) {\\n deleteDeployment(input: { deploymentID: $deploymentID }) {\\n ok\\n }\\n }\\n\": typeof types.SdkDeleteDeploymentDocument,\n \"\\n mutation SdkSetWorkspaceEnv($workspaceID: ID!, $name: String!, $value: String!) {\\n setWorkspaceEnv(input: { workspaceID: $workspaceID, name: $name, value: $value }) {\\n env {\\n name\\n value\\n secret\\n alias\\n inherited\\n masked\\n updatedAt\\n }\\n }\\n }\\n\": typeof types.SdkSetWorkspaceEnvDocument,\n \"\\n mutation SdkSetWorkspaceSecret($workspaceID: ID!, $name: String!, $value: String!) {\\n setWorkspaceSecret(input: { workspaceID: $workspaceID, name: $name, value: $value }) {\\n env {\\n name\\n value\\n secret\\n alias\\n inherited\\n masked\\n updatedAt\\n }\\n }\\n }\\n\": typeof types.SdkSetWorkspaceSecretDocument,\n \"\\n mutation SdkDeleteWorkspaceEnv($workspaceID: ID!, $name: String!) {\\n deleteWorkspaceEnv(input: { workspaceID: $workspaceID, name: $name }) {\\n ok\\n }\\n }\\n\": typeof types.SdkDeleteWorkspaceEnvDocument,\n \"\\n query SdkListWorkspaceEnv($workspaceID: ID!) {\\n workspaceEnv(workspaceID: $workspaceID) {\\n name\\n value\\n secret\\n alias\\n inherited\\n masked\\n updatedAt\\n }\\n }\\n\": typeof types.SdkListWorkspaceEnvDocument,\n \"\\n mutation SdkSetAppEnv($workspaceID: ID!, $alias: String!, $name: String!, $value: String!) {\\n setAppEnv(input: { workspaceID: $workspaceID, alias: $alias, name: $name, value: $value }) {\\n env {\\n name\\n value\\n secret\\n alias\\n inherited\\n masked\\n updatedAt\\n }\\n }\\n }\\n\": typeof types.SdkSetAppEnvDocument,\n \"\\n mutation SdkSetAppSecret($workspaceID: ID!, $alias: String!, $name: String!, $value: String!) {\\n setAppSecret(input: { workspaceID: $workspaceID, alias: $alias, name: $name, value: $value }) {\\n env {\\n name\\n value\\n secret\\n alias\\n inherited\\n masked\\n updatedAt\\n }\\n }\\n }\\n\": typeof types.SdkSetAppSecretDocument,\n \"\\n mutation SdkRemoveAppEnv($workspaceID: ID!, $alias: String!, $name: String!) {\\n removeAppEnv(input: { workspaceID: $workspaceID, alias: $alias, name: $name }) {\\n ok\\n }\\n }\\n\": typeof types.SdkRemoveAppEnvDocument,\n \"\\n mutation SdkInheritAppEnv($workspaceID: ID!, $alias: String!, $name: String!) {\\n inheritAppEnv(input: { workspaceID: $workspaceID, alias: $alias, name: $name }) {\\n ok\\n }\\n }\\n\": typeof types.SdkInheritAppEnvDocument,\n \"\\n query SdkListAppEnv($workspaceID: ID!, $alias: String!) {\\n appEnv(workspaceID: $workspaceID, alias: $alias) {\\n name\\n value\\n secret\\n alias\\n inherited\\n masked\\n updatedAt\\n }\\n }\\n\": typeof types.SdkListAppEnvDocument,\n \"\\n fragment RunFields on Run {\\n id\\n workspaceID\\n ownerId\\n status\\n rawStatus\\n command\\n harness\\n prompt\\n setup\\n skills\\n verify\\n approval\\n mode\\n parentRunID\\n depth\\n question {\\n id\\n text\\n options\\n askedAt\\n }\\n memoryMiB\\n maxSeconds\\n metadata\\n error\\n exitCode\\n result {\\n status\\n detail\\n text\\n }\\n verifyExitCode\\n vmID\\n transcriptAvailable\\n usage {\\n vmSeconds\\n memoryMiB\\n mibSeconds\\n }\\n createdAt\\n startedAt\\n settledAt\\n }\\n\": typeof types.RunFieldsFragmentDoc,\n \"\\n mutation SdkCreateRun($input: CreateRunInput!) {\\n createRun(input: $input) {\\n ...RunFields\\n }\\n }\\n\": typeof types.SdkCreateRunDocument,\n \"\\n query SdkGetRun($id: ID!) {\\n run(id: $id) {\\n ...RunFields\\n }\\n }\\n\": typeof types.SdkGetRunDocument,\n \"\\n query SdkPollRun($id: ID!) {\\n run(id: $id) {\\n id\\n status\\n error\\n exitCode\\n }\\n }\\n\": typeof types.SdkPollRunDocument,\n \"\\n query SdkListRuns($input: ListRunsInput) {\\n runs(input: $input) {\\n items {\\n ...RunFields\\n }\\n total\\n limit\\n offset\\n hasMore\\n nextOffset\\n }\\n }\\n\": typeof types.SdkListRunsDocument,\n \"\\n mutation SdkCancelRun($id: ID!) {\\n cancelRun(id: $id) {\\n ...RunFields\\n }\\n }\\n\": typeof types.SdkCancelRunDocument,\n \"\\n query SdkRunEvents($runID: ID!, $limit: Int) {\\n runEvents(runID: $runID, limit: $limit) {\\n id\\n runID\\n type\\n severity\\n message\\n metadata\\n createdAt\\n }\\n }\\n\": typeof types.SdkRunEventsDocument,\n \"\\n query SdkRunConsole($id: ID!, $tailBytes: Int) {\\n runConsole(id: $id, tailBytes: $tailBytes) {\\n runID\\n running\\n text\\n }\\n }\\n\": typeof types.SdkRunConsoleDocument,\n \"\\n query SdkRunTranscript($id: ID!, $tailBytes: Int) {\\n runTranscript(id: $id, tailBytes: $tailBytes) {\\n runID\\n available\\n text\\n totalBytes\\n truncated\\n }\\n }\\n\": typeof types.SdkRunTranscriptDocument,\n \"\\n mutation SdkAnswerRun($id: ID!, $answer: String!) {\\n answerRun(id: $id, answer: $answer) {\\n ...RunFields\\n }\\n }\\n\": typeof types.SdkAnswerRunDocument,\n \"\\n mutation SdkFollowUpRun($input: FollowUpRunInput!) {\\n followUpRun(input: $input) {\\n ...RunFields\\n }\\n }\\n\": typeof types.SdkFollowUpRunDocument,\n};\nconst documents: Documents = {\n \"\\n fragment DeploymentFields on Deployment {\\n id\\n workspaceID\\n kind\\n runtime\\n alias\\n serviceMode\\n healthPath\\n cronSchedule\\n cronPath\\n url\\n previewUrl\\n sshCommand\\n aliasHeld\\n aliasRevision\\n status\\n error\\n filesCount\\n sizeBytes\\n size\\n spaMode\\n gitRepo\\n gitCommit\\n createdAt\\n }\\n\": types.DeploymentFieldsFragmentDoc,\n \"\\n query SdkWhoami {\\n whoami {\\n kind\\n userID\\n name\\n agentID\\n agentName\\n claimed\\n claimedBy\\n scopes\\n expiresAt\\n usage {\\n month\\n requests\\n limit\\n }\\n resources {\\n workspaces\\n workspaceLimit\\n services\\n serviceLimit\\n }\\n }\\n }\\n\": types.SdkWhoamiDocument,\n \"\\n mutation SdkCreateWorkspace($name: String!) {\\n createWorkspace(input: { name: $name }) {\\n workspace {\\n id\\n name\\n ownerId\\n projectId\\n createdAt\\n updatedAt\\n }\\n }\\n }\\n\": types.SdkCreateWorkspaceDocument,\n \"\\n query SdkListWorkspaces {\\n workspaces {\\n id\\n name\\n ownerId\\n projectId\\n createdAt\\n updatedAt\\n }\\n }\\n\": types.SdkListWorkspacesDocument,\n \"\\n mutation SdkDeleteWorkspace($workspaceID: ID!, $withDeployments: Boolean) {\\n deleteWorkspace(input: { workspaceID: $workspaceID, withDeployments: $withDeployments }) {\\n ok\\n }\\n }\\n\": types.SdkDeleteWorkspaceDocument,\n \"\\n mutation SdkWriteTextFile($workspaceID: ID!, $path: String!, $text: String!) {\\n writeWorkspaceTextFile(input: { workspaceID: $workspaceID, path: $path, text: $text }) {\\n file {\\n path\\n sizeBytes\\n size\\n sha256\\n updatedAt\\n }\\n }\\n }\\n\": types.SdkWriteTextFileDocument,\n \"\\n mutation SdkWriteBase64File($workspaceID: ID!, $path: String!, $contentBase64: String!) {\\n writeWorkspaceBase64File(\\n input: { workspaceID: $workspaceID, path: $path, contentBase64: $contentBase64 }\\n ) {\\n file {\\n path\\n sizeBytes\\n size\\n sha256\\n updatedAt\\n }\\n }\\n }\\n\": types.SdkWriteBase64FileDocument,\n \"\\n query SdkListFiles($input: ListWorkspaceFilesInput!) {\\n workspaceFilesPage(input: $input) {\\n items {\\n path\\n sizeBytes\\n size\\n sha256\\n updatedAt\\n }\\n total\\n limit\\n offset\\n hasMore\\n nextOffset\\n }\\n }\\n\": types.SdkListFilesDocument,\n \"\\n query SdkReadFile($input: ReadWorkspaceFileInput!) {\\n readWorkspaceFile(input: $input) {\\n text\\n offset\\n limit\\n totalBytes\\n truncated\\n nextOffset\\n file {\\n path\\n sizeBytes\\n size\\n sha256\\n updatedAt\\n }\\n }\\n }\\n\": types.SdkReadFileDocument,\n \"\\n mutation SdkDeleteFile($workspaceID: ID!, $path: String!) {\\n deleteWorkspaceFile(input: { workspaceID: $workspaceID, path: $path }) {\\n ok\\n }\\n }\\n\": types.SdkDeleteFileDocument,\n \"\\n mutation SdkCreateDeployment($input: CreateDeploymentInput!) {\\n createDeployment(input: $input) {\\n deployment {\\n ...DeploymentFields\\n }\\n }\\n }\\n\": types.SdkCreateDeploymentDocument,\n \"\\n mutation SdkDeployWorkspace($input: DeployWorkspaceInput!) {\\n deployWorkspace(input: $input) {\\n deployment {\\n ...DeploymentFields\\n }\\n }\\n }\\n\": types.SdkDeployWorkspaceDocument,\n \"\\n query SdkGetDeployment($id: ID!) {\\n deployment(id: $id) {\\n ...DeploymentFields\\n }\\n }\\n\": types.SdkGetDeploymentDocument,\n \"\\n query SdkPollDeployment($id: ID!) {\\n deployment(id: $id) {\\n id\\n status\\n error\\n aliasHeld\\n url\\n previewUrl\\n }\\n }\\n\": types.SdkPollDeploymentDocument,\n \"\\n query SdkGetDeploymentByAlias($alias: String!) {\\n deploymentByAlias(alias: $alias) {\\n ...DeploymentFields\\n }\\n }\\n\": types.SdkGetDeploymentByAliasDocument,\n \"\\n query SdkListDeployments($input: ListDeploymentsInput) {\\n deploymentsPage(input: $input) {\\n items {\\n ...DeploymentFields\\n }\\n total\\n limit\\n offset\\n hasMore\\n nextOffset\\n }\\n }\\n\": types.SdkListDeploymentsDocument,\n \"\\n query SdkListReleases($alias: String!) {\\n deploymentReleases(alias: $alias) {\\n ...DeploymentFields\\n }\\n }\\n\": types.SdkListReleasesDocument,\n \"\\n mutation SdkRollback(\\n $deploymentID: ID!\\n $expectedCurrentDeploymentID: ID!\\n $expectedCurrentAliasRevision: String!\\n ) {\\n rollbackDeployment(\\n input: {\\n deploymentID: $deploymentID\\n expectedCurrentDeploymentID: $expectedCurrentDeploymentID\\n expectedCurrentAliasRevision: $expectedCurrentAliasRevision\\n }\\n ) {\\n ...DeploymentFields\\n }\\n }\\n\": types.SdkRollbackDocument,\n \"\\n query SdkServiceStatus($deploymentID: ID!) {\\n serviceStatus(deploymentID: $deploymentID) {\\n deploymentID\\n alias\\n serviceMode\\n running\\n health\\n vmID\\n inFlight\\n alwaysOn\\n memSizeMiB\\n startedAt\\n lastUsedAt\\n lastStoppedAt\\n restartCount\\n lastError\\n }\\n }\\n\": types.SdkServiceStatusDocument,\n \"\\n query SdkServiceLogs($deploymentID: ID!, $tailBytes: Int) {\\n serviceLogs(deploymentID: $deploymentID, tailBytes: $tailBytes) {\\n deploymentID\\n stdout\\n stderr\\n truncated\\n stdoutBytes\\n stderrBytes\\n tailBytes\\n }\\n }\\n\": types.SdkServiceLogsDocument,\n \"\\n query SdkDeploymentEvents($deploymentID: ID!, $limit: Int) {\\n deploymentEvents(deploymentID: $deploymentID, limit: $limit) {\\n id\\n deploymentID\\n type\\n rawType\\n severity\\n message\\n vmID\\n createdAt\\n }\\n }\\n\": types.SdkDeploymentEventsDocument,\n \"\\n mutation SdkRestartService($deploymentID: ID!) {\\n restartService(input: { deploymentID: $deploymentID }) {\\n deploymentID\\n running\\n health\\n vmID\\n restartCount\\n lastError\\n }\\n }\\n\": types.SdkRestartServiceDocument,\n \"\\n mutation SdkStopService($deploymentID: ID!) {\\n stopService(input: { deploymentID: $deploymentID }) {\\n deploymentID\\n running\\n health\\n vmID\\n restartCount\\n lastError\\n }\\n }\\n\": types.SdkStopServiceDocument,\n \"\\n mutation SdkDeleteDeployment($deploymentID: ID!) {\\n deleteDeployment(input: { deploymentID: $deploymentID }) {\\n ok\\n }\\n }\\n\": types.SdkDeleteDeploymentDocument,\n \"\\n mutation SdkSetWorkspaceEnv($workspaceID: ID!, $name: String!, $value: String!) {\\n setWorkspaceEnv(input: { workspaceID: $workspaceID, name: $name, value: $value }) {\\n env {\\n name\\n value\\n secret\\n alias\\n inherited\\n masked\\n updatedAt\\n }\\n }\\n }\\n\": types.SdkSetWorkspaceEnvDocument,\n \"\\n mutation SdkSetWorkspaceSecret($workspaceID: ID!, $name: String!, $value: String!) {\\n setWorkspaceSecret(input: { workspaceID: $workspaceID, name: $name, value: $value }) {\\n env {\\n name\\n value\\n secret\\n alias\\n inherited\\n masked\\n updatedAt\\n }\\n }\\n }\\n\": types.SdkSetWorkspaceSecretDocument,\n \"\\n mutation SdkDeleteWorkspaceEnv($workspaceID: ID!, $name: String!) {\\n deleteWorkspaceEnv(input: { workspaceID: $workspaceID, name: $name }) {\\n ok\\n }\\n }\\n\": types.SdkDeleteWorkspaceEnvDocument,\n \"\\n query SdkListWorkspaceEnv($workspaceID: ID!) {\\n workspaceEnv(workspaceID: $workspaceID) {\\n name\\n value\\n secret\\n alias\\n inherited\\n masked\\n updatedAt\\n }\\n }\\n\": types.SdkListWorkspaceEnvDocument,\n \"\\n mutation SdkSetAppEnv($workspaceID: ID!, $alias: String!, $name: String!, $value: String!) {\\n setAppEnv(input: { workspaceID: $workspaceID, alias: $alias, name: $name, value: $value }) {\\n env {\\n name\\n value\\n secret\\n alias\\n inherited\\n masked\\n updatedAt\\n }\\n }\\n }\\n\": types.SdkSetAppEnvDocument,\n \"\\n mutation SdkSetAppSecret($workspaceID: ID!, $alias: String!, $name: String!, $value: String!) {\\n setAppSecret(input: { workspaceID: $workspaceID, alias: $alias, name: $name, value: $value }) {\\n env {\\n name\\n value\\n secret\\n alias\\n inherited\\n masked\\n updatedAt\\n }\\n }\\n }\\n\": types.SdkSetAppSecretDocument,\n \"\\n mutation SdkRemoveAppEnv($workspaceID: ID!, $alias: String!, $name: String!) {\\n removeAppEnv(input: { workspaceID: $workspaceID, alias: $alias, name: $name }) {\\n ok\\n }\\n }\\n\": types.SdkRemoveAppEnvDocument,\n \"\\n mutation SdkInheritAppEnv($workspaceID: ID!, $alias: String!, $name: String!) {\\n inheritAppEnv(input: { workspaceID: $workspaceID, alias: $alias, name: $name }) {\\n ok\\n }\\n }\\n\": types.SdkInheritAppEnvDocument,\n \"\\n query SdkListAppEnv($workspaceID: ID!, $alias: String!) {\\n appEnv(workspaceID: $workspaceID, alias: $alias) {\\n name\\n value\\n secret\\n alias\\n inherited\\n masked\\n updatedAt\\n }\\n }\\n\": types.SdkListAppEnvDocument,\n \"\\n fragment RunFields on Run {\\n id\\n workspaceID\\n ownerId\\n status\\n rawStatus\\n command\\n harness\\n prompt\\n setup\\n skills\\n verify\\n approval\\n mode\\n parentRunID\\n depth\\n question {\\n id\\n text\\n options\\n askedAt\\n }\\n memoryMiB\\n maxSeconds\\n metadata\\n error\\n exitCode\\n result {\\n status\\n detail\\n text\\n }\\n verifyExitCode\\n vmID\\n transcriptAvailable\\n usage {\\n vmSeconds\\n memoryMiB\\n mibSeconds\\n }\\n createdAt\\n startedAt\\n settledAt\\n }\\n\": types.RunFieldsFragmentDoc,\n \"\\n mutation SdkCreateRun($input: CreateRunInput!) {\\n createRun(input: $input) {\\n ...RunFields\\n }\\n }\\n\": types.SdkCreateRunDocument,\n \"\\n query SdkGetRun($id: ID!) {\\n run(id: $id) {\\n ...RunFields\\n }\\n }\\n\": types.SdkGetRunDocument,\n \"\\n query SdkPollRun($id: ID!) {\\n run(id: $id) {\\n id\\n status\\n error\\n exitCode\\n }\\n }\\n\": types.SdkPollRunDocument,\n \"\\n query SdkListRuns($input: ListRunsInput) {\\n runs(input: $input) {\\n items {\\n ...RunFields\\n }\\n total\\n limit\\n offset\\n hasMore\\n nextOffset\\n }\\n }\\n\": types.SdkListRunsDocument,\n \"\\n mutation SdkCancelRun($id: ID!) {\\n cancelRun(id: $id) {\\n ...RunFields\\n }\\n }\\n\": types.SdkCancelRunDocument,\n \"\\n query SdkRunEvents($runID: ID!, $limit: Int) {\\n runEvents(runID: $runID, limit: $limit) {\\n id\\n runID\\n type\\n severity\\n message\\n metadata\\n createdAt\\n }\\n }\\n\": types.SdkRunEventsDocument,\n \"\\n query SdkRunConsole($id: ID!, $tailBytes: Int) {\\n runConsole(id: $id, tailBytes: $tailBytes) {\\n runID\\n running\\n text\\n }\\n }\\n\": types.SdkRunConsoleDocument,\n \"\\n query SdkRunTranscript($id: ID!, $tailBytes: Int) {\\n runTranscript(id: $id, tailBytes: $tailBytes) {\\n runID\\n available\\n text\\n totalBytes\\n truncated\\n }\\n }\\n\": types.SdkRunTranscriptDocument,\n \"\\n mutation SdkAnswerRun($id: ID!, $answer: String!) {\\n answerRun(id: $id, answer: $answer) {\\n ...RunFields\\n }\\n }\\n\": types.SdkAnswerRunDocument,\n \"\\n mutation SdkFollowUpRun($input: FollowUpRunInput!) {\\n followUpRun(input: $input) {\\n ...RunFields\\n }\\n }\\n\": types.SdkFollowUpRunDocument,\n};\n\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n fragment DeploymentFields on Deployment {\\n id\\n workspaceID\\n kind\\n runtime\\n alias\\n serviceMode\\n healthPath\\n cronSchedule\\n cronPath\\n url\\n previewUrl\\n sshCommand\\n aliasHeld\\n aliasRevision\\n status\\n error\\n filesCount\\n sizeBytes\\n size\\n spaMode\\n gitRepo\\n gitCommit\\n createdAt\\n }\\n\"): typeof import('./graphql.js').DeploymentFieldsFragmentDoc;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n query SdkWhoami {\\n whoami {\\n kind\\n userID\\n name\\n agentID\\n agentName\\n claimed\\n claimedBy\\n scopes\\n expiresAt\\n usage {\\n month\\n requests\\n limit\\n }\\n resources {\\n workspaces\\n workspaceLimit\\n services\\n serviceLimit\\n }\\n }\\n }\\n\"): typeof import('./graphql.js').SdkWhoamiDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n mutation SdkCreateWorkspace($name: String!) {\\n createWorkspace(input: { name: $name }) {\\n workspace {\\n id\\n name\\n ownerId\\n projectId\\n createdAt\\n updatedAt\\n }\\n }\\n }\\n\"): typeof import('./graphql.js').SdkCreateWorkspaceDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n query SdkListWorkspaces {\\n workspaces {\\n id\\n name\\n ownerId\\n projectId\\n createdAt\\n updatedAt\\n }\\n }\\n\"): typeof import('./graphql.js').SdkListWorkspacesDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n mutation SdkDeleteWorkspace($workspaceID: ID!, $withDeployments: Boolean) {\\n deleteWorkspace(input: { workspaceID: $workspaceID, withDeployments: $withDeployments }) {\\n ok\\n }\\n }\\n\"): typeof import('./graphql.js').SdkDeleteWorkspaceDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n mutation SdkWriteTextFile($workspaceID: ID!, $path: String!, $text: String!) {\\n writeWorkspaceTextFile(input: { workspaceID: $workspaceID, path: $path, text: $text }) {\\n file {\\n path\\n sizeBytes\\n size\\n sha256\\n updatedAt\\n }\\n }\\n }\\n\"): typeof import('./graphql.js').SdkWriteTextFileDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n mutation SdkWriteBase64File($workspaceID: ID!, $path: String!, $contentBase64: String!) {\\n writeWorkspaceBase64File(\\n input: { workspaceID: $workspaceID, path: $path, contentBase64: $contentBase64 }\\n ) {\\n file {\\n path\\n sizeBytes\\n size\\n sha256\\n updatedAt\\n }\\n }\\n }\\n\"): typeof import('./graphql.js').SdkWriteBase64FileDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n query SdkListFiles($input: ListWorkspaceFilesInput!) {\\n workspaceFilesPage(input: $input) {\\n items {\\n path\\n sizeBytes\\n size\\n sha256\\n updatedAt\\n }\\n total\\n limit\\n offset\\n hasMore\\n nextOffset\\n }\\n }\\n\"): typeof import('./graphql.js').SdkListFilesDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n query SdkReadFile($input: ReadWorkspaceFileInput!) {\\n readWorkspaceFile(input: $input) {\\n text\\n offset\\n limit\\n totalBytes\\n truncated\\n nextOffset\\n file {\\n path\\n sizeBytes\\n size\\n sha256\\n updatedAt\\n }\\n }\\n }\\n\"): typeof import('./graphql.js').SdkReadFileDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n mutation SdkDeleteFile($workspaceID: ID!, $path: String!) {\\n deleteWorkspaceFile(input: { workspaceID: $workspaceID, path: $path }) {\\n ok\\n }\\n }\\n\"): typeof import('./graphql.js').SdkDeleteFileDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n mutation SdkCreateDeployment($input: CreateDeploymentInput!) {\\n createDeployment(input: $input) {\\n deployment {\\n ...DeploymentFields\\n }\\n }\\n }\\n\"): typeof import('./graphql.js').SdkCreateDeploymentDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n mutation SdkDeployWorkspace($input: DeployWorkspaceInput!) {\\n deployWorkspace(input: $input) {\\n deployment {\\n ...DeploymentFields\\n }\\n }\\n }\\n\"): typeof import('./graphql.js').SdkDeployWorkspaceDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n query SdkGetDeployment($id: ID!) {\\n deployment(id: $id) {\\n ...DeploymentFields\\n }\\n }\\n\"): typeof import('./graphql.js').SdkGetDeploymentDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n query SdkPollDeployment($id: ID!) {\\n deployment(id: $id) {\\n id\\n status\\n error\\n aliasHeld\\n url\\n previewUrl\\n }\\n }\\n\"): typeof import('./graphql.js').SdkPollDeploymentDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n query SdkGetDeploymentByAlias($alias: String!) {\\n deploymentByAlias(alias: $alias) {\\n ...DeploymentFields\\n }\\n }\\n\"): typeof import('./graphql.js').SdkGetDeploymentByAliasDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n query SdkListDeployments($input: ListDeploymentsInput) {\\n deploymentsPage(input: $input) {\\n items {\\n ...DeploymentFields\\n }\\n total\\n limit\\n offset\\n hasMore\\n nextOffset\\n }\\n }\\n\"): typeof import('./graphql.js').SdkListDeploymentsDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n query SdkListReleases($alias: String!) {\\n deploymentReleases(alias: $alias) {\\n ...DeploymentFields\\n }\\n }\\n\"): typeof import('./graphql.js').SdkListReleasesDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n mutation SdkRollback(\\n $deploymentID: ID!\\n $expectedCurrentDeploymentID: ID!\\n $expectedCurrentAliasRevision: String!\\n ) {\\n rollbackDeployment(\\n input: {\\n deploymentID: $deploymentID\\n expectedCurrentDeploymentID: $expectedCurrentDeploymentID\\n expectedCurrentAliasRevision: $expectedCurrentAliasRevision\\n }\\n ) {\\n ...DeploymentFields\\n }\\n }\\n\"): typeof import('./graphql.js').SdkRollbackDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n query SdkServiceStatus($deploymentID: ID!) {\\n serviceStatus(deploymentID: $deploymentID) {\\n deploymentID\\n alias\\n serviceMode\\n running\\n health\\n vmID\\n inFlight\\n alwaysOn\\n memSizeMiB\\n startedAt\\n lastUsedAt\\n lastStoppedAt\\n restartCount\\n lastError\\n }\\n }\\n\"): typeof import('./graphql.js').SdkServiceStatusDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n query SdkServiceLogs($deploymentID: ID!, $tailBytes: Int) {\\n serviceLogs(deploymentID: $deploymentID, tailBytes: $tailBytes) {\\n deploymentID\\n stdout\\n stderr\\n truncated\\n stdoutBytes\\n stderrBytes\\n tailBytes\\n }\\n }\\n\"): typeof import('./graphql.js').SdkServiceLogsDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n query SdkDeploymentEvents($deploymentID: ID!, $limit: Int) {\\n deploymentEvents(deploymentID: $deploymentID, limit: $limit) {\\n id\\n deploymentID\\n type\\n rawType\\n severity\\n message\\n vmID\\n createdAt\\n }\\n }\\n\"): typeof import('./graphql.js').SdkDeploymentEventsDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n mutation SdkRestartService($deploymentID: ID!) {\\n restartService(input: { deploymentID: $deploymentID }) {\\n deploymentID\\n running\\n health\\n vmID\\n restartCount\\n lastError\\n }\\n }\\n\"): typeof import('./graphql.js').SdkRestartServiceDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n mutation SdkStopService($deploymentID: ID!) {\\n stopService(input: { deploymentID: $deploymentID }) {\\n deploymentID\\n running\\n health\\n vmID\\n restartCount\\n lastError\\n }\\n }\\n\"): typeof import('./graphql.js').SdkStopServiceDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n mutation SdkDeleteDeployment($deploymentID: ID!) {\\n deleteDeployment(input: { deploymentID: $deploymentID }) {\\n ok\\n }\\n }\\n\"): typeof import('./graphql.js').SdkDeleteDeploymentDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n mutation SdkSetWorkspaceEnv($workspaceID: ID!, $name: String!, $value: String!) {\\n setWorkspaceEnv(input: { workspaceID: $workspaceID, name: $name, value: $value }) {\\n env {\\n name\\n value\\n secret\\n alias\\n inherited\\n masked\\n updatedAt\\n }\\n }\\n }\\n\"): typeof import('./graphql.js').SdkSetWorkspaceEnvDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n mutation SdkSetWorkspaceSecret($workspaceID: ID!, $name: String!, $value: String!) {\\n setWorkspaceSecret(input: { workspaceID: $workspaceID, name: $name, value: $value }) {\\n env {\\n name\\n value\\n secret\\n alias\\n inherited\\n masked\\n updatedAt\\n }\\n }\\n }\\n\"): typeof import('./graphql.js').SdkSetWorkspaceSecretDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n mutation SdkDeleteWorkspaceEnv($workspaceID: ID!, $name: String!) {\\n deleteWorkspaceEnv(input: { workspaceID: $workspaceID, name: $name }) {\\n ok\\n }\\n }\\n\"): typeof import('./graphql.js').SdkDeleteWorkspaceEnvDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n query SdkListWorkspaceEnv($workspaceID: ID!) {\\n workspaceEnv(workspaceID: $workspaceID) {\\n name\\n value\\n secret\\n alias\\n inherited\\n masked\\n updatedAt\\n }\\n }\\n\"): typeof import('./graphql.js').SdkListWorkspaceEnvDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n mutation SdkSetAppEnv($workspaceID: ID!, $alias: String!, $name: String!, $value: String!) {\\n setAppEnv(input: { workspaceID: $workspaceID, alias: $alias, name: $name, value: $value }) {\\n env {\\n name\\n value\\n secret\\n alias\\n inherited\\n masked\\n updatedAt\\n }\\n }\\n }\\n\"): typeof import('./graphql.js').SdkSetAppEnvDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n mutation SdkSetAppSecret($workspaceID: ID!, $alias: String!, $name: String!, $value: String!) {\\n setAppSecret(input: { workspaceID: $workspaceID, alias: $alias, name: $name, value: $value }) {\\n env {\\n name\\n value\\n secret\\n alias\\n inherited\\n masked\\n updatedAt\\n }\\n }\\n }\\n\"): typeof import('./graphql.js').SdkSetAppSecretDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n mutation SdkRemoveAppEnv($workspaceID: ID!, $alias: String!, $name: String!) {\\n removeAppEnv(input: { workspaceID: $workspaceID, alias: $alias, name: $name }) {\\n ok\\n }\\n }\\n\"): typeof import('./graphql.js').SdkRemoveAppEnvDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n mutation SdkInheritAppEnv($workspaceID: ID!, $alias: String!, $name: String!) {\\n inheritAppEnv(input: { workspaceID: $workspaceID, alias: $alias, name: $name }) {\\n ok\\n }\\n }\\n\"): typeof import('./graphql.js').SdkInheritAppEnvDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n query SdkListAppEnv($workspaceID: ID!, $alias: String!) {\\n appEnv(workspaceID: $workspaceID, alias: $alias) {\\n name\\n value\\n secret\\n alias\\n inherited\\n masked\\n updatedAt\\n }\\n }\\n\"): typeof import('./graphql.js').SdkListAppEnvDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n fragment RunFields on Run {\\n id\\n workspaceID\\n ownerId\\n status\\n rawStatus\\n command\\n harness\\n prompt\\n setup\\n skills\\n verify\\n approval\\n mode\\n parentRunID\\n depth\\n question {\\n id\\n text\\n options\\n askedAt\\n }\\n memoryMiB\\n maxSeconds\\n metadata\\n error\\n exitCode\\n result {\\n status\\n detail\\n text\\n }\\n verifyExitCode\\n vmID\\n transcriptAvailable\\n usage {\\n vmSeconds\\n memoryMiB\\n mibSeconds\\n }\\n createdAt\\n startedAt\\n settledAt\\n }\\n\"): typeof import('./graphql.js').RunFieldsFragmentDoc;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n mutation SdkCreateRun($input: CreateRunInput!) {\\n createRun(input: $input) {\\n ...RunFields\\n }\\n }\\n\"): typeof import('./graphql.js').SdkCreateRunDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n query SdkGetRun($id: ID!) {\\n run(id: $id) {\\n ...RunFields\\n }\\n }\\n\"): typeof import('./graphql.js').SdkGetRunDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n query SdkPollRun($id: ID!) {\\n run(id: $id) {\\n id\\n status\\n error\\n exitCode\\n }\\n }\\n\"): typeof import('./graphql.js').SdkPollRunDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n query SdkListRuns($input: ListRunsInput) {\\n runs(input: $input) {\\n items {\\n ...RunFields\\n }\\n total\\n limit\\n offset\\n hasMore\\n nextOffset\\n }\\n }\\n\"): typeof import('./graphql.js').SdkListRunsDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n mutation SdkCancelRun($id: ID!) {\\n cancelRun(id: $id) {\\n ...RunFields\\n }\\n }\\n\"): typeof import('./graphql.js').SdkCancelRunDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n query SdkRunEvents($runID: ID!, $limit: Int) {\\n runEvents(runID: $runID, limit: $limit) {\\n id\\n runID\\n type\\n severity\\n message\\n metadata\\n createdAt\\n }\\n }\\n\"): typeof import('./graphql.js').SdkRunEventsDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n query SdkRunConsole($id: ID!, $tailBytes: Int) {\\n runConsole(id: $id, tailBytes: $tailBytes) {\\n runID\\n running\\n text\\n }\\n }\\n\"): typeof import('./graphql.js').SdkRunConsoleDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n query SdkRunTranscript($id: ID!, $tailBytes: Int) {\\n runTranscript(id: $id, tailBytes: $tailBytes) {\\n runID\\n available\\n text\\n totalBytes\\n truncated\\n }\\n }\\n\"): typeof import('./graphql.js').SdkRunTranscriptDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n mutation SdkAnswerRun($id: ID!, $answer: String!) {\\n answerRun(id: $id, answer: $answer) {\\n ...RunFields\\n }\\n }\\n\"): typeof import('./graphql.js').SdkAnswerRunDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n mutation SdkFollowUpRun($input: FollowUpRunInput!) {\\n followUpRun(input: $input) {\\n ...RunFields\\n }\\n }\\n\"): typeof import('./graphql.js').SdkFollowUpRunDocument;\n\n\nexport function graphql(source: string) {\n return (documents as any)[source] ?? {};\n}\n"]}
1
+ {"version":3,"file":"gql.js","sourceRoot":"","sources":["../../src/generated/gql.ts"],"names":[],"mappings":"AAAA,oBAAoB;AACpB,OAAO,KAAK,KAAK,MAAM,cAAc,CAAC;AA8DtC,MAAM,SAAS,GAAc;IACzB,qXAAqX,EAAE,KAAK,CAAC,2BAA2B;IACxZ,gXAAgX,EAAE,KAAK,CAAC,iBAAiB;IACzY,gPAAgP,EAAE,KAAK,CAAC,0BAA0B;IAClR,uJAAuJ,EAAE,KAAK,CAAC,yBAAyB;IACxL,yMAAyM,EAAE,KAAK,CAAC,0BAA0B;IAC3O,ySAAyS,EAAE,KAAK,CAAC,wBAAwB;IACzU,sVAAsV,EAAE,KAAK,CAAC,0BAA0B;IACxX,sSAAsS,EAAE,KAAK,CAAC,oBAAoB;IAClU,qTAAqT,EAAE,KAAK,CAAC,mBAAmB;IAChV,uKAAuK,EAAE,KAAK,CAAC,qBAAqB;IACpM,mLAAmL,EAAE,KAAK,CAAC,2BAA2B;IACtN,gLAAgL,EAAE,KAAK,CAAC,0BAA0B;IAClN,4GAA4G,EAAE,KAAK,CAAC,wBAAwB;IAC5I,qKA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AC,oBAAoB;IAClK,8HAA8H,EAAE,KAAK,CAAC,sBAAsB;IAC5J,uHAAuH,EAAE,KAAK,CAAC,uBAAuB;CACzJ,CAAC;AAwLF,MAAM,UAAU,OAAO,CAAC,MAAc;IACpC,OAAQ,SAAiB,CAAC,MAAM,CAAC,IAAI,EAAE,CAAC;AAC1C,CAAC","sourcesContent":["/* eslint-disable */\nimport * as types from './graphql.js';\n\n\n\n/**\n * Map of all GraphQL operations in the project.\n *\n * This map has several performance disadvantages:\n * 1. It is not tree-shakeable, so it will include all operations in the project.\n * 2. It is not minifiable, so the string of a GraphQL query will be multiple times inside the bundle.\n * 3. It does not support dead code elimination, so it will add unused operations.\n *\n * Therefore it is highly recommended to use the babel or swc plugin for production.\n * Learn more about it here: https://the-guild.dev/graphql/codegen/plugins/presets/preset-client#reducing-bundle-size\n */\ntype Documents = {\n \"\\n fragment DeploymentFields on Deployment {\\n id\\n workspaceID\\n kind\\n runtime\\n alias\\n serviceMode\\n healthPath\\n cronSchedule\\n cronPath\\n url\\n previewUrl\\n sshCommand\\n aliasHeld\\n aliasRevision\\n status\\n error\\n filesCount\\n sizeBytes\\n size\\n spaMode\\n gitRepo\\n gitCommit\\n createdAt\\n }\\n\": typeof types.DeploymentFieldsFragmentDoc,\n \"\\n query SdkWhoami {\\n whoami {\\n kind\\n userID\\n name\\n agentID\\n agentName\\n claimed\\n claimedBy\\n scopes\\n expiresAt\\n usage {\\n month\\n requests\\n limit\\n }\\n resources {\\n workspaces\\n workspaceLimit\\n services\\n serviceLimit\\n }\\n }\\n }\\n\": typeof types.SdkWhoamiDocument,\n \"\\n mutation SdkCreateWorkspace($name: String!) {\\n createWorkspace(input: { name: $name }) {\\n workspace {\\n id\\n name\\n ownerId\\n projectId\\n createdAt\\n updatedAt\\n }\\n }\\n }\\n\": typeof types.SdkCreateWorkspaceDocument,\n \"\\n query SdkListWorkspaces {\\n workspaces {\\n id\\n name\\n ownerId\\n projectId\\n createdAt\\n updatedAt\\n }\\n }\\n\": typeof types.SdkListWorkspacesDocument,\n \"\\n mutation SdkDeleteWorkspace($workspaceID: ID!, $withDeployments: Boolean) {\\n deleteWorkspace(input: { workspaceID: $workspaceID, withDeployments: $withDeployments }) {\\n ok\\n }\\n }\\n\": typeof types.SdkDeleteWorkspaceDocument,\n \"\\n mutation SdkWriteTextFile($workspaceID: ID!, $path: String!, $text: String!) {\\n writeWorkspaceTextFile(input: { workspaceID: $workspaceID, path: $path, text: $text }) {\\n file {\\n path\\n sizeBytes\\n size\\n sha256\\n updatedAt\\n }\\n }\\n }\\n\": typeof types.SdkWriteTextFileDocument,\n \"\\n mutation SdkWriteBase64File($workspaceID: ID!, $path: String!, $contentBase64: String!) {\\n writeWorkspaceBase64File(\\n input: { workspaceID: $workspaceID, path: $path, contentBase64: $contentBase64 }\\n ) {\\n file {\\n path\\n sizeBytes\\n size\\n sha256\\n updatedAt\\n }\\n }\\n }\\n\": typeof types.SdkWriteBase64FileDocument,\n \"\\n query SdkListFiles($input: ListWorkspaceFilesInput!) {\\n workspaceFilesPage(input: $input) {\\n items {\\n path\\n sizeBytes\\n size\\n sha256\\n updatedAt\\n }\\n total\\n limit\\n offset\\n hasMore\\n nextOffset\\n }\\n }\\n\": typeof types.SdkListFilesDocument,\n \"\\n query SdkReadFile($input: ReadWorkspaceFileInput!) {\\n readWorkspaceFile(input: $input) {\\n text\\n offset\\n limit\\n totalBytes\\n truncated\\n nextOffset\\n file {\\n path\\n sizeBytes\\n size\\n sha256\\n updatedAt\\n }\\n }\\n }\\n\": typeof types.SdkReadFileDocument,\n \"\\n mutation SdkDeleteFile($workspaceID: ID!, $path: String!) {\\n deleteWorkspaceFile(input: { workspaceID: $workspaceID, path: $path }) {\\n ok\\n }\\n }\\n\": typeof types.SdkDeleteFileDocument,\n \"\\n mutation SdkCreateDeployment($input: CreateDeploymentInput!) {\\n createDeployment(input: $input) {\\n deployment {\\n ...DeploymentFields\\n }\\n }\\n }\\n\": typeof types.SdkCreateDeploymentDocument,\n \"\\n mutation SdkDeployWorkspace($input: DeployWorkspaceInput!) {\\n deployWorkspace(input: $input) {\\n deployment {\\n ...DeploymentFields\\n }\\n }\\n }\\n\": typeof types.SdkDeployWorkspaceDocument,\n \"\\n query SdkGetDeployment($id: ID!) {\\n deployment(id: $id) {\\n ...DeploymentFields\\n }\\n }\\n\": typeof types.SdkGetDeploymentDocument,\n \"\\n query SdkPollDeployment($id: ID!) {\\n deployment(id: $id) {\\n id\\n status\\n error\\n aliasHeld\\n url\\n previewUrl\\n }\\n }\\n\": typeof types.SdkPollDeploymentDocument,\n \"\\n query SdkGetDeploymentByAlias($alias: String!) {\\n deploymentByAlias(alias: $alias) {\\n ...DeploymentFields\\n }\\n }\\n\": typeof types.SdkGetDeploymentByAliasDocument,\n \"\\n query SdkListDeployments($input: ListDeploymentsInput) {\\n deploymentsPage(input: $input) {\\n items {\\n ...DeploymentFields\\n }\\n total\\n limit\\n offset\\n hasMore\\n nextOffset\\n }\\n }\\n\": typeof types.SdkListDeploymentsDocument,\n \"\\n query SdkListReleases($alias: String!) {\\n deploymentReleases(alias: $alias) {\\n ...DeploymentFields\\n }\\n }\\n\": typeof types.SdkListReleasesDocument,\n \"\\n mutation SdkRollback(\\n $deploymentID: ID!\\n $expectedCurrentDeploymentID: ID!\\n $expectedCurrentAliasRevision: String!\\n ) {\\n rollbackDeployment(\\n input: {\\n deploymentID: $deploymentID\\n expectedCurrentDeploymentID: $expectedCurrentDeploymentID\\n expectedCurrentAliasRevision: $expectedCurrentAliasRevision\\n }\\n ) {\\n ...DeploymentFields\\n }\\n }\\n\": typeof types.SdkRollbackDocument,\n \"\\n query SdkServiceStatus($deploymentID: ID!) {\\n serviceStatus(deploymentID: $deploymentID) {\\n deploymentID\\n alias\\n serviceMode\\n running\\n health\\n vmID\\n inFlight\\n alwaysOn\\n memSizeMiB\\n startedAt\\n lastUsedAt\\n lastStoppedAt\\n restartCount\\n lastError\\n }\\n }\\n\": typeof types.SdkServiceStatusDocument,\n \"\\n query SdkServiceLogs($deploymentID: ID!, $tailBytes: Int) {\\n serviceLogs(deploymentID: $deploymentID, tailBytes: $tailBytes) {\\n deploymentID\\n stdout\\n stderr\\n truncated\\n stdoutBytes\\n stderrBytes\\n tailBytes\\n }\\n }\\n\": typeof types.SdkServiceLogsDocument,\n \"\\n query SdkDeploymentEvents($deploymentID: ID!, $limit: Int) {\\n deploymentEvents(deploymentID: $deploymentID, limit: $limit) {\\n id\\n deploymentID\\n type\\n rawType\\n severity\\n message\\n vmID\\n createdAt\\n }\\n }\\n\": typeof types.SdkDeploymentEventsDocument,\n \"\\n mutation SdkRestartService($deploymentID: ID!) {\\n restartService(input: { deploymentID: $deploymentID }) {\\n deploymentID\\n running\\n health\\n vmID\\n restartCount\\n lastError\\n }\\n }\\n\": typeof types.SdkRestartServiceDocument,\n \"\\n mutation SdkStopService($deploymentID: ID!) {\\n stopService(input: { deploymentID: $deploymentID }) {\\n deploymentID\\n running\\n health\\n vmID\\n restartCount\\n lastError\\n }\\n }\\n\": typeof types.SdkStopServiceDocument,\n \"\\n mutation SdkDeleteDeployment($deploymentID: ID!) {\\n deleteDeployment(input: { deploymentID: $deploymentID }) {\\n ok\\n }\\n }\\n\": typeof types.SdkDeleteDeploymentDocument,\n \"\\n mutation SdkSetWorkspaceEnv($workspaceID: ID!, $name: String!, $value: String!) {\\n setWorkspaceEnv(input: { workspaceID: $workspaceID, name: $name, value: $value }) {\\n env {\\n name\\n value\\n secret\\n alias\\n inherited\\n masked\\n updatedAt\\n }\\n }\\n }\\n\": typeof types.SdkSetWorkspaceEnvDocument,\n \"\\n mutation SdkSetWorkspaceSecret($workspaceID: ID!, $name: String!, $value: String!) {\\n setWorkspaceSecret(input: { workspaceID: $workspaceID, name: $name, value: $value }) {\\n env {\\n name\\n value\\n secret\\n alias\\n inherited\\n masked\\n updatedAt\\n }\\n }\\n }\\n\": typeof types.SdkSetWorkspaceSecretDocument,\n \"\\n mutation SdkDeleteWorkspaceEnv($workspaceID: ID!, $name: String!) {\\n deleteWorkspaceEnv(input: { workspaceID: $workspaceID, name: $name }) {\\n ok\\n }\\n }\\n\": typeof types.SdkDeleteWorkspaceEnvDocument,\n \"\\n query SdkListWorkspaceEnv($workspaceID: ID!) {\\n workspaceEnv(workspaceID: $workspaceID) {\\n name\\n value\\n secret\\n alias\\n inherited\\n masked\\n updatedAt\\n }\\n }\\n\": typeof types.SdkListWorkspaceEnvDocument,\n \"\\n mutation SdkSetAppEnv($workspaceID: ID!, $alias: String!, $name: String!, $value: String!) {\\n setAppEnv(input: { workspaceID: $workspaceID, alias: $alias, name: $name, value: $value }) {\\n env {\\n name\\n value\\n secret\\n alias\\n inherited\\n masked\\n updatedAt\\n }\\n }\\n }\\n\": typeof types.SdkSetAppEnvDocument,\n \"\\n mutation SdkSetAppSecret($workspaceID: ID!, $alias: String!, $name: String!, $value: String!) {\\n setAppSecret(input: { workspaceID: $workspaceID, alias: $alias, name: $name, value: $value }) {\\n env {\\n name\\n value\\n secret\\n alias\\n inherited\\n masked\\n updatedAt\\n }\\n }\\n }\\n\": typeof types.SdkSetAppSecretDocument,\n \"\\n mutation SdkRemoveAppEnv($workspaceID: ID!, $alias: String!, $name: String!) {\\n removeAppEnv(input: { workspaceID: $workspaceID, alias: $alias, name: $name }) {\\n ok\\n }\\n }\\n\": typeof types.SdkRemoveAppEnvDocument,\n \"\\n mutation SdkInheritAppEnv($workspaceID: ID!, $alias: String!, $name: String!) {\\n inheritAppEnv(input: { workspaceID: $workspaceID, alias: $alias, name: $name }) {\\n ok\\n }\\n }\\n\": typeof types.SdkInheritAppEnvDocument,\n \"\\n query SdkListAppEnv($workspaceID: ID!, $alias: String!) {\\n appEnv(workspaceID: $workspaceID, alias: $alias) {\\n name\\n value\\n secret\\n alias\\n inherited\\n masked\\n updatedAt\\n }\\n }\\n\": typeof types.SdkListAppEnvDocument,\n \"\\n fragment RunFields on Run {\\n id\\n workspaceID\\n ownerId\\n status\\n rawStatus\\n command\\n harness\\n prompt\\n setup\\n skills\\n verify\\n approval\\n mode\\n access\\n alias\\n integrations {\\n kind\\n bindingID\\n env\\n skills\\n mcpServers {\\n name\\n transport\\n readOnly\\n }\\n }\\n parentRunID\\n depth\\n question {\\n id\\n text\\n options\\n askedAt\\n }\\n memoryMiB\\n maxSeconds\\n metadata\\n error\\n exitCode\\n result {\\n status\\n detail\\n text\\n }\\n verifyExitCode\\n vmID\\n transcriptAvailable\\n usage {\\n vmSeconds\\n memoryMiB\\n mibSeconds\\n }\\n createdAt\\n startedAt\\n settledAt\\n }\\n\": typeof types.RunFieldsFragmentDoc,\n \"\\n mutation SdkCreateRun($input: CreateRunInput!) {\\n createRun(input: $input) {\\n ...RunFields\\n }\\n }\\n\": typeof types.SdkCreateRunDocument,\n \"\\n query SdkGetRun($id: ID!) {\\n run(id: $id) {\\n ...RunFields\\n }\\n }\\n\": typeof types.SdkGetRunDocument,\n \"\\n query SdkPollRun($id: ID!) {\\n run(id: $id) {\\n id\\n status\\n error\\n exitCode\\n }\\n }\\n\": typeof types.SdkPollRunDocument,\n \"\\n query SdkListRuns($input: ListRunsInput) {\\n runs(input: $input) {\\n items {\\n ...RunFields\\n }\\n total\\n limit\\n offset\\n hasMore\\n nextOffset\\n }\\n }\\n\": typeof types.SdkListRunsDocument,\n \"\\n mutation SdkCancelRun($id: ID!) {\\n cancelRun(id: $id) {\\n ...RunFields\\n }\\n }\\n\": typeof types.SdkCancelRunDocument,\n \"\\n query SdkRunEvents($runID: ID!, $limit: Int) {\\n runEvents(runID: $runID, limit: $limit) {\\n id\\n runID\\n type\\n severity\\n message\\n metadata\\n createdAt\\n }\\n }\\n\": typeof types.SdkRunEventsDocument,\n \"\\n query SdkRunConsole($id: ID!, $tailBytes: Int) {\\n runConsole(id: $id, tailBytes: $tailBytes) {\\n runID\\n running\\n text\\n }\\n }\\n\": typeof types.SdkRunConsoleDocument,\n \"\\n query SdkRunTranscript($id: ID!, $tailBytes: Int) {\\n runTranscript(id: $id, tailBytes: $tailBytes) {\\n runID\\n available\\n text\\n totalBytes\\n truncated\\n }\\n }\\n\": typeof types.SdkRunTranscriptDocument,\n \"\\n mutation SdkAnswerRun($id: ID!, $answer: String!) {\\n answerRun(id: $id, answer: $answer) {\\n ...RunFields\\n }\\n }\\n\": typeof types.SdkAnswerRunDocument,\n \"\\n mutation SdkFollowUpRun($input: FollowUpRunInput!) {\\n followUpRun(input: $input) {\\n ...RunFields\\n }\\n }\\n\": typeof types.SdkFollowUpRunDocument,\n \"\\n query SdkRunHarnesses {\\n runHarnesses {\\n name\\n title\\n summary\\n requires\\n }\\n }\\n\": typeof types.SdkRunHarnessesDocument,\n};\nconst documents: Documents = {\n \"\\n fragment DeploymentFields on Deployment {\\n id\\n workspaceID\\n kind\\n runtime\\n alias\\n serviceMode\\n healthPath\\n cronSchedule\\n cronPath\\n url\\n previewUrl\\n sshCommand\\n aliasHeld\\n aliasRevision\\n status\\n error\\n filesCount\\n sizeBytes\\n size\\n spaMode\\n gitRepo\\n gitCommit\\n createdAt\\n }\\n\": types.DeploymentFieldsFragmentDoc,\n \"\\n query SdkWhoami {\\n whoami {\\n kind\\n userID\\n name\\n agentID\\n agentName\\n claimed\\n claimedBy\\n scopes\\n expiresAt\\n usage {\\n month\\n requests\\n limit\\n }\\n resources {\\n workspaces\\n workspaceLimit\\n services\\n serviceLimit\\n }\\n }\\n }\\n\": types.SdkWhoamiDocument,\n \"\\n mutation SdkCreateWorkspace($name: String!) {\\n createWorkspace(input: { name: $name }) {\\n workspace {\\n id\\n name\\n ownerId\\n projectId\\n createdAt\\n updatedAt\\n }\\n }\\n }\\n\": types.SdkCreateWorkspaceDocument,\n \"\\n query SdkListWorkspaces {\\n workspaces {\\n id\\n name\\n ownerId\\n projectId\\n createdAt\\n updatedAt\\n }\\n }\\n\": types.SdkListWorkspacesDocument,\n \"\\n mutation SdkDeleteWorkspace($workspaceID: ID!, $withDeployments: Boolean) {\\n deleteWorkspace(input: { workspaceID: $workspaceID, withDeployments: $withDeployments }) {\\n ok\\n }\\n }\\n\": types.SdkDeleteWorkspaceDocument,\n \"\\n mutation SdkWriteTextFile($workspaceID: ID!, $path: String!, $text: String!) {\\n writeWorkspaceTextFile(input: { workspaceID: $workspaceID, path: $path, text: $text }) {\\n file {\\n path\\n sizeBytes\\n size\\n sha256\\n updatedAt\\n }\\n }\\n }\\n\": types.SdkWriteTextFileDocument,\n \"\\n mutation SdkWriteBase64File($workspaceID: ID!, $path: String!, $contentBase64: String!) {\\n writeWorkspaceBase64File(\\n input: { workspaceID: $workspaceID, path: $path, contentBase64: $contentBase64 }\\n ) {\\n file {\\n path\\n sizeBytes\\n size\\n sha256\\n updatedAt\\n }\\n }\\n }\\n\": types.SdkWriteBase64FileDocument,\n \"\\n query SdkListFiles($input: ListWorkspaceFilesInput!) {\\n workspaceFilesPage(input: $input) {\\n items {\\n path\\n sizeBytes\\n size\\n sha256\\n updatedAt\\n }\\n total\\n limit\\n offset\\n hasMore\\n nextOffset\\n }\\n }\\n\": types.SdkListFilesDocument,\n \"\\n query SdkReadFile($input: ReadWorkspaceFileInput!) {\\n readWorkspaceFile(input: $input) {\\n text\\n offset\\n limit\\n totalBytes\\n truncated\\n nextOffset\\n file {\\n path\\n sizeBytes\\n size\\n sha256\\n updatedAt\\n }\\n }\\n }\\n\": types.SdkReadFileDocument,\n \"\\n mutation SdkDeleteFile($workspaceID: ID!, $path: String!) {\\n deleteWorkspaceFile(input: { workspaceID: $workspaceID, path: $path }) {\\n ok\\n }\\n }\\n\": types.SdkDeleteFileDocument,\n \"\\n mutation SdkCreateDeployment($input: CreateDeploymentInput!) {\\n createDeployment(input: $input) {\\n deployment {\\n ...DeploymentFields\\n }\\n }\\n }\\n\": types.SdkCreateDeploymentDocument,\n \"\\n mutation SdkDeployWorkspace($input: DeployWorkspaceInput!) {\\n deployWorkspace(input: $input) {\\n deployment {\\n ...DeploymentFields\\n }\\n }\\n }\\n\": types.SdkDeployWorkspaceDocument,\n \"\\n query SdkGetDeployment($id: ID!) {\\n deployment(id: $id) {\\n ...DeploymentFields\\n }\\n }\\n\": types.SdkGetDeploymentDocument,\n \"\\n query SdkPollDeployment($id: ID!) {\\n deployment(id: $id) {\\n id\\n status\\n error\\n aliasHeld\\n url\\n previewUrl\\n }\\n }\\n\": types.SdkPollDeploymentDocument,\n \"\\n query SdkGetDeploymentByAlias($alias: String!) {\\n deploymentByAlias(alias: $alias) {\\n ...DeploymentFields\\n }\\n }\\n\": types.SdkGetDeploymentByAliasDocument,\n \"\\n query SdkListDeployments($input: ListDeploymentsInput) {\\n deploymentsPage(input: $input) {\\n items {\\n ...DeploymentFields\\n }\\n total\\n limit\\n offset\\n hasMore\\n nextOffset\\n }\\n }\\n\": types.SdkListDeploymentsDocument,\n \"\\n query SdkListReleases($alias: String!) {\\n deploymentReleases(alias: $alias) {\\n ...DeploymentFields\\n }\\n }\\n\": types.SdkListReleasesDocument,\n \"\\n mutation SdkRollback(\\n $deploymentID: ID!\\n $expectedCurrentDeploymentID: ID!\\n $expectedCurrentAliasRevision: String!\\n ) {\\n rollbackDeployment(\\n input: {\\n deploymentID: $deploymentID\\n expectedCurrentDeploymentID: $expectedCurrentDeploymentID\\n expectedCurrentAliasRevision: $expectedCurrentAliasRevision\\n }\\n ) {\\n ...DeploymentFields\\n }\\n }\\n\": types.SdkRollbackDocument,\n \"\\n query SdkServiceStatus($deploymentID: ID!) {\\n serviceStatus(deploymentID: $deploymentID) {\\n deploymentID\\n alias\\n serviceMode\\n running\\n health\\n vmID\\n inFlight\\n alwaysOn\\n memSizeMiB\\n startedAt\\n lastUsedAt\\n lastStoppedAt\\n restartCount\\n lastError\\n }\\n }\\n\": types.SdkServiceStatusDocument,\n \"\\n query SdkServiceLogs($deploymentID: ID!, $tailBytes: Int) {\\n serviceLogs(deploymentID: $deploymentID, tailBytes: $tailBytes) {\\n deploymentID\\n stdout\\n stderr\\n truncated\\n stdoutBytes\\n stderrBytes\\n tailBytes\\n }\\n }\\n\": types.SdkServiceLogsDocument,\n \"\\n query SdkDeploymentEvents($deploymentID: ID!, $limit: Int) {\\n deploymentEvents(deploymentID: $deploymentID, limit: $limit) {\\n id\\n deploymentID\\n type\\n rawType\\n severity\\n message\\n vmID\\n createdAt\\n }\\n }\\n\": types.SdkDeploymentEventsDocument,\n \"\\n mutation SdkRestartService($deploymentID: ID!) {\\n restartService(input: { deploymentID: $deploymentID }) {\\n deploymentID\\n running\\n health\\n vmID\\n restartCount\\n lastError\\n }\\n }\\n\": types.SdkRestartServiceDocument,\n \"\\n mutation SdkStopService($deploymentID: ID!) {\\n stopService(input: { deploymentID: $deploymentID }) {\\n deploymentID\\n running\\n health\\n vmID\\n restartCount\\n lastError\\n }\\n }\\n\": types.SdkStopServiceDocument,\n \"\\n mutation SdkDeleteDeployment($deploymentID: ID!) {\\n deleteDeployment(input: { deploymentID: $deploymentID }) {\\n ok\\n }\\n }\\n\": types.SdkDeleteDeploymentDocument,\n \"\\n mutation SdkSetWorkspaceEnv($workspaceID: ID!, $name: String!, $value: String!) {\\n setWorkspaceEnv(input: { workspaceID: $workspaceID, name: $name, value: $value }) {\\n env {\\n name\\n value\\n secret\\n alias\\n inherited\\n masked\\n updatedAt\\n }\\n }\\n }\\n\": types.SdkSetWorkspaceEnvDocument,\n \"\\n mutation SdkSetWorkspaceSecret($workspaceID: ID!, $name: String!, $value: String!) {\\n setWorkspaceSecret(input: { workspaceID: $workspaceID, name: $name, value: $value }) {\\n env {\\n name\\n value\\n secret\\n alias\\n inherited\\n masked\\n updatedAt\\n }\\n }\\n }\\n\": types.SdkSetWorkspaceSecretDocument,\n \"\\n mutation SdkDeleteWorkspaceEnv($workspaceID: ID!, $name: String!) {\\n deleteWorkspaceEnv(input: { workspaceID: $workspaceID, name: $name }) {\\n ok\\n }\\n }\\n\": types.SdkDeleteWorkspaceEnvDocument,\n \"\\n query SdkListWorkspaceEnv($workspaceID: ID!) {\\n workspaceEnv(workspaceID: $workspaceID) {\\n name\\n value\\n secret\\n alias\\n inherited\\n masked\\n updatedAt\\n }\\n }\\n\": types.SdkListWorkspaceEnvDocument,\n \"\\n mutation SdkSetAppEnv($workspaceID: ID!, $alias: String!, $name: String!, $value: String!) {\\n setAppEnv(input: { workspaceID: $workspaceID, alias: $alias, name: $name, value: $value }) {\\n env {\\n name\\n value\\n secret\\n alias\\n inherited\\n masked\\n updatedAt\\n }\\n }\\n }\\n\": types.SdkSetAppEnvDocument,\n \"\\n mutation SdkSetAppSecret($workspaceID: ID!, $alias: String!, $name: String!, $value: String!) {\\n setAppSecret(input: { workspaceID: $workspaceID, alias: $alias, name: $name, value: $value }) {\\n env {\\n name\\n value\\n secret\\n alias\\n inherited\\n masked\\n updatedAt\\n }\\n }\\n }\\n\": types.SdkSetAppSecretDocument,\n \"\\n mutation SdkRemoveAppEnv($workspaceID: ID!, $alias: String!, $name: String!) {\\n removeAppEnv(input: { workspaceID: $workspaceID, alias: $alias, name: $name }) {\\n ok\\n }\\n }\\n\": types.SdkRemoveAppEnvDocument,\n \"\\n mutation SdkInheritAppEnv($workspaceID: ID!, $alias: String!, $name: String!) {\\n inheritAppEnv(input: { workspaceID: $workspaceID, alias: $alias, name: $name }) {\\n ok\\n }\\n }\\n\": types.SdkInheritAppEnvDocument,\n \"\\n query SdkListAppEnv($workspaceID: ID!, $alias: String!) {\\n appEnv(workspaceID: $workspaceID, alias: $alias) {\\n name\\n value\\n secret\\n alias\\n inherited\\n masked\\n updatedAt\\n }\\n }\\n\": types.SdkListAppEnvDocument,\n \"\\n fragment RunFields on Run {\\n id\\n workspaceID\\n ownerId\\n status\\n rawStatus\\n command\\n harness\\n prompt\\n setup\\n skills\\n verify\\n approval\\n mode\\n access\\n alias\\n integrations {\\n kind\\n bindingID\\n env\\n skills\\n mcpServers {\\n name\\n transport\\n readOnly\\n }\\n }\\n parentRunID\\n depth\\n question {\\n id\\n text\\n options\\n askedAt\\n }\\n memoryMiB\\n maxSeconds\\n metadata\\n error\\n exitCode\\n result {\\n status\\n detail\\n text\\n }\\n verifyExitCode\\n vmID\\n transcriptAvailable\\n usage {\\n vmSeconds\\n memoryMiB\\n mibSeconds\\n }\\n createdAt\\n startedAt\\n settledAt\\n }\\n\": types.RunFieldsFragmentDoc,\n \"\\n mutation SdkCreateRun($input: CreateRunInput!) {\\n createRun(input: $input) {\\n ...RunFields\\n }\\n }\\n\": types.SdkCreateRunDocument,\n \"\\n query SdkGetRun($id: ID!) {\\n run(id: $id) {\\n ...RunFields\\n }\\n }\\n\": types.SdkGetRunDocument,\n \"\\n query SdkPollRun($id: ID!) {\\n run(id: $id) {\\n id\\n status\\n error\\n exitCode\\n }\\n }\\n\": types.SdkPollRunDocument,\n \"\\n query SdkListRuns($input: ListRunsInput) {\\n runs(input: $input) {\\n items {\\n ...RunFields\\n }\\n total\\n limit\\n offset\\n hasMore\\n nextOffset\\n }\\n }\\n\": types.SdkListRunsDocument,\n \"\\n mutation SdkCancelRun($id: ID!) {\\n cancelRun(id: $id) {\\n ...RunFields\\n }\\n }\\n\": types.SdkCancelRunDocument,\n \"\\n query SdkRunEvents($runID: ID!, $limit: Int) {\\n runEvents(runID: $runID, limit: $limit) {\\n id\\n runID\\n type\\n severity\\n message\\n metadata\\n createdAt\\n }\\n }\\n\": types.SdkRunEventsDocument,\n \"\\n query SdkRunConsole($id: ID!, $tailBytes: Int) {\\n runConsole(id: $id, tailBytes: $tailBytes) {\\n runID\\n running\\n text\\n }\\n }\\n\": types.SdkRunConsoleDocument,\n \"\\n query SdkRunTranscript($id: ID!, $tailBytes: Int) {\\n runTranscript(id: $id, tailBytes: $tailBytes) {\\n runID\\n available\\n text\\n totalBytes\\n truncated\\n }\\n }\\n\": types.SdkRunTranscriptDocument,\n \"\\n mutation SdkAnswerRun($id: ID!, $answer: String!) {\\n answerRun(id: $id, answer: $answer) {\\n ...RunFields\\n }\\n }\\n\": types.SdkAnswerRunDocument,\n \"\\n mutation SdkFollowUpRun($input: FollowUpRunInput!) {\\n followUpRun(input: $input) {\\n ...RunFields\\n }\\n }\\n\": types.SdkFollowUpRunDocument,\n \"\\n query SdkRunHarnesses {\\n runHarnesses {\\n name\\n title\\n summary\\n requires\\n }\\n }\\n\": types.SdkRunHarnessesDocument,\n};\n\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n fragment DeploymentFields on Deployment {\\n id\\n workspaceID\\n kind\\n runtime\\n alias\\n serviceMode\\n healthPath\\n cronSchedule\\n cronPath\\n url\\n previewUrl\\n sshCommand\\n aliasHeld\\n aliasRevision\\n status\\n error\\n filesCount\\n sizeBytes\\n size\\n spaMode\\n gitRepo\\n gitCommit\\n createdAt\\n }\\n\"): typeof import('./graphql.js').DeploymentFieldsFragmentDoc;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n query SdkWhoami {\\n whoami {\\n kind\\n userID\\n name\\n agentID\\n agentName\\n claimed\\n claimedBy\\n scopes\\n expiresAt\\n usage {\\n month\\n requests\\n limit\\n }\\n resources {\\n workspaces\\n workspaceLimit\\n services\\n serviceLimit\\n }\\n }\\n }\\n\"): typeof import('./graphql.js').SdkWhoamiDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n mutation SdkCreateWorkspace($name: String!) {\\n createWorkspace(input: { name: $name }) {\\n workspace {\\n id\\n name\\n ownerId\\n projectId\\n createdAt\\n updatedAt\\n }\\n }\\n }\\n\"): typeof import('./graphql.js').SdkCreateWorkspaceDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n query SdkListWorkspaces {\\n workspaces {\\n id\\n name\\n ownerId\\n projectId\\n createdAt\\n updatedAt\\n }\\n }\\n\"): typeof import('./graphql.js').SdkListWorkspacesDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n mutation SdkDeleteWorkspace($workspaceID: ID!, $withDeployments: Boolean) {\\n deleteWorkspace(input: { workspaceID: $workspaceID, withDeployments: $withDeployments }) {\\n ok\\n }\\n }\\n\"): typeof import('./graphql.js').SdkDeleteWorkspaceDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n mutation SdkWriteTextFile($workspaceID: ID!, $path: String!, $text: String!) {\\n writeWorkspaceTextFile(input: { workspaceID: $workspaceID, path: $path, text: $text }) {\\n file {\\n path\\n sizeBytes\\n size\\n sha256\\n updatedAt\\n }\\n }\\n }\\n\"): typeof import('./graphql.js').SdkWriteTextFileDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n mutation SdkWriteBase64File($workspaceID: ID!, $path: String!, $contentBase64: String!) {\\n writeWorkspaceBase64File(\\n input: { workspaceID: $workspaceID, path: $path, contentBase64: $contentBase64 }\\n ) {\\n file {\\n path\\n sizeBytes\\n size\\n sha256\\n updatedAt\\n }\\n }\\n }\\n\"): typeof import('./graphql.js').SdkWriteBase64FileDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n query SdkListFiles($input: ListWorkspaceFilesInput!) {\\n workspaceFilesPage(input: $input) {\\n items {\\n path\\n sizeBytes\\n size\\n sha256\\n updatedAt\\n }\\n total\\n limit\\n offset\\n hasMore\\n nextOffset\\n }\\n }\\n\"): typeof import('./graphql.js').SdkListFilesDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n query SdkReadFile($input: ReadWorkspaceFileInput!) {\\n readWorkspaceFile(input: $input) {\\n text\\n offset\\n limit\\n totalBytes\\n truncated\\n nextOffset\\n file {\\n path\\n sizeBytes\\n size\\n sha256\\n updatedAt\\n }\\n }\\n }\\n\"): typeof import('./graphql.js').SdkReadFileDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n mutation SdkDeleteFile($workspaceID: ID!, $path: String!) {\\n deleteWorkspaceFile(input: { workspaceID: $workspaceID, path: $path }) {\\n ok\\n }\\n }\\n\"): typeof import('./graphql.js').SdkDeleteFileDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n mutation SdkCreateDeployment($input: CreateDeploymentInput!) {\\n createDeployment(input: $input) {\\n deployment {\\n ...DeploymentFields\\n }\\n }\\n }\\n\"): typeof import('./graphql.js').SdkCreateDeploymentDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n mutation SdkDeployWorkspace($input: DeployWorkspaceInput!) {\\n deployWorkspace(input: $input) {\\n deployment {\\n ...DeploymentFields\\n }\\n }\\n }\\n\"): typeof import('./graphql.js').SdkDeployWorkspaceDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n query SdkGetDeployment($id: ID!) {\\n deployment(id: $id) {\\n ...DeploymentFields\\n }\\n }\\n\"): typeof import('./graphql.js').SdkGetDeploymentDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n query SdkPollDeployment($id: ID!) {\\n deployment(id: $id) {\\n id\\n status\\n error\\n aliasHeld\\n url\\n previewUrl\\n }\\n }\\n\"): typeof import('./graphql.js').SdkPollDeploymentDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n query SdkGetDeploymentByAlias($alias: String!) {\\n deploymentByAlias(alias: $alias) {\\n ...DeploymentFields\\n }\\n }\\n\"): typeof import('./graphql.js').SdkGetDeploymentByAliasDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n query SdkListDeployments($input: ListDeploymentsInput) {\\n deploymentsPage(input: $input) {\\n items {\\n ...DeploymentFields\\n }\\n total\\n limit\\n offset\\n hasMore\\n nextOffset\\n }\\n }\\n\"): typeof import('./graphql.js').SdkListDeploymentsDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n query SdkListReleases($alias: String!) {\\n deploymentReleases(alias: $alias) {\\n ...DeploymentFields\\n }\\n }\\n\"): typeof import('./graphql.js').SdkListReleasesDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n mutation SdkRollback(\\n $deploymentID: ID!\\n $expectedCurrentDeploymentID: ID!\\n $expectedCurrentAliasRevision: String!\\n ) {\\n rollbackDeployment(\\n input: {\\n deploymentID: $deploymentID\\n expectedCurrentDeploymentID: $expectedCurrentDeploymentID\\n expectedCurrentAliasRevision: $expectedCurrentAliasRevision\\n }\\n ) {\\n ...DeploymentFields\\n }\\n }\\n\"): typeof import('./graphql.js').SdkRollbackDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n query SdkServiceStatus($deploymentID: ID!) {\\n serviceStatus(deploymentID: $deploymentID) {\\n deploymentID\\n alias\\n serviceMode\\n running\\n health\\n vmID\\n inFlight\\n alwaysOn\\n memSizeMiB\\n startedAt\\n lastUsedAt\\n lastStoppedAt\\n restartCount\\n lastError\\n }\\n }\\n\"): typeof import('./graphql.js').SdkServiceStatusDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n query SdkServiceLogs($deploymentID: ID!, $tailBytes: Int) {\\n serviceLogs(deploymentID: $deploymentID, tailBytes: $tailBytes) {\\n deploymentID\\n stdout\\n stderr\\n truncated\\n stdoutBytes\\n stderrBytes\\n tailBytes\\n }\\n }\\n\"): typeof import('./graphql.js').SdkServiceLogsDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n query SdkDeploymentEvents($deploymentID: ID!, $limit: Int) {\\n deploymentEvents(deploymentID: $deploymentID, limit: $limit) {\\n id\\n deploymentID\\n type\\n rawType\\n severity\\n message\\n vmID\\n createdAt\\n }\\n }\\n\"): typeof import('./graphql.js').SdkDeploymentEventsDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n mutation SdkRestartService($deploymentID: ID!) {\\n restartService(input: { deploymentID: $deploymentID }) {\\n deploymentID\\n running\\n health\\n vmID\\n restartCount\\n lastError\\n }\\n }\\n\"): typeof import('./graphql.js').SdkRestartServiceDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n mutation SdkStopService($deploymentID: ID!) {\\n stopService(input: { deploymentID: $deploymentID }) {\\n deploymentID\\n running\\n health\\n vmID\\n restartCount\\n lastError\\n }\\n }\\n\"): typeof import('./graphql.js').SdkStopServiceDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n mutation SdkDeleteDeployment($deploymentID: ID!) {\\n deleteDeployment(input: { deploymentID: $deploymentID }) {\\n ok\\n }\\n }\\n\"): typeof import('./graphql.js').SdkDeleteDeploymentDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n mutation SdkSetWorkspaceEnv($workspaceID: ID!, $name: String!, $value: String!) {\\n setWorkspaceEnv(input: { workspaceID: $workspaceID, name: $name, value: $value }) {\\n env {\\n name\\n value\\n secret\\n alias\\n inherited\\n masked\\n updatedAt\\n }\\n }\\n }\\n\"): typeof import('./graphql.js').SdkSetWorkspaceEnvDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n mutation SdkSetWorkspaceSecret($workspaceID: ID!, $name: String!, $value: String!) {\\n setWorkspaceSecret(input: { workspaceID: $workspaceID, name: $name, value: $value }) {\\n env {\\n name\\n value\\n secret\\n alias\\n inherited\\n masked\\n updatedAt\\n }\\n }\\n }\\n\"): typeof import('./graphql.js').SdkSetWorkspaceSecretDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n mutation SdkDeleteWorkspaceEnv($workspaceID: ID!, $name: String!) {\\n deleteWorkspaceEnv(input: { workspaceID: $workspaceID, name: $name }) {\\n ok\\n }\\n }\\n\"): typeof import('./graphql.js').SdkDeleteWorkspaceEnvDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n query SdkListWorkspaceEnv($workspaceID: ID!) {\\n workspaceEnv(workspaceID: $workspaceID) {\\n name\\n value\\n secret\\n alias\\n inherited\\n masked\\n updatedAt\\n }\\n }\\n\"): typeof import('./graphql.js').SdkListWorkspaceEnvDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n mutation SdkSetAppEnv($workspaceID: ID!, $alias: String!, $name: String!, $value: String!) {\\n setAppEnv(input: { workspaceID: $workspaceID, alias: $alias, name: $name, value: $value }) {\\n env {\\n name\\n value\\n secret\\n alias\\n inherited\\n masked\\n updatedAt\\n }\\n }\\n }\\n\"): typeof import('./graphql.js').SdkSetAppEnvDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n mutation SdkSetAppSecret($workspaceID: ID!, $alias: String!, $name: String!, $value: String!) {\\n setAppSecret(input: { workspaceID: $workspaceID, alias: $alias, name: $name, value: $value }) {\\n env {\\n name\\n value\\n secret\\n alias\\n inherited\\n masked\\n updatedAt\\n }\\n }\\n }\\n\"): typeof import('./graphql.js').SdkSetAppSecretDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n mutation SdkRemoveAppEnv($workspaceID: ID!, $alias: String!, $name: String!) {\\n removeAppEnv(input: { workspaceID: $workspaceID, alias: $alias, name: $name }) {\\n ok\\n }\\n }\\n\"): typeof import('./graphql.js').SdkRemoveAppEnvDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n mutation SdkInheritAppEnv($workspaceID: ID!, $alias: String!, $name: String!) {\\n inheritAppEnv(input: { workspaceID: $workspaceID, alias: $alias, name: $name }) {\\n ok\\n }\\n }\\n\"): typeof import('./graphql.js').SdkInheritAppEnvDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n query SdkListAppEnv($workspaceID: ID!, $alias: String!) {\\n appEnv(workspaceID: $workspaceID, alias: $alias) {\\n name\\n value\\n secret\\n alias\\n inherited\\n masked\\n updatedAt\\n }\\n }\\n\"): typeof import('./graphql.js').SdkListAppEnvDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n fragment RunFields on Run {\\n id\\n workspaceID\\n ownerId\\n status\\n rawStatus\\n command\\n harness\\n prompt\\n setup\\n skills\\n verify\\n approval\\n mode\\n access\\n alias\\n integrations {\\n kind\\n bindingID\\n env\\n skills\\n mcpServers {\\n name\\n transport\\n readOnly\\n }\\n }\\n parentRunID\\n depth\\n question {\\n id\\n text\\n options\\n askedAt\\n }\\n memoryMiB\\n maxSeconds\\n metadata\\n error\\n exitCode\\n result {\\n status\\n detail\\n text\\n }\\n verifyExitCode\\n vmID\\n transcriptAvailable\\n usage {\\n vmSeconds\\n memoryMiB\\n mibSeconds\\n }\\n createdAt\\n startedAt\\n settledAt\\n }\\n\"): typeof import('./graphql.js').RunFieldsFragmentDoc;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n mutation SdkCreateRun($input: CreateRunInput!) {\\n createRun(input: $input) {\\n ...RunFields\\n }\\n }\\n\"): typeof import('./graphql.js').SdkCreateRunDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n query SdkGetRun($id: ID!) {\\n run(id: $id) {\\n ...RunFields\\n }\\n }\\n\"): typeof import('./graphql.js').SdkGetRunDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n query SdkPollRun($id: ID!) {\\n run(id: $id) {\\n id\\n status\\n error\\n exitCode\\n }\\n }\\n\"): typeof import('./graphql.js').SdkPollRunDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n query SdkListRuns($input: ListRunsInput) {\\n runs(input: $input) {\\n items {\\n ...RunFields\\n }\\n total\\n limit\\n offset\\n hasMore\\n nextOffset\\n }\\n }\\n\"): typeof import('./graphql.js').SdkListRunsDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n mutation SdkCancelRun($id: ID!) {\\n cancelRun(id: $id) {\\n ...RunFields\\n }\\n }\\n\"): typeof import('./graphql.js').SdkCancelRunDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n query SdkRunEvents($runID: ID!, $limit: Int) {\\n runEvents(runID: $runID, limit: $limit) {\\n id\\n runID\\n type\\n severity\\n message\\n metadata\\n createdAt\\n }\\n }\\n\"): typeof import('./graphql.js').SdkRunEventsDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n query SdkRunConsole($id: ID!, $tailBytes: Int) {\\n runConsole(id: $id, tailBytes: $tailBytes) {\\n runID\\n running\\n text\\n }\\n }\\n\"): typeof import('./graphql.js').SdkRunConsoleDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n query SdkRunTranscript($id: ID!, $tailBytes: Int) {\\n runTranscript(id: $id, tailBytes: $tailBytes) {\\n runID\\n available\\n text\\n totalBytes\\n truncated\\n }\\n }\\n\"): typeof import('./graphql.js').SdkRunTranscriptDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n mutation SdkAnswerRun($id: ID!, $answer: String!) {\\n answerRun(id: $id, answer: $answer) {\\n ...RunFields\\n }\\n }\\n\"): typeof import('./graphql.js').SdkAnswerRunDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n mutation SdkFollowUpRun($input: FollowUpRunInput!) {\\n followUpRun(input: $input) {\\n ...RunFields\\n }\\n }\\n\"): typeof import('./graphql.js').SdkFollowUpRunDocument;\n/**\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.\n */\nexport function graphql(source: \"\\n query SdkRunHarnesses {\\n runHarnesses {\\n name\\n title\\n summary\\n requires\\n }\\n }\\n\"): typeof import('./graphql.js').SdkRunHarnessesDocument;\n\n\nexport function graphql(source: string) {\n return (documents as any)[source] ?? {};\n}\n"]}