@shipeasy/openapi 3.2.0 → 3.4.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.
Files changed (40) hide show
  1. package/README.md +1 -1
  2. package/dist/{chunk-RTN572TI.js → chunk-JJA7XEPU.js} +91 -1
  3. package/dist/chunk-JJA7XEPU.js.map +1 -0
  4. package/dist/{chunk-DW33MG4B.js → chunk-Z3CY5Y44.js} +514 -126
  5. package/dist/chunk-Z3CY5Y44.js.map +1 -0
  6. package/dist/{client-BPVn4hMC.d.ts → client-CkRbr8I2.d.ts} +1544 -212
  7. package/dist/client.d.ts +1 -1
  8. package/dist/client.js +23 -1
  9. package/dist/custom.d.ts +5 -5
  10. package/dist/custom.js +128 -84
  11. package/dist/custom.js.map +1 -1
  12. package/dist/index.d.ts +2 -2
  13. package/dist/index.js +24 -2
  14. package/dist/index.js.map +1 -1
  15. package/dist/schemas.d.ts +1935 -963
  16. package/dist/schemas.js +141 -1
  17. package/openapi-sdk.json +31 -9
  18. package/openapi.json +10449 -8118
  19. package/openapi.yaml +2274 -634
  20. package/package.json +1 -1
  21. package/spec/components/schemas/alert-rules.yaml +434 -10
  22. package/spec/components/schemas/alerts.yaml +9 -7
  23. package/spec/components/schemas/common.yaml +2 -2
  24. package/spec/components/schemas/connectors.yaml +69 -6
  25. package/spec/components/schemas/events.yaml +20 -9
  26. package/spec/components/schemas/keys.yaml +39 -0
  27. package/spec/components/schemas/metrics.yaml +131 -251
  28. package/spec/components/schemas/ops.yaml +471 -29
  29. package/spec/components/schemas/projects.yaml +18 -0
  30. package/spec/components/schemas/search.yaml +1 -0
  31. package/spec/components/schemas/tags.yaml +91 -0
  32. package/spec/openapi.yaml +56 -0
  33. package/spec/paths/alerts.yaml +5 -3
  34. package/spec/paths/i18n.yaml +2 -1
  35. package/spec/paths/keys.yaml +79 -0
  36. package/spec/paths/metrics.yaml +26 -17
  37. package/spec/paths/ops.yaml +514 -11
  38. package/spec/paths/tags.yaml +270 -0
  39. package/dist/chunk-DW33MG4B.js.map +0 -1
  40. package/dist/chunk-RTN572TI.js.map +0 -1
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../src/generated/core/bodySerializer.gen.ts","../src/generated/core/params.gen.ts","../src/generated/core/serverSentEvents.gen.ts","../src/generated/core/pathSerializer.gen.ts","../src/generated/core/utils.gen.ts","../src/generated/core/auth.gen.ts","../src/generated/client/utils.gen.ts","../src/generated/client/client.gen.ts","../src/generated/client.gen.ts","../src/generated/sdk.gen.ts","../src/client.ts"],"sourcesContent":["// This file is auto-generated by @hey-api/openapi-ts\n\nimport type { ArrayStyle, ObjectStyle, SerializerOptions } from './pathSerializer.gen';\n\nexport type QuerySerializer = (query: Record<string, unknown>) => string;\n\nexport type BodySerializer = (body: unknown) => unknown;\n\ntype QuerySerializerOptionsObject = {\n allowReserved?: boolean;\n array?: Partial<SerializerOptions<ArrayStyle>>;\n object?: Partial<SerializerOptions<ObjectStyle>>;\n};\n\nexport type QuerySerializerOptions = QuerySerializerOptionsObject & {\n /**\n * Per-parameter serialization overrides. When provided, these settings\n * override the global array/object settings for specific parameter names.\n */\n parameters?: Record<string, QuerySerializerOptionsObject>;\n};\n\nconst serializeFormDataPair = (data: FormData, key: string, value: unknown): void => {\n if (typeof value === 'string' || value instanceof Blob) {\n data.append(key, value);\n } else if (value instanceof Date) {\n data.append(key, value.toISOString());\n } else {\n data.append(key, JSON.stringify(value));\n }\n};\n\nconst serializeUrlSearchParamsPair = (data: URLSearchParams, key: string, value: unknown): void => {\n if (typeof value === 'string') {\n data.append(key, value);\n } else {\n data.append(key, JSON.stringify(value));\n }\n};\n\nexport const formDataBodySerializer = {\n bodySerializer: (body: unknown): FormData => {\n const data = new FormData();\n\n Object.entries(body as Record<string, unknown>).forEach(([key, value]) => {\n if (value === undefined || value === null) {\n return;\n }\n if (Array.isArray(value)) {\n value.forEach((v) => serializeFormDataPair(data, key, v));\n } else {\n serializeFormDataPair(data, key, value);\n }\n });\n\n return data;\n },\n};\n\nexport const jsonBodySerializer = {\n bodySerializer: (body: unknown): string =>\n JSON.stringify(body, (_key, value) => (typeof value === 'bigint' ? value.toString() : value)),\n};\n\nexport const urlSearchParamsBodySerializer = {\n bodySerializer: (body: unknown): string => {\n const data = new URLSearchParams();\n\n Object.entries(body as Record<string, unknown>).forEach(([key, value]) => {\n if (value === undefined || value === null) {\n return;\n }\n if (Array.isArray(value)) {\n value.forEach((v) => serializeUrlSearchParamsPair(data, key, v));\n } else {\n serializeUrlSearchParamsPair(data, key, value);\n }\n });\n\n return data.toString();\n },\n};\n","// This file is auto-generated by @hey-api/openapi-ts\n\ntype Slot = 'body' | 'headers' | 'path' | 'query';\n\nexport type Field =\n | {\n in: Exclude<Slot, 'body'>;\n /**\n * Field name. This is the name we want the user to see and use.\n */\n key: string;\n /**\n * Field mapped name. This is the name we want to use in the request.\n * If omitted, we use the same value as `key`.\n */\n map?: string;\n }\n | {\n in: Extract<Slot, 'body'>;\n /**\n * Key isn't required for bodies.\n */\n key?: string;\n map?: string;\n }\n | {\n /**\n * Field name. This is the name we want the user to see and use.\n */\n key: string;\n /**\n * Field mapped name. This is the name we want to use in the request.\n * If `in` is omitted, `map` aliases `key` to the transport layer.\n */\n map: Slot;\n };\n\nexport interface Fields {\n allowExtra?: Partial<Record<Slot, boolean>>;\n args?: ReadonlyArray<Field>;\n}\n\nexport type FieldsConfig = ReadonlyArray<Field | Fields>;\n\nconst extraPrefixesMap: Record<string, Slot> = {\n $body_: 'body',\n $headers_: 'headers',\n $path_: 'path',\n $query_: 'query',\n};\nconst extraPrefixes = Object.entries(extraPrefixesMap);\n\ntype KeyMap = Map<\n string,\n | {\n in: Slot;\n map?: string;\n }\n | {\n in?: never;\n map: Slot;\n }\n>;\n\nfunction buildKeyMap(fields: FieldsConfig, map?: KeyMap): KeyMap {\n if (!map) {\n map = new Map();\n }\n\n for (const config of fields) {\n if ('in' in config) {\n if (config.key) {\n map.set(config.key, {\n in: config.in,\n map: config.map,\n });\n }\n } else if ('key' in config) {\n map.set(config.key, {\n map: config.map,\n });\n } else if (config.args) {\n buildKeyMap(config.args, map);\n }\n }\n\n return map;\n}\n\ninterface Params {\n body?: unknown;\n headers: Record<string, unknown>;\n path: Record<string, unknown>;\n query: Record<string, unknown>;\n}\n\nfunction stripEmptySlots(params: Params): void {\n for (const [slot, value] of Object.entries(params)) {\n if (slot === 'body') continue;\n if (value && typeof value === 'object' && !Array.isArray(value) && !Object.keys(value).length) {\n delete params[slot as Slot];\n }\n }\n}\n\nexport function buildClientParams(args: ReadonlyArray<unknown>, fields: FieldsConfig): Params {\n const params: Params = {\n headers: Object.create(null),\n path: Object.create(null),\n query: Object.create(null),\n };\n\n const map = buildKeyMap(fields);\n\n function writeSlot(slot: Slot, key: string, value: unknown): void {\n let record = params[slot] as Record<string, unknown> | undefined;\n if (record === undefined) {\n record = Object.create(null) as Record<string, unknown>;\n params[slot] = record;\n }\n record[key] = value;\n }\n\n let config: FieldsConfig[number] | undefined;\n\n for (const [index, arg] of args.entries()) {\n if (fields[index]) {\n config = fields[index];\n }\n\n if (!config) {\n continue;\n }\n\n if ('in' in config) {\n if (config.key) {\n const field = map.get(config.key)!;\n const name = field.map || config.key;\n if (field.in) {\n writeSlot(field.in, name, arg);\n }\n } else {\n params.body = arg;\n }\n } else {\n for (const [key, value] of Object.entries(arg ?? {})) {\n const field = map.get(key);\n\n if (field) {\n if (field.in) {\n const name = field.map || key;\n writeSlot(field.in, name, value);\n } else {\n params[field.map] = value;\n }\n } else {\n const extra = extraPrefixes.find(([prefix]) => key.startsWith(prefix));\n\n if (extra) {\n const [prefix, slot] = extra;\n writeSlot(slot, key.slice(prefix.length), value);\n } else if ('allowExtra' in config && config.allowExtra) {\n for (const [slot, allowed] of Object.entries(config.allowExtra)) {\n if (allowed) {\n writeSlot(slot as Slot, key, value);\n break;\n }\n }\n }\n }\n }\n }\n }\n\n stripEmptySlots(params);\n\n return params;\n}\n","// This file is auto-generated by @hey-api/openapi-ts\n\nimport type { Config } from './types.gen';\n\nexport type ServerSentEventsOptions<TData = unknown> = Omit<RequestInit, 'method'> &\n Pick<Config, 'method' | 'responseTransformer' | 'responseValidator'> & {\n /**\n * Fetch API implementation. You can use this option to provide a custom\n * fetch instance.\n *\n * @default globalThis.fetch\n */\n fetch?: typeof fetch;\n /**\n * Implementing clients can call request interceptors inside this hook.\n */\n onRequest?: (url: string, init: RequestInit) => Promise<Request>;\n /**\n * Callback invoked when a network or parsing error occurs during streaming.\n *\n * This option applies only if the endpoint returns a stream of events.\n *\n * @param error The error that occurred.\n */\n onSseError?: (error: unknown) => void;\n /**\n * Callback invoked when an event is streamed from the server.\n *\n * This option applies only if the endpoint returns a stream of events.\n *\n * @param event Event streamed from the server.\n * @returns Nothing (void).\n */\n onSseEvent?: (event: StreamEvent<TData>) => void;\n serializedBody?: RequestInit['body'];\n /**\n * Default retry delay in milliseconds.\n *\n * This option applies only if the endpoint returns a stream of events.\n *\n * @default 3000\n */\n sseDefaultRetryDelay?: number;\n /**\n * Maximum number of retry attempts before giving up.\n */\n sseMaxRetryAttempts?: number;\n /**\n * Maximum retry delay in milliseconds.\n *\n * Applies only when exponential backoff is used.\n *\n * This option applies only if the endpoint returns a stream of events.\n *\n * @default 30000\n */\n sseMaxRetryDelay?: number;\n /**\n * Optional sleep function for retry backoff.\n *\n * Defaults to using `setTimeout`.\n */\n sseSleepFn?: (ms: number) => Promise<void>;\n url: string;\n };\n\nexport interface StreamEvent<TData = unknown> {\n data: TData;\n event?: string;\n id?: string;\n retry?: number;\n}\n\nexport type ServerSentEventsResult<TData = unknown, TReturn = void, TNext = unknown> = {\n stream: AsyncGenerator<\n TData extends Record<string, unknown> ? TData[keyof TData] : TData,\n TReturn,\n TNext\n >;\n};\n\nexport function createSseClient<TData = unknown>({\n onRequest,\n onSseError,\n onSseEvent,\n responseTransformer,\n responseValidator,\n sseDefaultRetryDelay,\n sseMaxRetryAttempts,\n sseMaxRetryDelay,\n sseSleepFn,\n url,\n ...options\n}: ServerSentEventsOptions): ServerSentEventsResult<TData> {\n let lastEventId: string | undefined;\n\n const sleep = sseSleepFn ?? ((ms: number) => new Promise((resolve) => setTimeout(resolve, ms)));\n\n const createStream = async function* () {\n let retryDelay: number = sseDefaultRetryDelay ?? 3000;\n let attempt = 0;\n const signal = options.signal ?? new AbortController().signal;\n\n while (true) {\n if (signal.aborted) break;\n\n attempt++;\n\n const headers =\n options.headers instanceof Headers\n ? options.headers\n : new Headers(options.headers as Record<string, string> | undefined);\n\n if (lastEventId !== undefined) {\n headers.set('Last-Event-ID', lastEventId);\n }\n\n try {\n const requestInit: RequestInit = {\n redirect: 'follow',\n ...options,\n body: options.serializedBody,\n headers,\n signal,\n };\n let request = new Request(url, requestInit);\n if (onRequest) {\n request = await onRequest(url, requestInit);\n }\n // fetch must be assigned here, otherwise it would throw the error:\n // TypeError: Failed to execute 'fetch' on 'Window': Illegal invocation\n const _fetch = options.fetch ?? globalThis.fetch;\n const response = await _fetch(request);\n\n if (!response.ok) throw new Error(`SSE failed: ${response.status} ${response.statusText}`);\n\n if (!response.body) throw new Error('No body in SSE response');\n\n const reader = response.body.pipeThrough(new TextDecoderStream()).getReader();\n\n let buffer = '';\n\n const abortHandler = () => {\n try {\n reader.cancel();\n } catch {\n // noop\n }\n };\n\n signal.addEventListener('abort', abortHandler);\n\n try {\n while (true) {\n const { done, value } = await reader.read();\n if (done) break;\n buffer += value;\n buffer = buffer.replace(/\\r\\n?/g, '\\n'); // normalize line endings\n\n const chunks = buffer.split('\\n\\n');\n buffer = chunks.pop() ?? '';\n\n for (const chunk of chunks) {\n const lines = chunk.split('\\n');\n const dataLines: Array<string> = [];\n let eventName: string | undefined;\n\n for (const line of lines) {\n if (line.startsWith('data:')) {\n dataLines.push(line.replace(/^data:\\s*/, ''));\n } else if (line.startsWith('event:')) {\n eventName = line.replace(/^event:\\s*/, '');\n } else if (line.startsWith('id:')) {\n lastEventId = line.replace(/^id:\\s*/, '');\n } else if (line.startsWith('retry:')) {\n const parsed = Number.parseInt(line.replace(/^retry:\\s*/, ''), 10);\n if (!Number.isNaN(parsed)) {\n retryDelay = parsed;\n }\n }\n }\n\n let data: unknown;\n let parsedJson = false;\n\n if (dataLines.length) {\n const rawData = dataLines.join('\\n');\n try {\n data = JSON.parse(rawData);\n parsedJson = true;\n } catch {\n data = rawData;\n }\n }\n\n if (parsedJson) {\n if (responseValidator) {\n await responseValidator(data);\n }\n\n if (responseTransformer) {\n data = await responseTransformer(data);\n }\n }\n\n onSseEvent?.({\n data,\n event: eventName,\n id: lastEventId,\n retry: retryDelay,\n });\n\n if (dataLines.length) {\n yield data as any;\n }\n }\n }\n } finally {\n signal.removeEventListener('abort', abortHandler);\n reader.releaseLock();\n }\n\n break; // exit loop on normal completion\n } catch (error) {\n // connection failed or aborted; retry after delay\n onSseError?.(error);\n\n if (sseMaxRetryAttempts !== undefined && attempt >= sseMaxRetryAttempts) {\n break; // stop after firing error\n }\n\n // exponential backoff: double retry each attempt, cap at 30s\n const backoff = Math.min(retryDelay * 2 ** (attempt - 1), sseMaxRetryDelay ?? 30000);\n await sleep(backoff);\n }\n }\n };\n\n const stream = createStream();\n\n return { stream };\n}\n","// This file is auto-generated by @hey-api/openapi-ts\n\ninterface SerializeOptions<T> extends SerializePrimitiveOptions, SerializerOptions<T> {}\n\ninterface SerializePrimitiveOptions {\n allowReserved?: boolean;\n name: string;\n}\n\nexport interface SerializerOptions<T> {\n /**\n * @default true\n */\n explode: boolean;\n style: T;\n}\n\nexport type ArrayStyle = 'form' | 'spaceDelimited' | 'pipeDelimited';\nexport type ArraySeparatorStyle = ArrayStyle | MatrixStyle;\ntype MatrixStyle = 'label' | 'matrix' | 'simple';\nexport type ObjectStyle = 'form' | 'deepObject';\ntype ObjectSeparatorStyle = ObjectStyle | MatrixStyle;\n\ninterface SerializePrimitiveParam extends SerializePrimitiveOptions {\n value: string;\n}\n\nexport const separatorArrayExplode = (style: ArraySeparatorStyle): '.' | ';' | ',' | '&' => {\n switch (style) {\n case 'label':\n return '.';\n case 'matrix':\n return ';';\n case 'simple':\n return ',';\n default:\n return '&';\n }\n};\n\nexport const separatorArrayNoExplode = (style: ArraySeparatorStyle): ',' | '|' | '%20' => {\n switch (style) {\n case 'form':\n return ',';\n case 'pipeDelimited':\n return '|';\n case 'spaceDelimited':\n return '%20';\n default:\n return ',';\n }\n};\n\nexport const separatorObjectExplode = (style: ObjectSeparatorStyle): '.' | ';' | ',' | '&' => {\n switch (style) {\n case 'label':\n return '.';\n case 'matrix':\n return ';';\n case 'simple':\n return ',';\n default:\n return '&';\n }\n};\n\nexport const serializeArrayParam = ({\n allowReserved,\n explode,\n name,\n style,\n value,\n}: SerializeOptions<ArraySeparatorStyle> & {\n value: unknown[];\n}): string => {\n if (!explode) {\n const joinedValues = (\n allowReserved ? value : value.map((v) => encodeURIComponent(v as string))\n ).join(separatorArrayNoExplode(style));\n switch (style) {\n case 'label':\n return `.${joinedValues}`;\n case 'matrix':\n return `;${name}=${joinedValues}`;\n case 'simple':\n return joinedValues;\n default:\n return `${name}=${joinedValues}`;\n }\n }\n\n const separator = separatorArrayExplode(style);\n const joinedValues = value\n .map((v) => {\n if (style === 'label' || style === 'simple') {\n return allowReserved ? v : encodeURIComponent(v as string);\n }\n\n return serializePrimitiveParam({\n allowReserved,\n name,\n value: v as string,\n });\n })\n .join(separator);\n return style === 'label' || style === 'matrix' ? separator + joinedValues : joinedValues;\n};\n\nexport const serializePrimitiveParam = ({\n allowReserved,\n name,\n value,\n}: SerializePrimitiveParam): string => {\n if (value === undefined || value === null) {\n return '';\n }\n\n if (typeof value === 'object') {\n throw new Error(\n 'Deeply-nested arrays/objects aren’t supported. Provide your own `querySerializer()` to handle these.',\n );\n }\n\n return `${name}=${allowReserved ? value : encodeURIComponent(value)}`;\n};\n\nexport const serializeObjectParam = ({\n allowReserved,\n explode,\n name,\n style,\n value,\n valueOnly,\n}: SerializeOptions<ObjectSeparatorStyle> & {\n value: Record<string, unknown> | Date;\n valueOnly?: boolean;\n}): string => {\n if (value instanceof Date) {\n return valueOnly ? value.toISOString() : `${name}=${value.toISOString()}`;\n }\n\n if (style !== 'deepObject' && !explode) {\n let values: string[] = [];\n Object.entries(value).forEach(([key, v]) => {\n values = [...values, key, allowReserved ? (v as string) : encodeURIComponent(v as string)];\n });\n const joinedValues = values.join(',');\n switch (style) {\n case 'form':\n return `${name}=${joinedValues}`;\n case 'label':\n return `.${joinedValues}`;\n case 'matrix':\n return `;${name}=${joinedValues}`;\n default:\n return joinedValues;\n }\n }\n\n const separator = separatorObjectExplode(style);\n const joinedValues = Object.entries(value)\n .map(([key, v]) =>\n serializePrimitiveParam({\n allowReserved,\n name: style === 'deepObject' ? `${name}[${key}]` : key,\n value: v as string,\n }),\n )\n .join(separator);\n return style === 'label' || style === 'matrix' ? separator + joinedValues : joinedValues;\n};\n","// This file is auto-generated by @hey-api/openapi-ts\n\nimport type { BodySerializer, QuerySerializer } from './bodySerializer.gen';\nimport {\n type ArraySeparatorStyle,\n serializeArrayParam,\n serializeObjectParam,\n serializePrimitiveParam,\n} from './pathSerializer.gen';\n\nexport interface PathSerializer {\n path: Record<string, unknown>;\n url: string;\n}\n\nexport const PATH_PARAM_RE: RegExp = /\\{[^{}]+\\}/g;\n\nexport const defaultPathSerializer = ({ path, url: _url }: PathSerializer): string => {\n let url = _url;\n const matches = _url.match(PATH_PARAM_RE);\n if (matches) {\n for (const match of matches) {\n let explode = false;\n let name = match.substring(1, match.length - 1);\n let style: ArraySeparatorStyle = 'simple';\n\n if (name.endsWith('*')) {\n explode = true;\n name = name.substring(0, name.length - 1);\n }\n\n if (name.startsWith('.')) {\n name = name.substring(1);\n style = 'label';\n } else if (name.startsWith(';')) {\n name = name.substring(1);\n style = 'matrix';\n }\n\n const value = path[name];\n\n if (value === undefined || value === null) {\n continue;\n }\n\n if (Array.isArray(value)) {\n url = url.replace(match, serializeArrayParam({ explode, name, style, value }));\n continue;\n }\n\n if (typeof value === 'object') {\n url = url.replace(\n match,\n serializeObjectParam({\n explode,\n name,\n style,\n value: value as Record<string, unknown>,\n valueOnly: true,\n }),\n );\n continue;\n }\n\n if (style === 'matrix') {\n url = url.replace(\n match,\n `;${serializePrimitiveParam({\n name,\n value: value as string,\n })}`,\n );\n continue;\n }\n\n const replaceValue = encodeURIComponent(\n style === 'label' ? `.${value as string}` : (value as string),\n );\n url = url.replace(match, replaceValue);\n }\n }\n return url;\n};\n\nexport const getUrl = ({\n baseUrl,\n path,\n query,\n querySerializer,\n url: _url,\n}: {\n baseUrl?: string;\n path?: Record<string, unknown>;\n query?: Record<string, unknown>;\n querySerializer: QuerySerializer;\n url: string;\n}): string => {\n const pathUrl = _url.startsWith('/') ? _url : `/${_url}`;\n let url = (baseUrl ?? '') + pathUrl;\n if (path) {\n url = defaultPathSerializer({ path, url });\n }\n let search = query ? querySerializer(query) : '';\n if (search.startsWith('?')) {\n search = search.substring(1);\n }\n if (search) {\n url += `?${search}`;\n }\n return url;\n};\n\nexport function getValidRequestBody(options: {\n body?: unknown;\n bodySerializer?: BodySerializer | null;\n serializedBody?: unknown;\n}): unknown {\n const hasBody = options.body !== undefined;\n const isSerializedBody = hasBody && options.bodySerializer;\n\n if (isSerializedBody) {\n if ('serializedBody' in options) {\n const hasSerializedBody =\n options.serializedBody !== undefined && options.serializedBody !== '';\n\n return hasSerializedBody ? options.serializedBody : null;\n }\n\n // not all clients implement a serializedBody property (i.e., client-axios)\n return options.body !== '' ? options.body : null;\n }\n\n // plain/text body\n if (hasBody) {\n return options.body;\n }\n\n // no body was provided\n return undefined;\n}\n","// This file is auto-generated by @hey-api/openapi-ts\n\nexport type AuthToken = string | undefined;\n\nexport interface Auth {\n /**\n * Which part of the request do we use to send the auth?\n *\n * @default 'header'\n */\n in?: 'header' | 'query' | 'cookie';\n /**\n * A unique identifier for the security scheme.\n *\n * Defined only when there are multiple security schemes whose `Auth`\n * shape would otherwise be identical.\n */\n key?: string;\n /**\n * Header or query parameter name.\n *\n * @default 'Authorization'\n */\n name?: string;\n scheme?: 'basic' | 'bearer';\n type: 'apiKey' | 'http';\n}\n\nexport const getAuthToken = async (\n auth: Auth,\n callback: ((auth: Auth) => Promise<AuthToken> | AuthToken) | AuthToken,\n): Promise<string | undefined> => {\n const token = typeof callback === 'function' ? await callback(auth) : callback;\n\n if (!token) {\n return;\n }\n\n if (auth.scheme === 'bearer') {\n return `Bearer ${token}`;\n }\n\n if (auth.scheme === 'basic') {\n return `Basic ${btoa(token)}`;\n }\n\n return token;\n};\n","// This file is auto-generated by @hey-api/openapi-ts\n\nimport { getAuthToken } from '../core/auth.gen';\nimport type { QuerySerializerOptions } from '../core/bodySerializer.gen';\nimport { jsonBodySerializer } from '../core/bodySerializer.gen';\nimport {\n serializeArrayParam,\n serializeObjectParam,\n serializePrimitiveParam,\n} from '../core/pathSerializer.gen';\nimport { getUrl } from '../core/utils.gen';\nimport type { Client, ClientOptions, Config, RequestOptions } from './types.gen';\n\nexport const createQuerySerializer = <T = unknown>({\n parameters = {},\n ...args\n}: QuerySerializerOptions = {}): ((queryParams: T) => string) => {\n const querySerializer = (queryParams: T): string => {\n const search: string[] = [];\n if (queryParams && typeof queryParams === 'object') {\n for (const name in queryParams) {\n const value = queryParams[name];\n\n if (value === undefined || value === null) {\n continue;\n }\n\n const options = parameters[name] || args;\n\n if (Array.isArray(value)) {\n const serializedArray = serializeArrayParam({\n allowReserved: options.allowReserved,\n explode: true,\n name,\n style: 'form',\n value,\n ...options.array,\n });\n if (serializedArray) search.push(serializedArray);\n } else if (typeof value === 'object') {\n const serializedObject = serializeObjectParam({\n allowReserved: options.allowReserved,\n explode: true,\n name,\n style: 'deepObject',\n value: value as Record<string, unknown>,\n ...options.object,\n });\n if (serializedObject) search.push(serializedObject);\n } else {\n const serializedPrimitive = serializePrimitiveParam({\n allowReserved: options.allowReserved,\n name,\n value: value as string,\n });\n if (serializedPrimitive) search.push(serializedPrimitive);\n }\n }\n }\n return search.join('&');\n };\n return querySerializer;\n};\n\n/**\n * Infers parseAs value from provided Content-Type header.\n */\nexport const getParseAs = (contentType: string | null): Exclude<Config['parseAs'], 'auto'> => {\n if (!contentType) {\n // If no Content-Type header is provided, the best we can do is return the raw response body,\n // which is effectively the same as the 'stream' option.\n return 'stream';\n }\n\n const cleanContent = contentType.split(';')[0]?.trim();\n\n if (!cleanContent) {\n return;\n }\n\n if (cleanContent.startsWith('application/json') || cleanContent.endsWith('+json')) {\n return 'json';\n }\n\n if (cleanContent === 'multipart/form-data') {\n return 'formData';\n }\n\n if (\n ['application/', 'audio/', 'image/', 'video/'].some((type) => cleanContent.startsWith(type))\n ) {\n return 'blob';\n }\n\n if (cleanContent.startsWith('text/')) {\n return 'text';\n }\n\n return;\n};\n\nconst checkForExistence = (\n options: Pick<RequestOptions, 'auth' | 'query'> & {\n headers: Headers;\n },\n name?: string,\n): boolean => {\n if (!name) {\n return false;\n }\n if (\n options.headers.has(name) ||\n options.query?.[name] ||\n options.headers.get('Cookie')?.includes(`${name}=`)\n ) {\n return true;\n }\n return false;\n};\n\nexport async function setAuthParams(\n options: Pick<RequestOptions, 'auth' | 'query' | 'security'> & {\n headers: Headers;\n },\n): Promise<void> {\n for (const auth of options.security ?? []) {\n if (checkForExistence(options, auth.name)) {\n continue;\n }\n\n const token = await getAuthToken(auth, options.auth);\n\n if (!token) {\n continue;\n }\n\n const name = auth.name ?? 'Authorization';\n\n switch (auth.in) {\n case 'query':\n if (!options.query) {\n options.query = {};\n }\n options.query[name] = token;\n break;\n case 'cookie':\n options.headers.append('Cookie', `${name}=${token}`);\n break;\n case 'header':\n default:\n options.headers.set(name, token);\n break;\n }\n }\n}\n\nexport const buildUrl: Client['buildUrl'] = (options) =>\n getUrl({\n baseUrl: options.baseUrl as string,\n path: options.path,\n query: options.query,\n querySerializer:\n typeof options.querySerializer === 'function'\n ? options.querySerializer\n : createQuerySerializer(options.querySerializer),\n url: options.url,\n });\n\nexport const mergeConfigs = (a: Config, b: Config): Config => {\n const config = { ...a, ...b };\n if (config.baseUrl?.endsWith('/')) {\n config.baseUrl = config.baseUrl.substring(0, config.baseUrl.length - 1);\n }\n config.headers = mergeHeaders(a.headers, b.headers);\n return config;\n};\n\nconst headersEntries = (headers: Headers): Array<[string, string]> => {\n const entries: Array<[string, string]> = [];\n headers.forEach((value, key) => {\n entries.push([key, value]);\n });\n return entries;\n};\n\nexport const mergeHeaders = (\n ...headers: Array<Required<Config>['headers'] | undefined>\n): Headers => {\n const mergedHeaders = new Headers();\n for (const header of headers) {\n if (!header) {\n continue;\n }\n\n const iterator = header instanceof Headers ? headersEntries(header) : Object.entries(header);\n\n for (const [key, value] of iterator) {\n if (value === null) {\n mergedHeaders.delete(key);\n } else if (Array.isArray(value)) {\n for (const v of value) {\n mergedHeaders.append(key, v as string);\n }\n } else if (value !== undefined) {\n // assume object headers are meant to be JSON stringified, i.e., their\n // content value in OpenAPI specification is 'application/json'\n mergedHeaders.set(\n key,\n typeof value === 'object' ? JSON.stringify(value) : (value as string),\n );\n }\n }\n }\n return mergedHeaders;\n};\n\ntype ErrInterceptor<Err, Res, Req, Options> = (\n error: Err,\n /** response may be undefined due to a network error where no response object is produced */\n response: Res | undefined,\n /** request may be undefined, because error may be from building the request object itself */\n request: Req | undefined,\n options: Options,\n) => Err | Promise<Err>;\n\ntype ReqInterceptor<Req, Options> = (request: Req, options: Options) => Req | Promise<Req>;\n\ntype ResInterceptor<Res, Req, Options> = (\n response: Res,\n request: Req,\n options: Options,\n) => Res | Promise<Res>;\n\nclass Interceptors<Interceptor> {\n fns: Array<Interceptor | null> = [];\n\n clear(): void {\n this.fns = [];\n }\n\n eject(id: number | Interceptor): void {\n const index = this.getInterceptorIndex(id);\n if (this.fns[index]) {\n this.fns[index] = null;\n }\n }\n\n exists(id: number | Interceptor): boolean {\n const index = this.getInterceptorIndex(id);\n return Boolean(this.fns[index]);\n }\n\n getInterceptorIndex(id: number | Interceptor): number {\n if (typeof id === 'number') {\n return this.fns[id] ? id : -1;\n }\n return this.fns.indexOf(id);\n }\n\n update(id: number | Interceptor, fn: Interceptor): number | Interceptor | false {\n const index = this.getInterceptorIndex(id);\n if (this.fns[index]) {\n this.fns[index] = fn;\n return id;\n }\n return false;\n }\n\n use(fn: Interceptor): number {\n this.fns.push(fn);\n return this.fns.length - 1;\n }\n}\n\nexport interface Middleware<Req, Res, Err, Options> {\n error: Interceptors<ErrInterceptor<Err, Res, Req, Options>>;\n request: Interceptors<ReqInterceptor<Req, Options>>;\n response: Interceptors<ResInterceptor<Res, Req, Options>>;\n}\n\nexport const createInterceptors = <Req, Res, Err, Options>(): Middleware<\n Req,\n Res,\n Err,\n Options\n> => ({\n error: new Interceptors<ErrInterceptor<Err, Res, Req, Options>>(),\n request: new Interceptors<ReqInterceptor<Req, Options>>(),\n response: new Interceptors<ResInterceptor<Res, Req, Options>>(),\n});\n\nconst defaultQuerySerializer = createQuerySerializer({\n allowReserved: false,\n array: {\n explode: true,\n style: 'form',\n },\n object: {\n explode: true,\n style: 'deepObject',\n },\n});\n\nconst defaultHeaders = {\n 'Content-Type': 'application/json',\n};\n\nexport const createConfig = <T extends ClientOptions = ClientOptions>(\n override: Config<Omit<ClientOptions, keyof T> & T> = {},\n): Config<Omit<ClientOptions, keyof T> & T> => ({\n ...jsonBodySerializer,\n headers: defaultHeaders,\n parseAs: 'auto',\n querySerializer: defaultQuerySerializer,\n ...override,\n});\n","// This file is auto-generated by @hey-api/openapi-ts\n\nimport { createSseClient } from '../core/serverSentEvents.gen';\nimport type { HttpMethod } from '../core/types.gen';\nimport { getValidRequestBody } from '../core/utils.gen';\nimport type { Client, Config, RequestOptions, ResolvedRequestOptions } from './types.gen';\nimport {\n buildUrl,\n createConfig,\n createInterceptors,\n getParseAs,\n mergeConfigs,\n mergeHeaders,\n setAuthParams,\n} from './utils.gen';\n\ntype ReqInit = Omit<RequestInit, 'body' | 'headers'> & {\n body?: any;\n headers: ReturnType<typeof mergeHeaders>;\n};\n\nexport const createClient = (config: Config = {}): Client => {\n let _config = mergeConfigs(createConfig(), config);\n\n const getConfig = (): Config => ({ ..._config });\n\n const setConfig = (config: Config): Config => {\n _config = mergeConfigs(_config, config);\n return getConfig();\n };\n\n const interceptors = createInterceptors<Request, Response, unknown, ResolvedRequestOptions>();\n\n const beforeRequest = async <\n TData = unknown,\n TResponseStyle extends 'data' | 'fields' = 'fields',\n ThrowOnError extends boolean = boolean,\n Url extends string = string,\n >(\n options: RequestOptions<TData, TResponseStyle, ThrowOnError, Url>,\n ) => {\n const opts = {\n ..._config,\n ...options,\n fetch: options.fetch ?? _config.fetch ?? globalThis.fetch,\n headers: mergeHeaders(_config.headers, options.headers),\n serializedBody: undefined as string | undefined,\n };\n\n if (opts.security) {\n await setAuthParams(opts);\n }\n\n if (opts.requestValidator) {\n await opts.requestValidator(opts);\n }\n\n if (opts.body !== undefined && opts.bodySerializer) {\n opts.serializedBody = opts.bodySerializer(opts.body) as string | undefined;\n }\n\n // remove Content-Type header if body is empty to avoid sending invalid requests\n if (opts.body === undefined || opts.serializedBody === '') {\n opts.headers.delete('Content-Type');\n }\n\n const resolvedOpts = opts as typeof opts &\n ResolvedRequestOptions<TResponseStyle, ThrowOnError, Url>;\n const url = buildUrl(resolvedOpts);\n\n return { opts: resolvedOpts, url };\n };\n\n const request: Client['request'] = async (options) => {\n const throwOnError = options.throwOnError ?? _config.throwOnError;\n const responseStyle = options.responseStyle ?? _config.responseStyle;\n\n let request: Request | undefined;\n let response: Response | undefined;\n\n try {\n const { opts, url } = await beforeRequest(options);\n const requestInit: ReqInit = {\n redirect: 'follow',\n ...opts,\n body: getValidRequestBody(opts),\n };\n\n request = new Request(url, requestInit);\n\n for (const fn of interceptors.request.fns) {\n if (fn) {\n request = await fn(request, opts);\n }\n }\n\n // fetch must be assigned here, otherwise it would throw the error:\n // TypeError: Failed to execute 'fetch' on 'Window': Illegal invocation\n const _fetch = opts.fetch!;\n\n response = await _fetch(request);\n\n for (const fn of interceptors.response.fns) {\n if (fn) {\n response = await fn(response, request, opts);\n }\n }\n\n const result = {\n request,\n response,\n };\n\n if (response.ok) {\n const parseAs =\n (opts.parseAs === 'auto'\n ? getParseAs(response.headers.get('Content-Type'))\n : opts.parseAs) ?? 'json';\n\n if (response.status === 204 || response.headers.get('Content-Length') === '0') {\n let emptyData: any;\n switch (parseAs) {\n case 'arrayBuffer':\n case 'blob':\n case 'text':\n emptyData = await response[parseAs]();\n break;\n case 'formData':\n emptyData = new FormData();\n break;\n case 'stream':\n emptyData = response.body;\n break;\n case 'json':\n default:\n emptyData = {};\n break;\n }\n return opts.responseStyle === 'data'\n ? emptyData\n : {\n data: emptyData,\n ...result,\n };\n }\n\n let data: any;\n switch (parseAs) {\n case 'arrayBuffer':\n case 'blob':\n case 'formData':\n case 'text':\n data = await response[parseAs]();\n break;\n case 'json': {\n // Some servers return 200 with no Content-Length and empty body.\n // response.json() would throw; read as text and parse if non-empty.\n const text = await response.text();\n data = text ? JSON.parse(text) : {};\n break;\n }\n case 'stream':\n return opts.responseStyle === 'data'\n ? response.body\n : {\n data: response.body,\n ...result,\n };\n }\n\n if (parseAs === 'json') {\n if (opts.responseValidator) {\n await opts.responseValidator(data);\n }\n\n if (opts.responseTransformer) {\n data = await opts.responseTransformer(data);\n }\n }\n\n return opts.responseStyle === 'data'\n ? data\n : {\n data,\n ...result,\n };\n }\n\n const textError = await response.text();\n let jsonError: unknown;\n\n try {\n jsonError = JSON.parse(textError);\n } catch {\n // noop\n }\n\n throw jsonError ?? textError;\n } catch (error) {\n let finalError = error;\n\n for (const fn of interceptors.error.fns) {\n if (fn) {\n finalError = await fn(finalError, response, request, options as ResolvedRequestOptions);\n }\n }\n\n finalError = finalError || {};\n\n if (throwOnError) {\n throw finalError;\n }\n\n // TODO: we probably want to return error and improve types\n return responseStyle === 'data'\n ? undefined\n : {\n error: finalError,\n request,\n response,\n };\n }\n };\n\n const makeMethodFn = (method: Uppercase<HttpMethod>) => (options: RequestOptions) =>\n request({ ...options, method });\n\n const makeSseFn = (method: Uppercase<HttpMethod>) => async (options: RequestOptions) => {\n const { opts, url } = await beforeRequest(options);\n return createSseClient({\n ...opts,\n body: opts.body as BodyInit | null | undefined,\n method,\n onRequest: async (url, init) => {\n let request = new Request(url, init);\n for (const fn of interceptors.request.fns) {\n if (fn) {\n request = await fn(request, opts);\n }\n }\n return request;\n },\n serializedBody: getValidRequestBody(opts) as BodyInit | null | undefined,\n url,\n });\n };\n\n const _buildUrl: Client['buildUrl'] = (options) => buildUrl({ ..._config, ...options });\n\n return {\n buildUrl: _buildUrl,\n connect: makeMethodFn('CONNECT'),\n delete: makeMethodFn('DELETE'),\n get: makeMethodFn('GET'),\n getConfig,\n head: makeMethodFn('HEAD'),\n interceptors,\n options: makeMethodFn('OPTIONS'),\n patch: makeMethodFn('PATCH'),\n post: makeMethodFn('POST'),\n put: makeMethodFn('PUT'),\n request,\n setConfig,\n sse: {\n connect: makeSseFn('CONNECT'),\n delete: makeSseFn('DELETE'),\n get: makeSseFn('GET'),\n head: makeSseFn('HEAD'),\n options: makeSseFn('OPTIONS'),\n patch: makeSseFn('PATCH'),\n post: makeSseFn('POST'),\n put: makeSseFn('PUT'),\n trace: makeSseFn('TRACE'),\n },\n trace: makeMethodFn('TRACE'),\n } as Client;\n};\n","// This file is auto-generated by @hey-api/openapi-ts\n\nimport { type Client, type ClientOptions, type Config, createClient, createConfig } from './client';\nimport type { ClientOptions as ClientOptions2 } from './types.gen';\n\n/**\n * The `createClientConfig()` function will be called on client initialization\n * and the returned object will become the client's initial configuration.\n *\n * You may want to initialize your client this way instead of calling\n * `setConfig()`. This is useful for example if you're using Next.js\n * to ensure your client always has the correct values.\n */\nexport type CreateClientConfig<T extends ClientOptions = ClientOptions2> = (override?: Config<ClientOptions & T>) => Config<Required<ClientOptions> & T>;\n\nexport const client: Client = createClient(createConfig<ClientOptions2>({ baseUrl: 'https://shipeasy.ai' }));\n","// This file is auto-generated by @hey-api/openapi-ts\n\nimport type { Client, ClientMeta, Options as Options2, RequestResult, TDataShape } from './client';\nimport { client } from './client.gen';\nimport type { AckOpsItemData, AckOpsItemErrors, AckOpsItemResponses, AddToGateWhitelistData, AddToGateWhitelistErrors, AddToGateWhitelistResponses, AnswerOpsQuestionData, AnswerOpsQuestionErrors, AnswerOpsQuestionResponses, ApproveEventData, ApproveEventErrors, ApproveEventResponses, AskOpsQuestionsData, AskOpsQuestionsErrors, AskOpsQuestionsResponses, CancelOpsQuestionData, CancelOpsQuestionErrors, CancelOpsQuestionResponses, CreateAlertRuleData, CreateAlertRuleErrors, CreateAlertRuleResponses, CreateAttributeData, CreateAttributeErrors, CreateAttributeResponses, CreateConfigData, CreateConfigErrors, CreateConfigResponses, CreateConnectorData, CreateConnectorErrors, CreateConnectorResponses, CreateEventData, CreateEventErrors, CreateEventResponses, CreateExperimentData, CreateExperimentErrors, CreateExperimentReadoutData, CreateExperimentReadoutErrors, CreateExperimentReadoutResponses, CreateExperimentResponses, CreateGateData, CreateGateErrors, CreateGateResponses, CreateGateTemplateData, CreateGateTemplateErrors, CreateGateTemplateResponses, CreateI18nDraftData, CreateI18nDraftErrors, CreateI18nDraftResponses, CreateI18nProfileData, CreateI18nProfileErrors, CreateI18nProfileResponses, CreateKeyData, CreateKeyErrors, CreateKeyResponses, CreateKillswitchData, CreateKillswitchErrors, CreateKillswitchResponses, CreateMetricData, CreateMetricErrors, CreateMetricResponses, CreateOpsCommentData, CreateOpsCommentErrors, CreateOpsCommentResponses, CreateOpsInvestigationData, CreateOpsInvestigationErrors, CreateOpsInvestigationResponses, CreateOpsItemData, CreateOpsItemErrors, CreateOpsItemResponses, CreateOpsQaNoteData, CreateOpsQaNoteErrors, CreateOpsQaNoteResponses, CreatePublicBugData, CreatePublicBugErrors, CreatePublicBugResponses, CreatePublicFeatureRequestData, CreatePublicFeatureRequestErrors, CreatePublicFeatureRequestResponses, CreateTriggerConnectorData, CreateTriggerConnectorErrors, CreateTriggerConnectorResponses, CreateUniverseData, CreateUniverseErrors, CreateUniverseResponses, DeleteAlertRuleData, DeleteAlertRuleErrors, DeleteAlertRuleResponses, DeleteAttributeData, DeleteAttributeErrors, DeleteAttributeResponses, DeleteConfigData, DeleteConfigErrors, DeleteConfigResponses, DeleteConnectorData, DeleteConnectorErrors, DeleteConnectorResponses, DeleteEventData, DeleteEventErrors, DeleteEventResponses, DeleteExperimentData, DeleteExperimentErrors, DeleteExperimentResponses, DeleteGateData, DeleteGateErrors, DeleteGateResponses, DeleteGateTemplateData, DeleteGateTemplateErrors, DeleteGateTemplateResponses, DeleteI18nDraftData, DeleteI18nDraftErrors, DeleteI18nDraftResponses, DeleteI18nKeyData, DeleteI18nKeyErrors, DeleteI18nKeyResponses, DeleteI18nProfileData, DeleteI18nProfileErrors, DeleteI18nProfileResponses, DeleteKillswitchData, DeleteKillswitchErrors, DeleteKillswitchResponses, DeleteMetricData, DeleteMetricErrors, DeleteMetricResponses, DeleteOpsItemData, DeleteOpsItemErrors, DeleteOpsItemResponses, DeleteUniverseData, DeleteUniverseErrors, DeleteUniverseResponses, DisableGateData, DisableGateErrors, DisableGateResponses, DiscardConfigDraftData, DiscardConfigDraftErrors, DiscardConfigDraftResponses, EnableGateData, EnableGateErrors, EnableGateResponses, FileErrorTicketData, FileErrorTicketErrors, FileErrorTicketResponses, FireConnectorData, FireConnectorErrors, FireConnectorResponses, GetAttributeData, GetAttributeErrors, GetAttributeResponses, GetConfigData, GetConfigErrors, GetConfigResponses, GetConnectorData, GetConnectorErrors, GetConnectorResponses, GetCurrentProjectData, GetCurrentProjectErrors, GetCurrentProjectResponses, GetEntityTagsData, GetEntityTagsErrors, GetEntityTagsResponses, GetErrorData, GetErrorErrors, GetErrorResponses, GetErrorSeriesData, GetErrorSeriesErrors, GetErrorSeriesResponses, GetEventData, GetEventErrors, GetEventResponses, GetExperimentData, GetExperimentErrors, GetExperimentReadoutData, GetExperimentReadoutErrors, GetExperimentReadoutResponses, GetExperimentResponses, GetExperimentResultsData, GetExperimentResultsErrors, GetExperimentResultsResponses, GetExperimentTimeseriesData, GetExperimentTimeseriesErrors, GetExperimentTimeseriesResponses, GetGateData, GetGateErrors, GetGateResponses, GetGateTemplateData, GetGateTemplateErrors, GetGateTemplateResponses, GetGateWhitelistData, GetGateWhitelistErrors, GetGateWhitelistResponses, GetKillswitchData, GetKillswitchErrors, GetKillswitchResponses, GetMetricData, GetMetricErrors, GetMetricResponses, GetMetricSeriesData, GetMetricSeriesErrors, GetMetricSeriesResponses, GetOpsItemData, GetOpsItemErrors, GetOpsItemResponses, GetProjectData, GetProjectErrors, GetProjectResponses, LinkPrToOpsItemData, LinkPrToOpsItemErrors, LinkPrToOpsItemResponses, ListAlertRulesData, ListAlertRulesErrors, ListAlertRulesResponses, ListAlertsData, ListAlertsErrors, ListAlertsResponses, ListAttributesData, ListAttributesErrors, ListAttributesResponses, ListConfigActivityData, ListConfigActivityErrors, ListConfigActivityResponses, ListConfigsData, ListConfigsErrors, ListConfigsResponses, ListConfigVersionsData, ListConfigVersionsErrors, ListConfigVersionsResponses, ListConnectorsData, ListConnectorsErrors, ListConnectorsResponses, ListErrorsData, ListErrorsErrors, ListErrorsResponses, ListEventsData, ListEventsErrors, ListEventsResponses, ListExperimentsData, ListExperimentsErrors, ListExperimentsResponses, ListGateActivityData, ListGateActivityErrors, ListGateActivityResponses, ListGatesData, ListGatesErrors, ListGatesResponses, ListGateTemplatesData, ListGateTemplatesErrors, ListGateTemplatesResponses, ListI18nDraftKeysData, ListI18nDraftKeysErrors, ListI18nDraftKeysResponses, ListI18nDraftsData, ListI18nDraftsErrors, ListI18nDraftsResponses, ListI18nKeysData, ListI18nKeysErrors, ListI18nKeysResponses, ListI18nProfilesData, ListI18nProfilesErrors, ListI18nProfilesResponses, ListKeysData, ListKeysErrors, ListKeysResponses, ListKillswitchesData, ListKillswitchesErrors, ListKillswitchesResponses, ListMetricExperimentsData, ListMetricExperimentsErrors, ListMetricExperimentsResponses, ListMetricsData, ListMetricsErrors, ListMetricsResponses, ListOpsAgentsData, ListOpsAgentsErrors, ListOpsAgentsResponses, ListOpsCommentsData, ListOpsCommentsErrors, ListOpsCommentsResponses, ListOpsInvestigationsData, ListOpsInvestigationsErrors, ListOpsInvestigationsResponses, ListOpsItemsData, ListOpsItemsErrors, ListOpsItemsResponses, ListOpsQaNotesData, ListOpsQaNotesErrors, ListOpsQaNotesResponses, ListOpsQuestionsData, ListOpsQuestionsErrors, ListOpsQuestionsResponses, ListSlackChannelsData, ListSlackChannelsErrors, ListSlackChannelsResponses, ListTagsData, ListTagsErrors, ListTagsResponses, ListUniversesData, ListUniversesErrors, ListUniversesResponses, NotifyOpsData, NotifyOpsErrors, NotifyOpsResponses, PublishConfigDraftData, PublishConfigDraftErrors, PublishConfigDraftResponses, PublishI18nProfileData, PublishI18nProfileErrors, PublishI18nProfileResponses, PushI18nKeysData, PushI18nKeysErrors, PushI18nKeysResponses, ReanalyzeExperimentData, ReanalyzeExperimentErrors, ReanalyzeExperimentResponses, RemoveFromGateWhitelistData, RemoveFromGateWhitelistErrors, RemoveFromGateWhitelistResponses, ResolveErrorData, ResolveErrorErrors, ResolveErrorResponses, RevokeKeyData, RevokeKeyErrors, RevokeKeyResponses, SaveConfigDraftData, SaveConfigDraftErrors, SaveConfigDraftResponses, SearchResourcesData, SearchResourcesErrors, SearchResourcesResponses, SetEntityTagsData, SetEntityTagsErrors, SetEntityTagsResponses, SetExperimentMetricsData, SetExperimentMetricsErrors, SetExperimentMetricsResponses, SetExperimentStatusData, SetExperimentStatusErrors, SetExperimentStatusResponses, SetGateWhitelistData, SetGateWhitelistErrors, SetGateWhitelistResponses, SetI18nLabelData, SetI18nLabelErrors, SetI18nLabelResponses, SetKillswitchSwitchData, SetKillswitchSwitchErrors, SetKillswitchSwitchResponses, SetKillswitchValueData, SetKillswitchValueErrors, SetKillswitchValueResponses, TestConnectorData, TestConnectorErrors, TestConnectorResponses, ToggleKillswitchData, ToggleKillswitchErrors, ToggleKillswitchResponses, UnarchiveMetricData, UnarchiveMetricErrors, UnarchiveMetricResponses, UnsetKillswitchSwitchData, UnsetKillswitchSwitchErrors, UnsetKillswitchSwitchResponses, UpdateAlertData, UpdateAlertErrors, UpdateAlertResponses, UpdateAlertRuleData, UpdateAlertRuleErrors, UpdateAlertRuleResponses, UpdateAttributeData, UpdateAttributeErrors, UpdateAttributeResponses, UpdateConfigData, UpdateConfigErrors, UpdateConfigResponses, UpdateConfigSchemaData, UpdateConfigSchemaErrors, UpdateConfigSchemaResponses, UpdateConnectorData, UpdateConnectorErrors, UpdateConnectorResponses, UpdateEntityTagsData, UpdateEntityTagsErrors, UpdateEntityTagsResponses, UpdateErrorStatusData, UpdateErrorStatusErrors, UpdateErrorStatusResponses, UpdateEventData, UpdateEventErrors, UpdateEventResponses, UpdateExperimentData, UpdateExperimentErrors, UpdateExperimentResponses, UpdateGateData, UpdateGateErrors, UpdateGateResponses, UpdateGateTemplateData, UpdateGateTemplateErrors, UpdateGateTemplateResponses, UpdateI18nDraftData, UpdateI18nDraftErrors, UpdateI18nDraftResponses, UpdateI18nKeyData, UpdateI18nKeyErrors, UpdateI18nKeyResponses, UpdateKeyData, UpdateKeyErrors, UpdateKeyResponses, UpdateKillswitchData, UpdateKillswitchErrors, UpdateKillswitchResponses, UpdateMetricData, UpdateMetricErrors, UpdateMetricResponses, UpdateOpsInvestigationData, UpdateOpsInvestigationErrors, UpdateOpsInvestigationResponses, UpdateOpsItemData, UpdateOpsItemErrors, UpdateOpsItemResponses, UpdateProjectData, UpdateProjectErrors, UpdateProjectResponses, UpdateTriggerConnectorData, UpdateTriggerConnectorErrors, UpdateTriggerConnectorResponses, UpdateUniverseData, UpdateUniverseErrors, UpdateUniverseResponses, UpsertI18nDraftKeyData, UpsertI18nDraftKeyErrors, UpsertI18nDraftKeyResponses, UpsertI18nKeysData, UpsertI18nKeysErrors, UpsertI18nKeysResponses, UpsertProjectData, UpsertProjectErrors, UpsertProjectResponses } from './types.gen';\n\nexport type Options<TData extends TDataShape = TDataShape, ThrowOnError extends boolean = boolean, TResponse = unknown> = Options2<TData, ThrowOnError, TResponse> & {\n /**\n * You can provide a client instance returned by `createClient()` instead of\n * individual options. This might be also useful if you want to implement a\n * custom client.\n */\n client?: Client;\n /**\n * You can pass arbitrary values through the `meta` object. This can be\n * used to access values that aren't defined as part of the SDK function.\n */\n meta?: keyof ClientMeta extends never ? Record<string, unknown> : ClientMeta;\n};\n\n/**\n * List feature gates\n *\n * Returns a single page of gates ordered by `updated_at desc, id desc`. Use the `cursor` query parameter to paginate.\n *\n * **Use case:** Snapshot every gate in the project — for example to render an admin overview or to drive a CI check that asserts no gate is left at 100% in staging.\n */\nexport const listGates = <ThrowOnError extends boolean = false>(options?: Options<ListGatesData, ThrowOnError>): RequestResult<ListGatesResponses, ListGatesErrors, ThrowOnError> => (options?.client ?? client).get<ListGatesResponses, ListGatesErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/gates',\n ...options\n});\n\n/**\n * Create a feature gate\n *\n * Creates a new gate. Default `enabled: true` at the supplied `rollout_pct` (`0` = fully dark).\n *\n * Only `name` is required. Request fields use snake_case (`owner_email`); the GET response returns camelCase (`ownerEmail`, `groupName`).\n *\n * Returns `409` if `name` already exists in the project (case-sensitive).\n *\n * **Use cases**\n *\n * - **Dark create + ramp later** — `{ \"name\": \"checkout_v2\" }` at 0% rollout. Ramp via PATCH after deploy validation.\n * - **Targeted rollout** — supply `rules` to gate the caller (e.g. only `plan = pro` users) plus a `rollout_pct` to bucket within that audience.\n * - **Gatekeeper stack** — supply `stack` instead of `rules`/`rollout_pct` for `internal ∪ beta ∪ public` fall-through. Stack entries evaluated top-to-bottom; first match wins.\n * - **Dashboard metadata** — populate `title`, `description`, `folder`, `group`, `owner_email` so the admin UI is self-documenting from day one.\n * - **Disabled on create** — pre-provision with `enabled: false` for a future launch; flip on with `POST /{id}/enable` at go-live.\n */\nexport const createGate = <ThrowOnError extends boolean = false>(options: Options<CreateGateData, ThrowOnError>): RequestResult<CreateGateResponses, CreateGateErrors, ThrowOnError> => (options.client ?? client).post<CreateGateResponses, CreateGateErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/gates',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * Delete a feature gate\n *\n * Soft-deletes the gate. Returns 409 if the gate is still referenced by a running experiment as a targeting gate — stop the experiment first.\n *\n * **Use case:** Tear down a gate after a feature has fully shipped and the rollout flag is no longer needed.\n */\nexport const deleteGate = <ThrowOnError extends boolean = false>(options: Options<DeleteGateData, ThrowOnError>): RequestResult<DeleteGateResponses, DeleteGateErrors, ThrowOnError> => (options.client ?? client).delete<DeleteGateResponses, DeleteGateErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/gates/{id}',\n ...options\n});\n\n/**\n * Get one gate\n *\n * Returns the full gate row — including the gatekeeper `stack`, resolved creator/last-editor emails, and the edit `version` — for one gate, addressed by id or `name`.\n *\n * **Use case:** Inspect a single gate's current rollout, rules, and stack before editing it, without paging through the whole list.\n */\nexport const getGate = <ThrowOnError extends boolean = false>(options: Options<GetGateData, ThrowOnError>): RequestResult<GetGateResponses, GetGateErrors, ThrowOnError> => (options.client ?? client).get<GetGateResponses, GetGateErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/gates/{id}',\n ...options\n});\n\n/**\n * Update a feature gate\n *\n * Partial update — only supplied fields change. Array fields (`rules`, `stack`) **replace** wholesale; there is no merge or append.\n *\n * `name` and the gate id are immutable. The response carries only `{ id }` — re-fetch via `GET /api/admin/gates` for the new row.\n *\n * **Use cases**\n *\n * - **Ramp rollout** — `{ \"rollout_pct\": 5000 }` for 50%. Basis points (0–10000); `100` = 1%.\n * - **Kill switch** — `{ \"enabled\": false }`. Forces evaluation to `false` for every caller regardless of rules/rollout. Re-enable with `POST /{id}/enable` or `{ \"enabled\": true }`.\n * - **Modify a rule's `in` set** — send the full new `rules` array. To add `'GB'` to `['US','CA']`: `{ \"rules\": [{ \"attr\": \"country\", \"op\": \"in\", \"value\": [\"US\",\"CA\",\"GB\"] }] }`. No per-rule patch endpoint.\n * - **Add targeting from scratch** — `{ \"rules\": [{ \"attr\": \"email\", \"op\": \"regex\", \"value\": \"@acme\\\\.com$\" }] }`.\n * - **Switch to gatekeeper stack** — send a non-null `stack`. To revert to flat eval, send `{ \"stack\": null }`.\n * - **Update metadata** — any subset of `title`, `description`, `folder`, `group`, `owner_email`.\n */\nexport const updateGate = <ThrowOnError extends boolean = false>(options: Options<UpdateGateData, ThrowOnError>): RequestResult<UpdateGateResponses, UpdateGateErrors, ThrowOnError> => (options.client ?? client).patch<UpdateGateResponses, UpdateGateErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/gates/{id}',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * Enable a gate\n *\n * Sets `enabled: true`. The current `rollout_pct` is preserved.\n *\n * **Use case:** Re-enable a previously disabled gate without re-issuing a full update.\n */\nexport const enableGate = <ThrowOnError extends boolean = false>(options: Options<EnableGateData, ThrowOnError>): RequestResult<EnableGateResponses, EnableGateErrors, ThrowOnError> => (options.client ?? client).post<EnableGateResponses, EnableGateErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/gates/{id}/enable',\n ...options\n});\n\n/**\n * Disable a gate\n *\n * Sets `enabled: false` so the gate evaluates to `false` for every caller, regardless of `rollout_pct` or `rules`. Use as a quick kill switch.\n *\n * **Use case:** Flip a gate off in production without redeploying — the canonical kill-switch flow.\n */\nexport const disableGate = <ThrowOnError extends boolean = false>(options: Options<DisableGateData, ThrowOnError>): RequestResult<DisableGateResponses, DisableGateErrors, ThrowOnError> => (options.client ?? client).post<DisableGateResponses, DisableGateErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/gates/{id}/disable',\n ...options\n});\n\n/**\n * List gate activity\n *\n * Returns recent audit rows for one gate (create, update, enable, disable, delete) ordered newest first. Use the `limit` query parameter to cap the result (1–100, default 20).\n *\n * **Use case:** Render the activity feed in the gate detail panel or answer \"who ramped this gate, and when?\" during an incident review.\n */\nexport const listGateActivity = <ThrowOnError extends boolean = false>(options: Options<ListGateActivityData, ThrowOnError>): RequestResult<ListGateActivityResponses, ListGateActivityErrors, ThrowOnError> => (options.client ?? client).get<ListGateActivityResponses, ListGateActivityErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/gates/{id}/activity',\n ...options\n});\n\n/**\n * Remove entries from a gate's whitelist\n *\n * Removes identities from the gate's whitelist. Entries that aren't on the list are skipped, so the call is idempotent.\n *\n * Removing the last entry leaves an empty whitelist block in place; to drop the block itself use `PUT` with `entries: []`.\n *\n * **Use case:** Revoke one beta tester's access without touching anyone else's.\n */\nexport const removeFromGateWhitelist = <ThrowOnError extends boolean = false>(options: Options<RemoveFromGateWhitelistData, ThrowOnError>): RequestResult<RemoveFromGateWhitelistResponses, RemoveFromGateWhitelistErrors, ThrowOnError> => (options.client ?? client).delete<RemoveFromGateWhitelistResponses, RemoveFromGateWhitelistErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/gates/{id}/whitelist',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * Read a gate's whitelist\n *\n * Returns the gate's whitelist — the always-first allowlist that admits the listed identities before any targeting rule or percentage rollout is evaluated.\n *\n * A gate with no whitelist returns `entries: []` (and the default `attr`), never a 404 — so a caller can read-then-write without special-casing the empty gate.\n *\n * **Use case:** Check whether an account is already let through before adding it.\n */\nexport const getGateWhitelist = <ThrowOnError extends boolean = false>(options: Options<GetGateWhitelistData, ThrowOnError>): RequestResult<GetGateWhitelistResponses, GetGateWhitelistErrors, ThrowOnError> => (options.client ?? client).get<GetGateWhitelistResponses, GetGateWhitelistErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/gates/{id}/whitelist',\n ...options\n});\n\n/**\n * Add entries to a gate's whitelist\n *\n * Adds identities to the gate's whitelist, creating the block if the gate doesn't have one yet. Entries already on the list are skipped, so the call is idempotent and safe to retry.\n *\n * Adding to a gate that already has a whitelist keyed on the other attribute is rejected (409) rather than silently re-keying the entries already there — use `PUT` to switch `attr` deliberately.\n *\n * **Use case:** Let one more customer into a private beta without reading the current list first.\n */\nexport const addToGateWhitelist = <ThrowOnError extends boolean = false>(options: Options<AddToGateWhitelistData, ThrowOnError>): RequestResult<AddToGateWhitelistResponses, AddToGateWhitelistErrors, ThrowOnError> => (options.client ?? client).post<AddToGateWhitelistResponses, AddToGateWhitelistErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/gates/{id}/whitelist',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * Replace a gate's whitelist\n *\n * Replaces the gate's whole whitelist with `entries`, creating the block if the gate didn't have one. Idempotent — the same call twice leaves the same list.\n *\n * This is the only whitelist call that can switch `attr` (`email` ⇄ `user_id`) or clear the block: `entries: []` removes the whitelist from the gate entirely.\n *\n * **Use cases**\n *\n * - **Pin an exact list** — `{ \"entries\": [\"alice@acme.dev\", \"bob@acme.dev\"] }`.\n * - **Switch to user ids** — `{ \"attr\": \"user_id\", \"entries\": [\"usr_123\"] }`.\n * - **Drop the whitelist** — `{ \"entries\": [] }`.\n */\nexport const setGateWhitelist = <ThrowOnError extends boolean = false>(options: Options<SetGateWhitelistData, ThrowOnError>): RequestResult<SetGateWhitelistResponses, SetGateWhitelistErrors, ThrowOnError> => (options.client ?? client).put<SetGateWhitelistResponses, SetGateWhitelistErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/gates/{id}/whitelist',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * List experiments\n *\n * Returns a single page of non-archived experiments ordered by `updated_at desc, id desc`. Use the `cursor` query parameter to paginate.\n *\n * **Use case:** Snapshot every active experiment in the project — e.g. render an overview dashboard or drive a CI check that no experiment has been running past its `min_runtime_days`.\n */\nexport const listExperiments = <ThrowOnError extends boolean = false>(options?: Options<ListExperimentsData, ThrowOnError>): RequestResult<ListExperimentsResponses, ListExperimentsErrors, ThrowOnError> => (options?.client ?? client).get<ListExperimentsResponses, ListExperimentsErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/experiments',\n ...options\n});\n\n/**\n * Create an experiment\n *\n * Creates a new experiment in `draft` status. `name`, `universe`, and `groups` are required; everything else has sensible defaults.\n *\n * Returns `409` if `name` already exists, `422` if the named universe doesn't exist, `403` if a plan-gated option is set (`sequential_testing`, custom `significance_threshold`) on a plan that doesn't include it.\n *\n * **Use cases**\n *\n * - **Minimal 50/50** — `name` + `universe` + two equal-weight groups.\n * - **Targeted rollout** — supply `targeting_gate` to restrict the eligible audience and `allocation_pct` to enrol a slice of it.\n * - **Multivariant** — three or more groups with weights summing to 10000.\n * - **Sequential testing** — `sequential_testing: true` for Premium plans.\n */\nexport const createExperiment = <ThrowOnError extends boolean = false>(options: Options<CreateExperimentData, ThrowOnError>): RequestResult<CreateExperimentResponses, CreateExperimentErrors, ThrowOnError> => (options.client ?? client).post<CreateExperimentResponses, CreateExperimentErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/experiments',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * Delete an experiment\n *\n * Archives the experiment (soft-delete via status transition). Returns `409` if the experiment is still `running` — stop it first.\n *\n * **Use case:** Tear down an experiment after the analysis is signed off.\n */\nexport const deleteExperiment = <ThrowOnError extends boolean = false>(options: Options<DeleteExperimentData, ThrowOnError>): RequestResult<DeleteExperimentResponses, DeleteExperimentErrors, ThrowOnError> => (options.client ?? client).delete<DeleteExperimentResponses, DeleteExperimentErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/experiments/{id}',\n ...options\n});\n\n/**\n * Get one experiment\n *\n * Returns the full experiment row including groups, params, allocation, and lifecycle timestamps.\n *\n * **Use case:** Fetch one experiment to render the detail page or to inspect its current allocation and group weights.\n */\nexport const getExperiment = <ThrowOnError extends boolean = false>(options: Options<GetExperimentData, ThrowOnError>): RequestResult<GetExperimentResponses, GetExperimentErrors, ThrowOnError> => (options.client ?? client).get<GetExperimentResponses, GetExperimentErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/experiments/{id}',\n ...options\n});\n\n/**\n * Update an experiment\n *\n * Partial update. `allocation_pct`, `groups`, `salt`, `universe`, `params` are **immutable while running** — returns `409` if you try. Stop the experiment first.\n *\n * Editing `groups` while in `draft` is fine; weights must still sum to 10000.\n *\n * **Use cases**\n *\n * - **Update metadata** — `description`, `tag`, `targeting_gate` editable any time.\n * - **Ramp before launch** — set `allocation_pct` while still in `draft`.\n * - **Tighten significance** — `significance_threshold` (Pro+).\n * - **Rewire groups** — replace `groups` wholesale while in `draft`; immutable once running.\n */\nexport const updateExperiment = <ThrowOnError extends boolean = false>(options: Options<UpdateExperimentData, ThrowOnError>): RequestResult<UpdateExperimentResponses, UpdateExperimentErrors, ThrowOnError> => (options.client ?? client).patch<UpdateExperimentResponses, UpdateExperimentErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/experiments/{id}',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * Transition experiment status\n *\n * Drives the experiment lifecycle. Allowed transitions:\n *\n * - `draft → running` — starts allocation. Bumps the `startedAt` timestamp.\n * - `running → stopped` — halts allocation. Existing exposures stay in the dataset.\n * - `stopped → archived` — soft-delete.\n * - `draft → archived` — discard an unstarted experiment.\n * - `archived → draft` — restore a soft-deleted experiment so it can be re-completed and started. Allowed only if it never started; one that already ran must be cloned instead.\n *\n * Restarting an `archived` experiment directly is not allowed — restore it to `draft` first. Returns `409` on illegal transitions and `429` if the plan's `experiments_running` limit is exceeded on `→ running`.\n *\n * **Use cases**\n *\n * - **Start** — `{ \"status\": \"running\" }` after wiring up the SDK and verifying targeting on staging.\n * - **Stop** — `{ \"status\": \"stopped\" }` once the experiment hits its `min_runtime_days` and conclusive results land.\n * - **Archive** — `{ \"status\": \"archived\" }` to soft-delete after sign-off.\n */\nexport const setExperimentStatus = <ThrowOnError extends boolean = false>(options: Options<SetExperimentStatusData, ThrowOnError>): RequestResult<SetExperimentStatusResponses, SetExperimentStatusErrors, ThrowOnError> => (options.client ?? client).post<SetExperimentStatusResponses, SetExperimentStatusErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/experiments/{id}/status',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * Attach metrics\n *\n * Replaces the experiment's metric attachments wholesale. Each entry pairs an existing `metric_id` with a `role` (`goal` / `guardrail` / `secondary`).\n *\n * Returns `422` if any `metric_id` doesn't exist in the project. Pass `{ metrics: [] }` to detach everything.\n *\n * **Use cases**\n *\n * - **Standard setup** — one `goal`, one or two `guardrail`, optional `secondary` metrics for diagnostics.\n * - **Detach all** — send `{ \"metrics\": [] }` before archiving.\n */\nexport const setExperimentMetrics = <ThrowOnError extends boolean = false>(options: Options<SetExperimentMetricsData, ThrowOnError>): RequestResult<SetExperimentMetricsResponses, SetExperimentMetricsErrors, ThrowOnError> => (options.client ?? client).post<SetExperimentMetricsResponses, SetExperimentMetricsErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/experiments/{id}/metrics',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * Get analysis results\n *\n * Returns the latest analysis output for the experiment — one row per metric/group/day, including sample size, mean, % delta vs. control, p-value, and a sample-ratio mismatch flag.\n *\n * **Use case:** Render the results table on the experiment detail page or drive an automated decision once a `goal` metric reaches significance.\n */\nexport const getExperimentResults = <ThrowOnError extends boolean = false>(options: Options<GetExperimentResultsData, ThrowOnError>): RequestResult<GetExperimentResultsResponses, GetExperimentResultsErrors, ThrowOnError> => (options.client ?? client).get<GetExperimentResultsResponses, GetExperimentResultsErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/experiments/{id}/results',\n ...options\n});\n\n/**\n * Get analysis timeseries\n *\n * Same row shape as `/results`, but returns every daily slice rather than the latest. Filter to a single metric with the `metric` query parameter.\n *\n * **Use case:** Drive a chart of metric movement over the experiment runtime, or sanity-check the lift is monotonic before deciding.\n */\nexport const getExperimentTimeseries = <ThrowOnError extends boolean = false>(options: Options<GetExperimentTimeseriesData, ThrowOnError>): RequestResult<GetExperimentTimeseriesResponses, GetExperimentTimeseriesErrors, ThrowOnError> => (options.client ?? client).get<GetExperimentTimeseriesResponses, GetExperimentTimeseriesErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/experiments/{id}/timeseries',\n ...options\n});\n\n/**\n * Re-queue analysis\n *\n * Requeues the daily analysis pass for this experiment outside the normal cron cadence. Useful after attaching a new metric or correcting an event taxonomy. The job runs asynchronously.\n *\n * **Use case:** Force-refresh results after wiring up a new metric without waiting for the next nightly cron tick.\n */\nexport const reanalyzeExperiment = <ThrowOnError extends boolean = false>(options: Options<ReanalyzeExperimentData, ThrowOnError>): RequestResult<ReanalyzeExperimentResponses, ReanalyzeExperimentErrors, ThrowOnError> => (options.client ?? client).post<ReanalyzeExperimentResponses, ReanalyzeExperimentErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/experiments/{id}/reanalyze',\n ...options\n});\n\n/**\n * Mint a readout snapshot\n *\n * Freezes the current results view into an immutable, dated readout snapshot — verdict, headline, per-metric numbers, the caveat list with its acknowledgment state, enrollment, and a hash of the assignment-relevant config. Ship/stop flows mint one automatically; \"Share readout\" mints one on demand. Snapshots are never updated after insert.\n *\n * Pass `requireAllAcknowledged: true` to enforce ship gating server-side — returns `422` while any open caveat is not listed in `acknowledgedCaveatIds`.\n *\n * **Use case:** Capture \"what the data said when we decided\" before shipping or stopping, so the decision stays auditable even after results move.\n */\nexport const createExperimentReadout = <ThrowOnError extends boolean = false>(options: Options<CreateExperimentReadoutData, ThrowOnError>): RequestResult<CreateExperimentReadoutResponses, CreateExperimentReadoutErrors, ThrowOnError> => (options.client ?? client).post<CreateExperimentReadoutResponses, CreateExperimentReadoutErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/experiments/{id}/readouts',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * Get a readout snapshot\n *\n * Returns one immutable readout snapshot — the frozen results view (verdict, headline, per-metric numbers, caveats, enrollment) captured when it was minted, plus the `configHash` that tells you whether it is still comparable to the live view.\n *\n * **Use case:** Render a shared, dated readout exactly as it looked at decision time.\n */\nexport const getExperimentReadout = <ThrowOnError extends boolean = false>(options: Options<GetExperimentReadoutData, ThrowOnError>): RequestResult<GetExperimentReadoutResponses, GetExperimentReadoutErrors, ThrowOnError> => (options.client ?? client).get<GetExperimentReadoutResponses, GetExperimentReadoutErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/experiments/{id}/readouts/{readoutId}',\n ...options\n});\n\n/**\n * List dynamic configs\n *\n * Returns a single page of configs ordered by `updated_at desc, id desc`. Each row includes the latest published `version` per env and any active drafts.\n *\n * **Use case:** Snapshot every config in the project — e.g. CI check that asserts no env is stuck on a stale default or that every config has a published value on prod.\n */\nexport const listConfigs = <ThrowOnError extends boolean = false>(options?: Options<ListConfigsData, ThrowOnError>): RequestResult<ListConfigsResponses, ListConfigsErrors, ThrowOnError> => (options?.client ?? client).get<ListConfigsResponses, ListConfigsErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/configs',\n ...options\n});\n\n/**\n * Create a dynamic config\n *\n * Creates a new config with the given `schema`. The initial `value` (or an empty object) is published as version 1 on **every** env.\n *\n * Returns `409` if `name` already exists in the project, `400` if `value` doesn't validate against `schema`.\n *\n * **Use cases**\n *\n * - **Minimal create** — `name` + `schema`. Initial value defaults to `{}`.\n * - **Seeded create** — supply a flat `value` to publish the same object on every env.\n * - **Per-env seed** — supply a `{ env: value }` map under `value`, or pass the env keys `dev`/`staging`/`prod` directly (each overrides `value` for that env and is published at version 1).\n */\nexport const createConfig = <ThrowOnError extends boolean = false>(options: Options<CreateConfigData, ThrowOnError>): RequestResult<CreateConfigResponses, CreateConfigErrors, ThrowOnError> => (options.client ?? client).post<CreateConfigResponses, CreateConfigErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/configs',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * Delete a dynamic config\n *\n * Soft-deletes the config and rebuilds the project's flags KV blob.\n *\n * **Use case:** Tear down a config after its consumers have stopped reading it.\n */\nexport const deleteConfig = <ThrowOnError extends boolean = false>(options: Options<DeleteConfigData, ThrowOnError>): RequestResult<DeleteConfigResponses, DeleteConfigErrors, ThrowOnError> => (options.client ?? client).delete<DeleteConfigResponses, DeleteConfigErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/configs/{id}',\n ...options\n});\n\n/**\n * Get one config\n *\n * Returns config metadata plus the latest published values per env and any active draft values. Use this to fetch the JSON the editor renders.\n *\n * **Use case:** Fetch one config's current published values and any in-flight drafts.\n */\nexport const getConfig = <ThrowOnError extends boolean = false>(options: Options<GetConfigData, ThrowOnError>): RequestResult<GetConfigResponses, GetConfigErrors, ThrowOnError> => (options.client ?? client).get<GetConfigResponses, GetConfigErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/configs/{id}',\n ...options\n});\n\n/**\n * Update a dynamic config\n *\n * Partial update. When `value` is supplied it is **republished on every env** (new version per env). A per-env key (`dev`/`staging`/`prod`) publishes a new version to **only that env**, immediately, overriding `value` for it. When `schema` is supplied it replaces the current schema; every existing value is re-validated.\n *\n * **Use cases**\n *\n * - **Republish flat value** — `{ \"value\": {…} }` sets the same value on every env.\n * - **Publish one env** — `{ \"prod\": {…} }` publishes a new version to prod only, instantly.\n * - **Schema migration** — `{ \"schema\": {…} }` replaces the schema; existing values are re-validated.\n */\nexport const updateConfig = <ThrowOnError extends boolean = false>(options: Options<UpdateConfigData, ThrowOnError>): RequestResult<UpdateConfigResponses, UpdateConfigErrors, ThrowOnError> => (options.client ?? client).patch<UpdateConfigResponses, UpdateConfigErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/configs/{id}',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * Discard a draft\n *\n * Drops the in-flight draft on one env. Published values are unaffected.\n *\n * **Use case:** Abandon an in-progress draft after deciding not to ship it.\n */\nexport const discardConfigDraft = <ThrowOnError extends boolean = false>(options: Options<DiscardConfigDraftData, ThrowOnError>): RequestResult<DiscardConfigDraftResponses, DiscardConfigDraftErrors, ThrowOnError> => (options.client ?? client).delete<DiscardConfigDraftResponses, DiscardConfigDraftErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/configs/{id}/drafts',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * Save a draft value\n *\n * Stages a value for one env without publishing. The draft is validated against the config's current schema and stored alongside the `baseVersion` it was forked from.\n *\n * Saving over an existing draft overwrites it. Use `POST /{id}/publish` to promote it to a new published version.\n *\n * **Use case:** Iterate on a config value on dev without affecting prod — preview in staging, then publish.\n */\nexport const saveConfigDraft = <ThrowOnError extends boolean = false>(options: Options<SaveConfigDraftData, ThrowOnError>): RequestResult<SaveConfigDraftResponses, SaveConfigDraftErrors, ThrowOnError> => (options.client ?? client).put<SaveConfigDraftResponses, SaveConfigDraftErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/configs/{id}/drafts',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * Publish a draft\n *\n * Promotes the staged draft on one env to a new published version. The draft must still validate against the current schema.\n *\n * Returns `404` if there is no draft for the given env.\n *\n * **Use case:** Ship a staged change once you've validated it on a lower env.\n */\nexport const publishConfigDraft = <ThrowOnError extends boolean = false>(options: Options<PublishConfigDraftData, ThrowOnError>): RequestResult<PublishConfigDraftResponses, PublishConfigDraftErrors, ThrowOnError> => (options.client ?? client).post<PublishConfigDraftResponses, PublishConfigDraftErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/configs/{id}/publish',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * List config activity\n *\n * Returns recent audit rows for one config (create, update, draft.save, publish, delete) ordered newest first. Use the `limit` query parameter to cap the result (1–100, default 20).\n *\n * **Use case:** Render the activity panel in the config editor or drive a slack notification on publish events.\n */\nexport const listConfigActivity = <ThrowOnError extends boolean = false>(options: Options<ListConfigActivityData, ThrowOnError>): RequestResult<ListConfigActivityResponses, ListConfigActivityErrors, ThrowOnError> => (options.client ?? client).get<ListConfigActivityResponses, ListConfigActivityErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/configs/{id}/activity',\n ...options\n});\n\n/**\n * Update a config schema\n *\n * Replaces a config's JSON Schema in place. Every existing published value is re-validated against the new schema before it lands; the update fails if any value no longer validates.\n *\n * **Use case:** Evolve a config's shape (add/remove a field) without republishing values.\n */\nexport const updateConfigSchema = <ThrowOnError extends boolean = false>(options: Options<UpdateConfigSchemaData, ThrowOnError>): RequestResult<UpdateConfigSchemaResponses, UpdateConfigSchemaErrors, ThrowOnError> => (options.client ?? client).patch<UpdateConfigSchemaResponses, UpdateConfigSchemaErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/configs/{id}/schema',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * List config version history\n *\n * Returns every published version of the config's value on one env, newest first. The `env` query parameter picks the environment (`dev`, `staging`, or `prod`) and defaults to `prod`; an unknown env returns `400`. The config's JSON Schema is config-level and not versioned — this is value history only.\n *\n * **Use case:** Render the History timeline in the config detail pane (value diff + restore), or audit which value was live on prod at a given version.\n */\nexport const listConfigVersions = <ThrowOnError extends boolean = false>(options: Options<ListConfigVersionsData, ThrowOnError>): RequestResult<ListConfigVersionsResponses, ListConfigVersionsErrors, ThrowOnError> => (options.client ?? client).get<ListConfigVersionsResponses, ListConfigVersionsErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/configs/{id}/versions',\n ...options\n});\n\n/**\n * List killswitches\n *\n * Returns a single page of killswitches ordered by `updated_at desc, id desc`. Each row includes the latest published `value`/`switches`/`version` per env.\n *\n * **Use case:** Snapshot every killswitch in the project — e.g. to render an incident-response runbook listing every kill and its current trip state.\n */\nexport const listKillswitches = <ThrowOnError extends boolean = false>(options?: Options<ListKillswitchesData, ThrowOnError>): RequestResult<ListKillswitchesResponses, ListKillswitchesErrors, ThrowOnError> => (options?.client ?? client).get<ListKillswitchesResponses, ListKillswitchesErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/killswitches',\n ...options\n});\n\n/**\n * Create a killswitch\n *\n * Creates a new killswitch with `value` (default `false`) applied to **every** env at version 1.\n *\n * Returns `409` if `name` already exists in the project.\n *\n * **Use cases**\n *\n * - **Untripped create** — `{ \"name\": \"payments.checkout\" }`. Provision the kill ahead of an incident.\n * - **Pre-tripped** — `{ \"value\": true }` to ship the killswitch already engaged.\n * - **With switches** — seed `switches` to carve out per-region/per-tenant kills from day one.\n */\nexport const createKillswitch = <ThrowOnError extends boolean = false>(options: Options<CreateKillswitchData, ThrowOnError>): RequestResult<CreateKillswitchResponses, CreateKillswitchErrors, ThrowOnError> => (options.client ?? client).post<CreateKillswitchResponses, CreateKillswitchErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/killswitches',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * Delete a killswitch\n *\n * Soft-deletes the killswitch and rebuilds the project's flags KV blob so SDKs stop seeing it.\n *\n * **Use case:** Tear down a killswitch after the feature it protected has been removed.\n */\nexport const deleteKillswitch = <ThrowOnError extends boolean = false>(options: Options<DeleteKillswitchData, ThrowOnError>): RequestResult<DeleteKillswitchResponses, DeleteKillswitchErrors, ThrowOnError> => (options.client ?? client).delete<DeleteKillswitchResponses, DeleteKillswitchErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/killswitches/{id}',\n ...options\n});\n\n/**\n * Get one killswitch\n *\n * Returns the killswitch metadata plus the latest published `value`/`switches`/`version` per env.\n *\n * **Use case:** Fetch the current state of one killswitch — e.g. to verify a trip propagated before declaring an incident mitigated.\n */\nexport const getKillswitch = <ThrowOnError extends boolean = false>(options: Options<GetKillswitchData, ThrowOnError>): RequestResult<GetKillswitchResponses, GetKillswitchErrors, ThrowOnError> => (options.client ?? client).get<GetKillswitchResponses, GetKillswitchErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/killswitches/{id}',\n ...options\n});\n\n/**\n * Update a killswitch\n *\n * Partial update applied to **every** env. Setting `value`/`switches` publishes a new version per env. Description-only patches don't bump versions.\n *\n * To change a single switch on a single env, use `PUT /{id}/switch` instead.\n *\n * **Use cases**\n *\n * - **Trip everywhere** — `{ \"value\": true }`. Kills the feature across dev/stage/prod in one call.\n * - **Untrip everywhere** — `{ \"value\": false }`.\n * - **Replace switches** — send the full new map; per-key edits use `PUT /{id}/switch`.\n * - **Update description** — metadata-only patches don't bump versions.\n */\nexport const updateKillswitch = <ThrowOnError extends boolean = false>(options: Options<UpdateKillswitchData, ThrowOnError>): RequestResult<UpdateKillswitchResponses, UpdateKillswitchErrors, ThrowOnError> => (options.client ?? client).patch<UpdateKillswitchResponses, UpdateKillswitchErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/killswitches/{id}',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * Remove one switch entry\n *\n * Removes a single `switchKey` from the `switches` map on a single `env`. Publishes a new version on that env.\n *\n * Returns `{ removed: false }` if the entry didn't exist (idempotent no-op).\n *\n * **Use case:** Clean up a per-region override after the incident is resolved so the flat `value` governs again.\n */\nexport const unsetKillswitchSwitch = <ThrowOnError extends boolean = false>(options: Options<UnsetKillswitchSwitchData, ThrowOnError>): RequestResult<UnsetKillswitchSwitchResponses, UnsetKillswitchSwitchErrors, ThrowOnError> => (options.client ?? client).delete<UnsetKillswitchSwitchResponses, UnsetKillswitchSwitchErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/killswitches/{id}/switch',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * Set one switch entry\n *\n * Sets or updates a single `switchKey` on a single `env`. Publishes one new version on that env only — other envs untouched.\n *\n * Use this for surgical per-env, per-key flips during incident response (e.g. trip `eu_region` on prod without touching the flat `value` or other envs).\n *\n * **Use cases**\n *\n * - **Trip a region** — `{ \"env\": \"prod\", \"switchKey\": \"eu_region\", \"value\": true }`.\n * - **Untrip without removing** — same payload with `value: false`. To remove the entry entirely use `DELETE /{id}/switch`.\n */\nexport const setKillswitchSwitch = <ThrowOnError extends boolean = false>(options: Options<SetKillswitchSwitchData, ThrowOnError>): RequestResult<SetKillswitchSwitchResponses, SetKillswitchSwitchErrors, ThrowOnError> => (options.client ?? client).put<SetKillswitchSwitchResponses, SetKillswitchSwitchErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/killswitches/{id}/switch',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * Set the flat value on one env\n *\n * Sets the flat `value` on a single `env`, publishing one new version on that env only. `switches` and other envs are untouched.\n *\n * Use this to trip (or untrip) a killswitch on one environment without replacing its per-key overrides.\n *\n * **Use cases**\n *\n * - **Trip on prod** — `{ \"env\": \"prod\", \"value\": true }`.\n * - **Untrip on prod** — `{ \"env\": \"prod\", \"value\": false }`.\n */\nexport const setKillswitchValue = <ThrowOnError extends boolean = false>(options: Options<SetKillswitchValueData, ThrowOnError>): RequestResult<SetKillswitchValueResponses, SetKillswitchValueErrors, ThrowOnError> => (options.client ?? client).put<SetKillswitchValueResponses, SetKillswitchValueErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/killswitches/{id}/value',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * Toggle a killswitch or one of its switches\n *\n * Flips a killswitch on one environment and publishes a new version there. This is the one-call incident verb: it reads the current value, flips it, and publishes, so you don't have to fetch the killswitch first.\n *\n * Every body field is optional, which is what makes the call widen cleanly:\n *\n * - **Flip the killswitch** — `{}`. Flips the flat `value` on `prod`.\n * - **Flip one sub-switch** — `{ \"switchKey\": \"eu_region\" }`. Flips that entry on `prod`, creating it (from `false`) if it isn't in the map yet.\n * - **Set it idempotently** — `{ \"switchKey\": \"eu_region\", \"value\": true }`. Publishes exactly that value, so a retried call can't undo the first one. A `null` `value` means \"flip\", not \"set to null\".\n * - **Choose the environment** — add `\"env\": \"staging\"`. Omitted, `env` is `prod`.\n *\n * The response reports both `previous` and `value`, so a caller that asked for a flip can see what it actually changed.\n *\n * Prefer this over `PUT /{id}/value` and `PUT /{id}/switch` unless you specifically need those endpoints' unconditional set semantics.\n */\nexport const toggleKillswitch = <ThrowOnError extends boolean = false>(options: Options<ToggleKillswitchData, ThrowOnError>): RequestResult<ToggleKillswitchResponses, ToggleKillswitchErrors, ThrowOnError> => (options.client ?? client).post<ToggleKillswitchResponses, ToggleKillswitchErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/killswitches/{id}/toggle',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * List universes\n *\n * Returns a single page of universes ordered by `created_at desc, id desc`. The universes table has no `updated_at`, so this list is keyed on creation time.\n *\n * **Use case:** Snapshot every universe in the project — for example to audit which `unit_type` and `holdout_range` are in use before launching a new experiment.\n */\nexport const listUniverses = <ThrowOnError extends boolean = false>(options?: Options<ListUniversesData, ThrowOnError>): RequestResult<ListUniversesResponses, ListUniversesErrors, ThrowOnError> => (options?.client ?? client).get<ListUniversesResponses, ListUniversesErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/universes',\n ...options\n});\n\n/**\n * Create a universe\n *\n * Creates a new universe. Only `name` is required — `unit_type` defaults to `user_id` and `holdout_range` defaults to `null` (no holdout).\n *\n * Returns `409` if `name` already exists in the project. Returns `403` if you supply `holdout_range` on a plan below Pro.\n *\n * **Use cases**\n *\n * - **Default universe** — `{ \"name\": \"primary_users\" }`. Per-user randomisation, no holdout.\n * - **Reserved holdout** — supply `holdout_range` to carve out a measurement slice excluded from all experiments.\n * - **Account-level** — `unit_type: 'account_id'` so multi-seat accounts see one consistent variant.\n */\nexport const createUniverse = <ThrowOnError extends boolean = false>(options: Options<CreateUniverseData, ThrowOnError>): RequestResult<CreateUniverseResponses, CreateUniverseErrors, ThrowOnError> => (options.client ?? client).post<CreateUniverseResponses, CreateUniverseErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/universes',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * Delete a universe\n *\n * Soft-deletes the universe. Returns `409` if any non-archived experiment still references it — archive those experiments first.\n *\n * **Use case:** Tear down a universe after every experiment that used it has been archived.\n */\nexport const deleteUniverse = <ThrowOnError extends boolean = false>(options: Options<DeleteUniverseData, ThrowOnError>): RequestResult<DeleteUniverseResponses, DeleteUniverseErrors, ThrowOnError> => (options.client ?? client).delete<DeleteUniverseResponses, DeleteUniverseErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/universes/{id}',\n ...options\n});\n\n/**\n * Update a universe\n *\n * Partial update. Only `holdout_range` is mutable — `name` and `unit_type` are immutable after create.\n *\n * Pass `\"holdout_range\": null` to remove an existing holdout.\n *\n * **Use cases**\n *\n * - **Adjust holdout** — change the reserved measurement slice without recreating experiments.\n * - **Remove holdout** — `{ \"holdout_range\": null }`.\n */\nexport const updateUniverse = <ThrowOnError extends boolean = false>(options: Options<UpdateUniverseData, ThrowOnError>): RequestResult<UpdateUniverseResponses, UpdateUniverseErrors, ThrowOnError> => (options.client ?? client).patch<UpdateUniverseResponses, UpdateUniverseErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/universes/{id}',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * List gate templates\n *\n * Returns the merged targeting-rule template catalog — read-only **built-ins first** (the `@team`/`@owner` audience aliases, country, email-domain, region presets, …), then this project's **customer** templates. Each item carries a `rules: [{ attr, op, value }]` definition; the alias templates carry a symbol value (`email in [\"@team\"]`) that the SDK expands to the resolved email list at rebuild.\n *\n * **Turn \"launch X in country Y\" into a gated flag:** list templates (optionally with `q`), take the matching template's `rules`, substitute the concrete value(s), and pass them as the `rules` arg of `release_flags_create`.\n *\n * The catalog is small and bounded, so the full merged set is returned in one page — this endpoint is **not** paginated (`next_cursor` is always `null`; there are no `limit`/`cursor` params).\n */\nexport const listGateTemplates = <ThrowOnError extends boolean = false>(options?: Options<ListGateTemplatesData, ThrowOnError>): RequestResult<ListGateTemplatesResponses, ListGateTemplatesErrors, ThrowOnError> => (options?.client ?? client).get<ListGateTemplatesResponses, ListGateTemplatesErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/gates/templates',\n ...options\n});\n\n/**\n * Create a gate template\n *\n * Creates a per-project (customer) targeting-rule template. Built-ins are read-only and cannot be created here. Returns `409` if a template with this `name` already exists in the project.\n */\nexport const createGateTemplate = <ThrowOnError extends boolean = false>(options: Options<CreateGateTemplateData, ThrowOnError>): RequestResult<CreateGateTemplateResponses, CreateGateTemplateErrors, ThrowOnError> => (options.client ?? client).post<CreateGateTemplateResponses, CreateGateTemplateErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/gates/templates',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * Delete a gate template\n *\n * Soft-deletes (archives) a **customer** template. Returns `409` if `id` names a read-only built-in template.\n */\nexport const deleteGateTemplate = <ThrowOnError extends boolean = false>(options: Options<DeleteGateTemplateData, ThrowOnError>): RequestResult<DeleteGateTemplateResponses, DeleteGateTemplateErrors, ThrowOnError> => (options.client ?? client).delete<DeleteGateTemplateResponses, DeleteGateTemplateErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/gates/templates/{id}',\n ...options\n});\n\n/**\n * Get one gate template\n *\n * Returns a single template by its `id` — a built-in slug (`country`) or a customer `gtpl_…` id.\n */\nexport const getGateTemplate = <ThrowOnError extends boolean = false>(options: Options<GetGateTemplateData, ThrowOnError>): RequestResult<GetGateTemplateResponses, GetGateTemplateErrors, ThrowOnError> => (options.client ?? client).get<GetGateTemplateResponses, GetGateTemplateErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/gates/templates/{id}',\n ...options\n});\n\n/**\n * Update a gate template\n *\n * Partial update of a **customer** template. `rules` replaces the list wholesale. Returns `409` if `id` names a read-only built-in template.\n */\nexport const updateGateTemplate = <ThrowOnError extends boolean = false>(options: Options<UpdateGateTemplateData, ThrowOnError>): RequestResult<UpdateGateTemplateResponses, UpdateGateTemplateErrors, ThrowOnError> => (options.client ?? client).patch<UpdateGateTemplateResponses, UpdateGateTemplateErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/gates/templates/{id}',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * List targeting attributes\n *\n * Returns every auto-inferred targeting attribute in the project — the `name` and (when known) the value `type` — for building gate/experiment targeting rules.\n *\n * **Use case:** Discover which user-context keys are available before authoring a targeting rule, instead of guessing attribute names.\n */\nexport const listAttributes = <ThrowOnError extends boolean = false>(options?: Options<ListAttributesData, ThrowOnError>): RequestResult<ListAttributesResponses, ListAttributesErrors, ThrowOnError> => (options?.client ?? client).get<ListAttributesResponses, ListAttributesErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/attributes',\n ...options\n});\n\n/**\n * Declare a targeting attribute\n *\n * Declare a targeting attribute the SDK reports and gates/experiments can target. `type: enum` requires `enum_values`.\n *\n * **Use case:** Register a `plan` or `country` attribute so targeting rules can reference it.\n */\nexport const createAttribute = <ThrowOnError extends boolean = false>(options: Options<CreateAttributeData, ThrowOnError>): RequestResult<CreateAttributeResponses, CreateAttributeErrors, ThrowOnError> => (options.client ?? client).post<CreateAttributeResponses, CreateAttributeErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/attributes',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * Archive a targeting attribute\n *\n * Soft-deletes (archives) a targeting attribute.\n *\n * **Use case:** Retire an attribute no targeting rule references anymore (the user-facing verb is `archive`).\n */\nexport const deleteAttribute = <ThrowOnError extends boolean = false>(options: Options<DeleteAttributeData, ThrowOnError>): RequestResult<DeleteAttributeResponses, DeleteAttributeErrors, ThrowOnError> => (options.client ?? client).delete<DeleteAttributeResponses, DeleteAttributeErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/attributes/{id}',\n ...options\n});\n\n/**\n * Get a targeting attribute\n *\n * Fetch one targeting attribute by id.\n *\n * **Use case:** Inspect an attribute's declared type + allowed values before editing it.\n */\nexport const getAttribute = <ThrowOnError extends boolean = false>(options: Options<GetAttributeData, ThrowOnError>): RequestResult<GetAttributeResponses, GetAttributeErrors, ThrowOnError> => (options.client ?? client).get<GetAttributeResponses, GetAttributeErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/attributes/{id}',\n ...options\n});\n\n/**\n * Update a targeting attribute\n *\n * Update a targeting attribute's type, allowed values, required flag, description, or SDK path. `name` is immutable.\n *\n * **Use case:** Add an allowed value to an `enum` attribute, or flip its required flag.\n */\nexport const updateAttribute = <ThrowOnError extends boolean = false>(options: Options<UpdateAttributeData, ThrowOnError>): RequestResult<UpdateAttributeResponses, UpdateAttributeErrors, ThrowOnError> => (options.client ?? client).patch<UpdateAttributeResponses, UpdateAttributeErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/attributes/{id}',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * List metrics\n *\n * Returns every metric in the project (not paginated) — name, folder, source event, the typed `queryIr`, and the rendered query.\n *\n * **Use case:** Audit every metric defined in the project — for example to find the metric id to attach as an experiment's success metric.\n */\nexport const listMetrics = <ThrowOnError extends boolean = false>(options?: Options<ListMetricsData, ThrowOnError>): RequestResult<ListMetricsResponses, ListMetricsErrors, ThrowOnError> => (options?.client ?? client).get<ListMetricsResponses, ListMetricsErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/metrics',\n ...options\n});\n\n/**\n * Create a metric\n *\n * Creates an event-backed metric. Pass the query as the DSL string (`query`) **or**\n * the typed IR (`query_ir`) — exactly one. `event_name` must equal the event the\n * query references.\n *\n * Returns `409` if a metric with the same `name` already exists, and `422` if the\n * query is invalid or references an unregistered event / label.\n *\n * **Use cases**\n *\n * - **Track an event** — `count(<event>)` for event counts.\n * - **Sum a value** — `sum(<event>, <label>)` for revenue / quantity metrics.\n * - **Experiment success metric** — create the metric, then attach its id to an experiment.\n */\nexport const createMetric = <ThrowOnError extends boolean = false>(options: Options<CreateMetricData, ThrowOnError>): RequestResult<CreateMetricResponses, CreateMetricErrors, ThrowOnError> => (options.client ?? client).post<CreateMetricResponses, CreateMetricErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/metrics',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * Archive a metric\n *\n * Soft-deletes (archives) the metric. Returns `409` if it is attached to a running experiment — stop those experiments first.\n *\n * **Use case:** Retire a metric once no running experiment depends on it (the user-facing verb is `archive`).\n */\nexport const deleteMetric = <ThrowOnError extends boolean = false>(options: Options<DeleteMetricData, ThrowOnError>): RequestResult<DeleteMetricResponses, DeleteMetricErrors, ThrowOnError> => (options.client ?? client).delete<DeleteMetricResponses, DeleteMetricErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/metrics/{id}',\n ...options\n});\n\n/**\n * Get a metric\n *\n * Fetch one metric by its id or name, including the rendered DSL query and the typed IR.\n *\n * **Use case:** Inspect a single metric's full definition before reusing it in an experiment or alert rule.\n */\nexport const getMetric = <ThrowOnError extends boolean = false>(options: Options<GetMetricData, ThrowOnError>): RequestResult<GetMetricResponses, GetMetricErrors, ThrowOnError> => (options.client ?? client).get<GetMetricResponses, GetMetricErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/metrics/{id}',\n ...options\n});\n\n/**\n * Update a metric\n *\n * Update a metric's definition — folder, source event, query (`query` DSL or typed `query_ir`), winsorisation, minimum detectable effect, or direction. `name` is immutable. Provide at most one of `query` / `query_ir`.\n *\n * **Use case:** Refine a metric's query or guardrail direction without recreating it.\n */\nexport const updateMetric = <ThrowOnError extends boolean = false>(options: Options<UpdateMetricData, ThrowOnError>): RequestResult<UpdateMetricResponses, UpdateMetricErrors, ThrowOnError> => (options.client ?? client).patch<UpdateMetricResponses, UpdateMetricErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/metrics/{id}',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * List experiments using a metric\n *\n * Returns every experiment that attaches this metric — as `goal`, `guardrail`, or `secondary` — ordered with running experiments first, then by role weight (goal > guardrail > secondary).\n *\n * **Use case:** See who depends on a metric before editing or archiving it — e.g. the metric detail panel's \"used by\" list.\n */\nexport const listMetricExperiments = <ThrowOnError extends boolean = false>(options: Options<ListMetricExperimentsData, ThrowOnError>): RequestResult<ListMetricExperimentsResponses, ListMetricExperimentsErrors, ThrowOnError> => (options.client ?? client).get<ListMetricExperimentsResponses, ListMetricExperimentsErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/metrics/{id}/experiments',\n ...options\n});\n\n/**\n * Unarchive a metric\n *\n * Reverses a soft-delete (archive), making the metric live again. Idempotent — unarchiving a metric that is already live succeeds with no effect.\n *\n * **Use case:** Undo an accidental archive (the metrics list \"Undo\" toast calls this).\n */\nexport const unarchiveMetric = <ThrowOnError extends boolean = false>(options: Options<UnarchiveMetricData, ThrowOnError>): RequestResult<UnarchiveMetricResponses, UnarchiveMetricErrors, ThrowOnError> => (options.client ?? client).post<UnarchiveMetricResponses, UnarchiveMetricErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/metrics/{id}/unarchive',\n ...options\n});\n\n/**\n * Get a metric's time series\n *\n * Compiles the metric's typed IR into Analytics Engine SQL and returns the bucketed series over the requested window (near-real-time; ingest lag is seconds). The window bounds are epoch **seconds**; `to` must be strictly greater than `from`. The response echoes the SQL that produced the rows.\n *\n * Returns `422` when the stored definition can't compile (e.g. a label or event has gone away — re-save the metric), and `502`/`503` when the analytics upstream fails or isn't configured.\n *\n * **Use case:** Render the metric trend chart / sparkline, or pull raw bucketed values to feed an external dashboard.\n */\nexport const getMetricSeries = <ThrowOnError extends boolean = false>(options: Options<GetMetricSeriesData, ThrowOnError>): RequestResult<GetMetricSeriesResponses, GetMetricSeriesErrors, ThrowOnError> => (options.client ?? client).post<GetMetricSeriesResponses, GetMetricSeriesErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/metrics/{id}/series',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * List events\n *\n * Returns every catalogued event in the project, including pending auto-discovered names. Each row carries its own `pending` flag, so the unapproved queue can be filtered client-side.\n *\n * **Use case:** Snapshot the event catalog — for example to review the pending auto-discovery queue before approving names, or to confirm which events your metrics can reference.\n */\nexport const listEvents = <ThrowOnError extends boolean = false>(options?: Options<ListEventsData, ThrowOnError>): RequestResult<ListEventsResponses, ListEventsErrors, ThrowOnError> => (options?.client ?? client).get<ListEventsResponses, ListEventsErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/events',\n ...options\n});\n\n/**\n * Register an event\n *\n * Registers a new event name and (optionally) its typed properties. Only `name` is required.\n *\n * If the name matches an existing **pending** (auto-discovered) row, this approves that row instead of returning a conflict. Otherwise an already-registered name returns `409`.\n *\n * **Use cases**\n *\n * - **Register a known event** — `{ \"name\": \"checkout_completed\" }` so metrics can reference it.\n * - **Declare typed properties** — supply `properties` to document the event's payload shape.\n */\nexport const createEvent = <ThrowOnError extends boolean = false>(options: Options<CreateEventData, ThrowOnError>): RequestResult<CreateEventResponses, CreateEventErrors, ThrowOnError> => (options.client ?? client).post<CreateEventResponses, CreateEventErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/events',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * Archive an event\n *\n * Soft-deletes (archives) the event. Returns `409` if any metric still references it — delete those metrics first.\n *\n * **Use case:** Retire an event from the catalog once no metric depends on it.\n */\nexport const deleteEvent = <ThrowOnError extends boolean = false>(options: Options<DeleteEventData, ThrowOnError>): RequestResult<DeleteEventResponses, DeleteEventErrors, ThrowOnError> => (options.client ?? client).delete<DeleteEventResponses, DeleteEventErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/events/{id}',\n ...options\n});\n\n/**\n * Get an event\n *\n * Returns one event's full detail. Resolves by exact id, unique id-prefix, or exact (unique) name.\n *\n * **Use case:** Inspect one event's declared properties and pending state by id or name.\n */\nexport const getEvent = <ThrowOnError extends boolean = false>(options: Options<GetEventData, ThrowOnError>): RequestResult<GetEventResponses, GetEventErrors, ThrowOnError> => (options.client ?? client).get<GetEventResponses, GetEventErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/events/{id}',\n ...options\n});\n\n/**\n * Update an event\n *\n * Partial update of an event's folder, description, or properties. `name` is immutable.\n *\n * `properties` replaces the full set (no merge) — omit it to leave properties unchanged.\n *\n * **Use case:** Refile an event, update its description, or redeclare its typed properties.\n */\nexport const updateEvent = <ThrowOnError extends boolean = false>(options: Options<UpdateEventData, ThrowOnError>): RequestResult<UpdateEventResponses, UpdateEventErrors, ThrowOnError> => (options.client ?? client).patch<UpdateEventResponses, UpdateEventErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/events/{id}',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * Approve a pending event\n *\n * Promotes a pending (auto-discovered) event to usable so metrics can query it (`pending` → `0`).\n *\n * You may optionally declare the event's folder, description, or properties in the same call — the body is the same shape as update, and may be empty.\n *\n * **Use case:** Clear an auto-discovered event out of the pending queue so metrics defined on it start resolving.\n */\nexport const approveEvent = <ThrowOnError extends boolean = false>(options: Options<ApproveEventData, ThrowOnError>): RequestResult<ApproveEventResponses, ApproveEventErrors, ThrowOnError> => (options.client ?? client).post<ApproveEventResponses, ApproveEventErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/events/{id}/approve',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * List the operational queue\n *\n * Returns the unified ops queue (bugs, feature requests, errors, alerts, measurement plans) in work order — highest priority first, oldest first within a priority — so consumers work it top-down. Every filter is applied in SQL before paging, and filters combine with AND. Human-gated holding states (items awaiting human sign-off in the dashboard) are never returned by `all`/default status.\n *\n * **Filters:** `type` (one item type), `status` (one lifecycle status, or `unresolved` — everything not yet `resolved`/`wont_fix`), `priority` (one triage priority), `owner` (one person or agent), and `scope=ready` — the items ready to be picked up right now: `open`, with nobody working them (no open run), and either unowned or reopened (sent back to `open` after an earlier run finished).\n *\n * **Paging:** `limit` is the page size and `offset` the number of items to skip. The order is stable, so walk the queue with `offset += limit`; a page shorter than `limit` is the last one.\n *\n * **Use case:** Pull the open queue to triage — e.g. every `bug` still `open` — before working items down one by one.\n */\nexport const listOpsItems = <ThrowOnError extends boolean = false>(options?: Options<ListOpsItemsData, ThrowOnError>): RequestResult<ListOpsItemsResponses, ListOpsItemsErrors, ThrowOnError> => (options?.client ?? client).get<ListOpsItemsResponses, ListOpsItemsErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/ops',\n ...options\n});\n\n/**\n * File a queue item\n *\n * Files one queue item — a bug report or a feature request — and fires the project's connectors (GitHub issue / Slack). `type` selects which; only the two user-fileable types are accepted (`error`/`alert` tickets are auto-filed by the platform). Returns the new id and per-project number.\n *\n * **Use cases**\n *\n * - **File a bug** — `{ \"type\": \"bug\", \"title\": \"Checkout 500s on Safari\", \"stepsToReproduce\": \"…\" }`.\n * - **File a feature request** — `{ \"type\": \"feature_request\", \"title\": \"Dark mode\", \"priority\": \"nice_to_have\" }`.\n */\nexport const createOpsItem = <ThrowOnError extends boolean = false>(options: Options<CreateOpsItemData, ThrowOnError>): RequestResult<CreateOpsItemResponses, CreateOpsItemErrors, ThrowOnError> => (options.client ?? client).post<CreateOpsItemResponses, CreateOpsItemErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/ops',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * File a bug\n *\n * Files one bug onto a project's queue, awaiting human approval. This is the **public** intake: it authenticates with a *client* SDK key rather than an admin key, so it can be called from a CLI, an installer script, a devtools overlay, or any shipped code — the same places a client key already lives.\n *\n * Three gates decide whether a ticket is filed, and nothing else the caller sends can widen them:\n *\n * 1. the key is a `client` key carrying the `tickets:public_create` scope,\n * 2. the key's project has public ticket creation enabled, and\n * 3. the item is filed as `pending_approval` — parked out of the work queue until a human promotes it in the dashboard.\n *\n * The project is the key's own project; there is no `X-Project-Id` to pass and no way to file into someone else's queue. Repeat submissions of the same title dedupe against the open ticket already tracking it, which returns `200` with `deduped: true` instead of filing again.\n *\n * Send a `dedupKey` to own that grain yourself — the same key from a monitor, a job, or a retried install re-triggers its open ticket: the ticket's fields are refreshed from the new payload and a \"re-triggered\" comment is appended (`200` with `deduped: true, updated: true`), so one recurring failure stays one ticket with its history intact.\n *\n * This endpoint is served by the Shipeasy **edge worker** (`api.shipeasy.ai`), not the admin API — see `servers` below.\n *\n * **Use case:** `shipeasy setup` fails on a customer's machine and self-reports the failure with the user's consent — `{ \"title\": \"Setup failed at Feature installs\", \"stepsToReproduce\": \"…\", \"actualResult\": \"…\" }`.\n */\nexport const createPublicBug = <ThrowOnError extends boolean = false>(options: Options<CreatePublicBugData, ThrowOnError>): RequestResult<CreatePublicBugResponses, CreatePublicBugErrors, ThrowOnError> => (options.client ?? client).post<CreatePublicBugResponses, CreatePublicBugErrors, ThrowOnError>({\n security: [{ name: 'X-SDK-Key', type: 'apiKey' }],\n url: '/ops/bug',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * File a feature request\n *\n * Files one feature request onto a project's queue, awaiting human approval. The feature-request counterpart to `POST /ops/bug`, with the same three gates: a `client` key carrying `tickets:public_create`, a project that has opted in, and a `pending_approval` state forced server-side.\n *\n * The project is the key's own project; there is no `X-Project-Id` to pass. Repeat submissions of the same title dedupe against the open ticket already tracking it, which returns `200` with `deduped: true` instead of filing again. A `dedupKey` works exactly as on `POST /ops/bug`: a repeat carrying the same key refreshes the open ticket and comments that it was re-triggered.\n *\n * This endpoint is served by the Shipeasy **edge worker** (`api.shipeasy.ai`), not the admin API — see `servers` below.\n *\n * **Use case:** An in-product \"request a feature\" form posts what the user asked for — `{ \"title\": \"Dark mode\", \"useCase\": \"Reduce eye strain at night\" }`.\n */\nexport const createPublicFeatureRequest = <ThrowOnError extends boolean = false>(options: Options<CreatePublicFeatureRequestData, ThrowOnError>): RequestResult<CreatePublicFeatureRequestResponses, CreatePublicFeatureRequestErrors, ThrowOnError> => (options.client ?? client).post<CreatePublicFeatureRequestResponses, CreatePublicFeatureRequestErrors, ThrowOnError>({\n security: [{ name: 'X-SDK-Key', type: 'apiKey' }],\n url: '/ops/feature-request',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * Delete a queue item\n *\n * Permanently delete a queue item — any type — along with its comment thread, attachments, tags, and investigation records. A human (dashboard) action: the route is never allow-listed for restricted ops keys. Irreversible; to take an item out of the queue without destroying it, set its status (`wont_fix`/`resolved`) instead.\n *\n * **Use case:** Remove a junk or duplicate report for good.\n */\nexport const deleteOpsItem = <ThrowOnError extends boolean = false>(options: Options<DeleteOpsItemData, ThrowOnError>): RequestResult<DeleteOpsItemResponses, DeleteOpsItemErrors, ThrowOnError> => (options.client ?? client).delete<DeleteOpsItemResponses, DeleteOpsItemErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/ops/{handle}',\n ...options\n});\n\n/**\n * Get one queue item\n *\n * Fetch a single queue item by its per-project `number` or full id.\n *\n * **Use case:** Inspect one item's full detail before updating its status or linking a PR.\n */\nexport const getOpsItem = <ThrowOnError extends boolean = false>(options: Options<GetOpsItemData, ThrowOnError>): RequestResult<GetOpsItemResponses, GetOpsItemErrors, ThrowOnError> => (options.client ?? client).get<GetOpsItemResponses, GetOpsItemErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/ops/{handle}',\n ...options\n});\n\n/**\n * Update a queue item\n *\n * Update a queue item. The body is validated against the item's stored type: a `bug` accepts its content fields (title, steps-to-reproduce, actual/expected result) plus `status`/`priority`/`notify` and a GitHub PR link; a `feature_request` its content (title, description, use-case) plus the same triage fields; `error`/`alert`/`measure_plan` accept `status`/`priority`/`notify` only (their content is platform-owned). Pass at least one field.\n *\n * Completing an `error` ticket (status `resolved` or `ready_for_qa`) also resolves the tracked error it links to; the error reopens automatically if it recurs — so completing is safe pre-deploy.\n *\n * **Use cases**\n *\n * - **Start working an item** — `{ \"status\": \"in_progress\" }`.\n * - **Hand off for review** — `{ \"status\": \"ready_for_qa\" }` once the fix landed (the mode PR-based loops use).\n * - **Triage** — `{ \"priority\": \"high\" }`, content edits on bug/feature items.\n */\nexport const updateOpsItem = <ThrowOnError extends boolean = false>(options: Options<UpdateOpsItemData, ThrowOnError>): RequestResult<UpdateOpsItemResponses, UpdateOpsItemErrors, ThrowOnError> => (options.client ?? client).patch<UpdateOpsItemResponses, UpdateOpsItemErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/ops/{handle}',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * Link a fixing PR\n *\n * Record the pull request that fixes a queue item (and clears the link with `prNumber: null`).\n *\n * **Use case:** Tie the fixing PR to the item so closing the PR can flip it to ready_for_qa.\n */\nexport const linkPrToOpsItem = <ThrowOnError extends boolean = false>(options: Options<LinkPrToOpsItemData, ThrowOnError>): RequestResult<LinkPrToOpsItemResponses, LinkPrToOpsItemErrors, ThrowOnError> => (options.client ?? client).post<LinkPrToOpsItemResponses, LinkPrToOpsItemErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/ops/{handle}/link-pr',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * Ack an item (start a run)\n *\n * Acknowledge a queue item — a person or an AI agent declaring \"I'm on this\n * now\". Opens a run: stamps who picked the item up and when, assigns them as\n * owner, and moves the item into the matching working status\n * (`investigating_by_ai` for an AI ack, `in_progress` for a human one). The\n * dashboard renders the open run as a live working indicator (which agent +\n * time since the run started).\n *\n * **AI ack.** Pass `agent` with your own agent type (`claude`, `cursor`,\n * `copilot`, `jules`; `gemini` aliases `jules`) and, when you have one, the\n * run's `sessionId` so the dashboard can deep-link to the session. If the\n * project has no connected trigger connector of that type the call fails\n * with `AGENT_NOT_CONNECTED` — list the available agents with `ops agents\n * list` and use one of those (or connect the agent under Settings →\n * Triggers).\n *\n * **Launching.** When the named agent has a connected trigger and you pass\n * no `sessionId`, the ack also fires that trigger — a new provider run\n * starts working the item. Pass `launch: false` to only claim the item and\n * record the run (you are doing the work yourself), without starting one.\n *\n * **Completion.** The run closes automatically on the loop's final actions —\n * linking the fixing PR (`link-pr`), an ops-notify escalation, or a\n * completion status change (`ready_for_qa`/`resolved`) — and the dashboard\n * then shows the run result (final action, PR, duration, session link).\n * A repeat ack supersedes the previous open run.\n *\n * **Use case:** Call this first when picking an item up, so the team sees\n * who/what is working on it in real time.\n */\nexport const ackOpsItem = <ThrowOnError extends boolean = false>(options: Options<AckOpsItemData, ThrowOnError>): RequestResult<AckOpsItemResponses, AckOpsItemErrors, ThrowOnError> => (options.client ?? client).post<AckOpsItemResponses, AckOpsItemErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/ops/{handle}/ack',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * List an item's investigation records\n *\n * The structured, read-only investigation records on a queue item — the\n * findings / blocking questions / QA notes an AI agent posted while working\n * it, plus its `working` run rows. Returns `published` records only, newest\n * first (max 50).\n *\n * **Use case:** Read what a previous agent run already found before starting\n * your own investigation of the item.\n */\nexport const listOpsInvestigations = <ThrowOnError extends boolean = false>(options: Options<ListOpsInvestigationsData, ThrowOnError>): RequestResult<ListOpsInvestigationsResponses, ListOpsInvestigationsErrors, ThrowOnError> => (options.client ?? client).get<ListOpsInvestigationsResponses, ListOpsInvestigationsErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/ops/{handle}/investigation',\n ...options\n});\n\n/**\n * Record an investigation\n *\n * Append one structured investigation record to a queue item — the AI-write\n * seam the cockpit's detail panel renders read-only. Post your findings\n * (`kind: investigated`), a blocking question for the team (`kind:\n * question`), or how to verify the fix (`kind: ready_for_qa` with\n * `qaNotes`). Append-only and create-only, so it is safe for restricted ops\n * keys. For a decision between options you can name, ask a structured\n * question instead (`ops questions ask`) — it is answerable in one tap and\n * the answer comes back to your run.\n *\n * **Use case:** After working an item, leave a findings write-up (summary,\n * markdown findings, sources inspected, confidence) so the team — and the\n * next agent run — sees what you learned.\n */\nexport const createOpsInvestigation = <ThrowOnError extends boolean = false>(options: Options<CreateOpsInvestigationData, ThrowOnError>): RequestResult<CreateOpsInvestigationResponses, CreateOpsInvestigationErrors, ThrowOnError> => (options.client ?? client).post<CreateOpsInvestigationResponses, CreateOpsInvestigationErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/ops/{handle}/investigation',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * Update an investigation record\n *\n * Update one existing investigation record in place — the write-back seam for\n * the `working` run record you were handed when a run was launched. Fill in\n * the `summary`/`findings`, attach the fixing PR, record your `confidence`\n * and the `sources` you inspected, or flip its `kind` off `working` once the\n * investigation is done. A partial patch: send only the fields you want to\n * change. Safe for restricted ops keys (it never reads or deletes).\n *\n * **Use case:** A run started with an empty `working` record; as you work,\n * PATCH it with your findings so the cockpit's detail panel fills in live —\n * no need to append a second record.\n */\nexport const updateOpsInvestigation = <ThrowOnError extends boolean = false>(options: Options<UpdateOpsInvestigationData, ThrowOnError>): RequestResult<UpdateOpsInvestigationResponses, UpdateOpsInvestigationErrors, ThrowOnError> => (options.client ?? client).patch<UpdateOpsInvestigationResponses, UpdateOpsInvestigationErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/ops/{handle}/investigation/{investigationId}',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * List an item's questions\n *\n * The structured questions asked on a queue item, with their answers —\n * newest first (max 100). Pull this to read the answers to questions you\n * asked: an answered question reads `status: completed` and carries\n * `answer.selected` (the option labels picked) and `answer.other` (the\n * free-text \"Other\" reply, or `null`).\n *\n * **Use case:** You asked with `delivery: poll` from a live session — poll\n * this until your questions read `completed`, then continue with the answers.\n */\nexport const listOpsQuestions = <ThrowOnError extends boolean = false>(options: Options<ListOpsQuestionsData, ThrowOnError>): RequestResult<ListOpsQuestionsResponses, ListOpsQuestionsErrors, ThrowOnError> => (options.client ?? client).get<ListOpsQuestionsResponses, ListOpsQuestionsErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/ops/{handle}/questions',\n ...options\n});\n\n/**\n * Ask the team questions about an item\n *\n * Ask 1–4 structured questions about a queue item — the way to get a\n * decision from a person when the implementation needs one. Each question\n * is the `AskUserQuestion` shape: a short `header` chip, the full\n * `question`, 2–4 `options` (`label` + `description`), and `multiSelect`\n * (checkboxes instead of radios). The person can always answer \"Other\" in\n * free text, so never add an \"Other\" option yourself. The questions render\n * at the very top of the item's detail panel and mark the row in the queue.\n *\n * **Delivery.** `resume` re-fires your trigger-connector run on the item\n * once every question it asked is answered, continuing the same run record\n * with the answers in the prompt — stop after asking. `poll` fires nothing;\n * poll `GET .../questions` instead. Omitted, it is `resume` when `runId`\n * names a run launched through a trigger connector, else `poll`.\n *\n * **Use case:** Blocked on a product decision (which behaviour to keep,\n * which of two fixes to ship) — ask instead of guessing, then wait for the\n * answer.\n */\nexport const askOpsQuestions = <ThrowOnError extends boolean = false>(options: Options<AskOpsQuestionsData, ThrowOnError>): RequestResult<AskOpsQuestionsResponses, AskOpsQuestionsErrors, ThrowOnError> => (options.client ?? client).post<AskOpsQuestionsResponses, AskOpsQuestionsErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/ops/{handle}/questions',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * Answer a question\n *\n * Answer one open question on a queue item — pick option labels in\n * `selected` (exactly one unless the question is `multiSelect`) and/or\n * write a free-text `other`. The question moves to `completed`. When it was\n * the last open question of a `resume` run, that agent is re-fired on the\n * item with every answer. A person's action: never allow-listed for\n * restricted ops keys.\n *\n * **Use case:** Unblock an agent from the CLI instead of the dashboard.\n */\nexport const answerOpsQuestion = <ThrowOnError extends boolean = false>(options: Options<AnswerOpsQuestionData, ThrowOnError>): RequestResult<AnswerOpsQuestionResponses, AnswerOpsQuestionErrors, ThrowOnError> => (options.client ?? client).post<AnswerOpsQuestionResponses, AnswerOpsQuestionErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/ops/{handle}/questions/{questionId}/answer',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * Withdraw a question\n *\n * Withdraw one open question you asked — it no longer needs an answer\n * (you found it out yourself, or the item moved on). The question moves to\n * `cancelled` and leaves the detail panel. Withdrawing the last open\n * question of a run delivers nothing.\n *\n * **Use case:** You asked, then answered it yourself from the code — take\n * it off the person's plate.\n */\nexport const cancelOpsQuestion = <ThrowOnError extends boolean = false>(options: Options<CancelOpsQuestionData, ThrowOnError>): RequestResult<CancelOpsQuestionResponses, CancelOpsQuestionErrors, ThrowOnError> => (options.client ?? client).post<CancelOpsQuestionResponses, CancelOpsQuestionErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/ops/{handle}/questions/{questionId}/cancel',\n ...options\n});\n\n/**\n * List an item's QA notes\n *\n * The typed QA notes on a queue item, newest first (max 200) — narrowing,\n * clarification, verification and correction notes, each with its author and\n * time. They are separate from the comment thread: read these to learn the\n * CURRENT QA state of a ticket (what remains failing, what \"fixed\" now means,\n * the last verification verdict) without parsing prose comments.\n *\n * **Use case:** A coding agent picks an item up and checks the latest\n * `verification` verdict and any `narrowing` note before touching the code.\n */\nexport const listOpsQaNotes = <ThrowOnError extends boolean = false>(options: Options<ListOpsQaNotesData, ThrowOnError>): RequestResult<ListOpsQaNotesResponses, ListOpsQaNotesErrors, ThrowOnError> => (options.client ?? client).get<ListOpsQaNotesResponses, ListOpsQaNotesErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/ops/{handle}/qa-notes',\n ...options\n});\n\n/**\n * Add a QA note to an item\n *\n * Append one typed QA note to a queue item. `kind` is `narrowing` (what now\n * passes vs what still fails), `clarification` (what \"fixed\" now means),\n * `verification` (requires a `verdict` of `pass` or `fail`, and `body` says\n * what was checked) or `correction` (withdraws an earlier framing). Notes\n * are append-only and appear in the item's QA notes section, not in the\n * comment thread. The author is the caller's identity; pass `agent` to\n * record the note as written by that agent type's QA automation. A `fail` verdict never changes the item's\n * status by itself: the dashboard offers an explicit \"Reopen item\" action,\n * and `ops update --status open` does the same from the CLI.\n *\n * **Use case:** QA automation records \"verified on production: FAIL, the\n * second facet still errors\" as data an agent can read back.\n */\nexport const createOpsQaNote = <ThrowOnError extends boolean = false>(options: Options<CreateOpsQaNoteData, ThrowOnError>): RequestResult<CreateOpsQaNoteResponses, CreateOpsQaNoteErrors, ThrowOnError> => (options.client ?? client).post<CreateOpsQaNoteResponses, CreateOpsQaNoteErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/ops/{handle}/qa-notes',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * List connected AI agents\n *\n * The project's connected AI agents — one per authenticated trigger\n * connector (Claude / Cursor / Copilot / Jules). These are the agent types\n * `ops ack` accepts and the agents a queue item can be assigned to.\n *\n * **Use case:** Discover which `agent` values an AI ack can use, e.g. after\n * an `AGENT_NOT_CONNECTED` error.\n */\nexport const listOpsAgents = <ThrowOnError extends boolean = false>(options?: Options<ListOpsAgentsData, ThrowOnError>): RequestResult<ListOpsAgentsResponses, ListOpsAgentsErrors, ThrowOnError> => (options?.client ?? client).get<ListOpsAgentsResponses, ListOpsAgentsErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/agent-profiles',\n ...options\n});\n\n/**\n * List an item's comments\n *\n * List the comment thread on a queue item, oldest first. Each comment\n * carries its author (a teammate email, or `system` for a comment authored by\n * Jarvis — the AI agent), its markdown body, and `parentId` for the single\n * level of threaded replies. Removed comments are omitted.\n *\n * **Use case:** Read the discussion on an item before replying or acting on it.\n */\nexport const listOpsComments = <ThrowOnError extends boolean = false>(options: Options<ListOpsCommentsData, ThrowOnError>): RequestResult<ListOpsCommentsResponses, ListOpsCommentsErrors, ThrowOnError> => (options.client ?? client).get<ListOpsCommentsResponses, ListOpsCommentsErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/ops/{handle}/comments',\n ...options\n});\n\n/**\n * Comment on an item\n *\n * Append a comment to a queue item's thread. The body is markdown (mentions\n * like `@teammate` notify that person; `@shipeasy` asks Jarvis, the AI agent,\n * to reply). Pass `parentId` to reply under an existing top-level comment\n * (one level of threading — a reply to a reply attaches to the same parent).\n *\n * Create-only and append-only, so it is safe for restricted ops keys — the\n * same channel the ops loop and Jarvis use to leave a note on an item.\n */\nexport const createOpsComment = <ThrowOnError extends boolean = false>(options: Options<CreateOpsCommentData, ThrowOnError>): RequestResult<CreateOpsCommentResponses, CreateOpsCommentErrors, ThrowOnError> => (options.client ?? client).post<CreateOpsCommentResponses, CreateOpsCommentErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/ops/{handle}/comments',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * Raise an attention notification\n *\n * Raise a 'needs your attention' bell notification. Create-only and idempotent on `dedupeKey` — re-raising with the same key updates the one card instead of stacking duplicates. It never reads, marks read, or deletes the feed, so it is safe for restricted ops keys.\n *\n * **Use case:** Escalate work that can't land in code (a product decision, a credential only a human has, a resource only a human may edit), deduped so repeats don't spam the bell.\n */\nexport const notifyOps = <ThrowOnError extends boolean = false>(options: Options<NotifyOpsData, ThrowOnError>): RequestResult<NotifyOpsResponses, NotifyOpsErrors, ThrowOnError> => (options.client ?? client).post<NotifyOpsResponses, NotifyOpsErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/notifications',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * List Slack channels\n *\n * List the project's connected Slack channels — used to resolve an alert rule's notification target.\n *\n * **Use case:** Populate a channel picker, or validate an alert rule's `--slack-channel` before saving.\n */\nexport const listSlackChannels = <ThrowOnError extends boolean = false>(options?: Options<ListSlackChannelsData, ThrowOnError>): RequestResult<ListSlackChannelsResponses, ListSlackChannelsErrors, ThrowOnError> => (options?.client ?? client).get<ListSlackChannelsResponses, ListSlackChannelsErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/slack/channels',\n ...options\n});\n\n/**\n * List alert rules\n *\n * Returns every alert rule in the project (not paginated). Each rule carries its bound `metricId`, the denormalised `metricName` (or `null` if the metric was removed), the comparator/threshold/window, severity, enabled flag, and delivery target.\n *\n * **Use case:** Audit which metrics have alerting configured — for example to confirm an on-call threshold is set before a launch.\n */\nexport const listAlertRules = <ThrowOnError extends boolean = false>(options?: Options<ListAlertRulesData, ThrowOnError>): RequestResult<ListAlertRulesResponses, ListAlertRulesErrors, ThrowOnError> => (options?.client ?? client).get<ListAlertRulesResponses, ListAlertRulesErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/alert-rules',\n ...options\n});\n\n/**\n * Create an alert rule\n *\n * Creates a metric-threshold alert rule. `name`, `metricId`, `comparator`, and `threshold` are required; `windowHours` defaults to `24`, `severity` to `warn`, and `enabled` to `true`.\n *\n * Returns `404` if `metricId` does not resolve, and `400` for a metric with no scalar form over a window (e.g. retention metrics) — the cron can't evaluate those.\n *\n * **Use cases**\n *\n * - **Threshold alert** — warn when an error/latency metric crosses a value over a rolling window.\n * - **Routed alert** — set `notify` to page a specific Slack channel or on-call email instead of the project default.\n */\nexport const createAlertRule = <ThrowOnError extends boolean = false>(options: Options<CreateAlertRuleData, ThrowOnError>): RequestResult<CreateAlertRuleResponses, CreateAlertRuleErrors, ThrowOnError> => (options.client ?? client).post<CreateAlertRuleResponses, CreateAlertRuleErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/alert-rules',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * Delete an alert rule\n *\n * Deletes the alert rule. The cron stops evaluating it immediately. Use this (then create a new rule) to repoint alerting at a different metric, since `metricId` is immutable.\n *\n * **Use case:** Remove an alert rule that is no longer needed, or as the first half of repointing a rule at a different metric.\n */\nexport const deleteAlertRule = <ThrowOnError extends boolean = false>(options: Options<DeleteAlertRuleData, ThrowOnError>): RequestResult<DeleteAlertRuleResponses, DeleteAlertRuleErrors, ThrowOnError> => (options.client ?? client).delete<DeleteAlertRuleResponses, DeleteAlertRuleErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/alert-rules/{id}',\n ...options\n});\n\n/**\n * Update an alert rule\n *\n * Partial update of a rule's tunable knobs. `metricId` is immutable — the metric also pins the aggregation, so a body carrying `metricId` is rejected with `409 IMMUTABLE_FIELD`; create a new rule bound to the other metric instead (rule deletion is dashboard-only).\n *\n * Pass `\"notify\": null` to revert the rule's delivery target back to the project default.\n *\n * **Use cases**\n *\n * - **Tune sensitivity** — change `threshold`/`comparator`/`windowHours` as the metric's baseline shifts.\n * - **Pause without losing config** — `{ \"enabled\": false }` instead of deleting the rule.\n */\nexport const updateAlertRule = <ThrowOnError extends boolean = false>(options: Options<UpdateAlertRuleData, ThrowOnError>): RequestResult<UpdateAlertRuleResponses, UpdateAlertRuleErrors, ThrowOnError> => (options.client ?? client).patch<UpdateAlertRuleResponses, UpdateAlertRuleErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/alert-rules/{id}',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * List fired alerts\n *\n * Returns the project's FIRED alerts as a **bare JSON array** (no pagination envelope), ordered by `createdAt desc`. Defaults to the currently-firing ones (`status=active`); pass a `status` to widen to resolved/dismissed history or `all`.\n *\n * A fired alert is an **instance** of an alert rule, and an instance IS its ops queue item — the same row `/api/admin/ops` returns with `type: \"alert\"`, viewed through the alert lens. One rule produces many instances over its life and at most one is open at a time: when the condition clears the instance closes, and the next firing is a NEW instance with its own id and history. That is why `severity` reads off the rule (the queue item carries it as `priority`) and why resolving the queue item and clearing the alert are one act, not two rows to keep in step.\n *\n * Instances are opened only by the platform — the UI's killswitch handlers plus the worker's analysis consumer and alerts cron — never filed by hand, so this surface is list + triage (via PATCH), with no create. The rules that *define* metric-threshold alerts live at `/api/admin/alert-rules`.\n *\n * **Use case:** Snapshot what is currently firing for an on-call view or the home Alerts block, or pull `status=all` to audit how a noisy rule has behaved over time.\n */\nexport const listAlerts = <ThrowOnError extends boolean = false>(options?: Options<ListAlertsData, ThrowOnError>): RequestResult<ListAlertsResponses, ListAlertsErrors, ThrowOnError> => (options?.client ?? client).get<ListAlertsResponses, ListAlertsErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/alerts',\n ...options\n});\n\n/**\n * Update a fired alert\n *\n * Triage writes on one fired alert — the only mutations this surface allows. All body fields are optional (at least one required); only the fields present are changed.\n *\n * - **`status`** — flip between `active` / `resolved` / `dismissed`. `resolved` and `dismissed` stamp `resolvedAt` / `dismissedAt`; `active` re-opens and clears both. These write the underlying queue item's own status (`resolved` / `wont_fix` / `open`), so clearing an alert here and resolving it in the ops queue are the same act. A cleared instance is never revived: if the condition fires again it opens a NEW instance with its own id.\n * - **`assigneeId`** — the PERSON owner (a `users.id`), or `null` to unassign.\n * - **`agent`** — the AGENT owner: a connected trigger connector's id, or the built-in `\"jarvis\"` (**Enterprise plan only** — `403` otherwise), or `null` to clear. Person and agent halves are independent.\n *\n * Returns the updated row; `404` if the alert does not exist in the project.\n *\n * **Use cases**\n *\n * - **Wave off a known condition** — `{ \"status\": \"dismissed\" }` on an alert that needs no action.\n * - **Hand it to someone** — `{ \"assigneeId\": \"…\" }` from the ops cockpit's Owner column.\n */\nexport const updateAlert = <ThrowOnError extends boolean = false>(options: Options<UpdateAlertData, ThrowOnError>): RequestResult<UpdateAlertResponses, UpdateAlertErrors, ThrowOnError> => (options.client ?? client).patch<UpdateAlertResponses, UpdateAlertErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/alerts/{id}',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * Show the current project\n *\n * Returns the project the caller's auth header resolves to — plan, status, billing, and which modules are enabled. The server reads the project from the credential, so there is no id parameter. Powers `whoami`.\n *\n * **Use case:** Resolve who you are — the project, plan, and enabled modules tied to the current credential — without passing an id. Backs a registry-driven `whoami`.\n */\nexport const getCurrentProject = <ThrowOnError extends boolean = false>(options?: Options<GetCurrentProjectData, ThrowOnError>): RequestResult<GetCurrentProjectResponses, GetCurrentProjectErrors, ThrowOnError> => (options?.client ?? client).get<GetCurrentProjectResponses, GetCurrentProjectErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/projects/current',\n ...options\n});\n\n/**\n * Find-or-create a project by domain\n *\n * Find-or-creates a project keyed by `(owner_email, domain)` under the session's owner, and returns it. Idempotent: a second call with the same domain returns the existing project with `created: false`.\n *\n * Only `domain` is required — `name` defaults to the domain on first create. Recording the result in a local `.shipeasy` binding is a consumer side-effect; this endpoint never performs it.\n *\n * **Use cases**\n *\n * - **Install flow** — provision a per-app project without a trip to the dashboard. Run it on every install; the idempotent key means a re-run returns the existing project rather than duplicating it.\n * - **Name explicitly** — pass `name` to label the project distinctly from its `domain`.\n */\nexport const upsertProject = <ThrowOnError extends boolean = false>(options: Options<UpsertProjectData, ThrowOnError>): RequestResult<UpsertProjectResponses, UpsertProjectErrors, ThrowOnError> => (options.client ?? client).post<UpsertProjectResponses, UpsertProjectErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/projects/upsert',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * Show a project by id\n *\n * Returns one project by id — the same full shape as `GET /api/admin/projects/current`. The id in the path must match the project the caller's credential resolves to (a credential can only read its own project); any other id is a 403.\n *\n * **Use case:** Re-fetch the project row after a `PATCH` when you already hold its id.\n */\nexport const getProject = <ThrowOnError extends boolean = false>(options: Options<GetProjectData, ThrowOnError>): RequestResult<GetProjectResponses, GetProjectErrors, ThrowOnError> => (options.client ?? client).get<GetProjectResponses, GetProjectErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/projects/{id}',\n ...options\n});\n\n/**\n * Update the current project\n *\n * Update the current project's settings — name, domain, slug, default environment, timezone, experiment-analysis knobs (statistical method, significance threshold, auto-rollback, minimum sample days), and the per-module enable flags. Partial: only the fields you send change.\n *\n * The project id in the path must match the project the caller's credential resolves to (a credential can only edit its own project). Changing `domain` re-stamps the allowed origin into every live SDK key.\n *\n * **Use case:** Rename a project, move its domain, toggle a module on/off, or tune the experiment-analysis defaults without leaving the CLI.\n */\nexport const updateProject = <ThrowOnError extends boolean = false>(options: Options<UpdateProjectData, ThrowOnError>): RequestResult<UpdateProjectResponses, UpdateProjectErrors, ThrowOnError> => (options.client ?? client).patch<UpdateProjectResponses, UpdateProjectErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/projects/{id}',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * List i18n profiles\n *\n * Returns every locale profile in the project (e.g. `en:prod`, `fr:prod`).\n *\n * **Use case:** Discover which locale profiles exist before pushing keys or publishing.\n */\nexport const listI18nProfiles = <ThrowOnError extends boolean = false>(options?: Options<ListI18nProfilesData, ThrowOnError>): RequestResult<ListI18nProfilesResponses, ListI18nProfilesErrors, ThrowOnError> => (options?.client ?? client).get<ListI18nProfilesResponses, ListI18nProfilesErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/i18n/profiles',\n ...options\n});\n\n/**\n * Create an i18n profile\n *\n * Create a locale profile. `name` is the stable handle (e.g. `fr:prod`).\n *\n * **Use case:** Stand up a new locale before seeding its keys.\n */\nexport const createI18nProfile = <ThrowOnError extends boolean = false>(options: Options<CreateI18nProfileData, ThrowOnError>): RequestResult<CreateI18nProfileResponses, CreateI18nProfileErrors, ThrowOnError> => (options.client ?? client).post<CreateI18nProfileResponses, CreateI18nProfileErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/i18n/profiles',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * List i18n keys\n *\n * List keys for a profile, optionally filtered to a name `prefix`.\n *\n * **Use case:** Read the current keys (and values) for a profile — e.g. to diff before a push.\n */\nexport const listI18nKeys = <ThrowOnError extends boolean = false>(options?: Options<ListI18nKeysData, ThrowOnError>): RequestResult<ListI18nKeysResponses, ListI18nKeysErrors, ThrowOnError> => (options?.client ?? client).get<ListI18nKeysResponses, ListI18nKeysErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/i18n/keys',\n ...options\n});\n\n/**\n * Push i18n keys (insert-only, or `force` to overwrite)\n *\n * Add NEW keys to a profile. Insert-only by default — existing keys are left untouched and reported back as `skipped`.\n *\n * Pass `force: true` to overwrite the existing ones in bulk with the submitted values: they come back as `updated` instead of `skipped`. Without `force` the only overwrite paths are `updateI18nKey` (one key) and the devtools-only `upsertI18nKeys`.\n *\n * **Use case:** Seed newly-extracted keys without clobbering translations already in the profile — or re-push a whole source-language file with `force` after the copy changed.\n */\nexport const pushI18nKeys = <ThrowOnError extends boolean = false>(options: Options<PushI18nKeysData, ThrowOnError>): RequestResult<PushI18nKeysResponses, PushI18nKeysErrors, ThrowOnError> => (options.client ?? client).post<PushI18nKeysResponses, PushI18nKeysErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/i18n/keys',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * Bulk upsert i18n keys (overwrite)\n *\n * Bulk upsert keys into a profile — existing keys ARE overwritten, new ones inserted. The profile's KV snapshot is rebuilt and the CDN purged before the call returns, so the edits go live on their own.\n *\n * This is the overwrite counterpart of the insert-only `pushI18nKeys`. It backs the devtools overlay's in-product \"Apply changes\" label editing and is deliberately not surfaced by the CLI or MCP — those surfaces only expose the insert-only push so a whole `en.json` can't wholesale-overwrite prod.\n *\n * **Use case:** Apply a batch of in-product label edits (devtools overlay) in one call.\n */\nexport const upsertI18nKeys = <ThrowOnError extends boolean = false>(options: Options<UpsertI18nKeysData, ThrowOnError>): RequestResult<UpsertI18nKeysResponses, UpsertI18nKeysErrors, ThrowOnError> => (options.client ?? client).put<UpsertI18nKeysResponses, UpsertI18nKeysErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/i18n/keys',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * Delete one i18n key\n *\n * Permanently delete a single key from its profile. The profile's KV snapshot is rebuilt and the CDN purged as part of this call, so the removal goes live on its own.\n *\n * **Use case:** Remove a stale or mistakenly-pushed key without touching the rest of the profile.\n */\nexport const deleteI18nKey = <ThrowOnError extends boolean = false>(options: Options<DeleteI18nKeyData, ThrowOnError>): RequestResult<DeleteI18nKeyResponses, DeleteI18nKeyErrors, ThrowOnError> => (options.client ?? client).delete<DeleteI18nKeyResponses, DeleteI18nKeyErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/i18n/keys/{id}',\n ...options\n});\n\n/**\n * Update one i18n key\n *\n * Overwrite a single existing key's value — the only overwrite path.\n *\n * The change goes live on its own: the profile's KV snapshot is rebuilt and the CDN purged as part of this call, so no separate profile publish is needed.\n *\n * **Use case:** Correct or re-translate a single string in place.\n */\nexport const updateI18nKey = <ThrowOnError extends boolean = false>(options: Options<UpdateI18nKeyData, ThrowOnError>): RequestResult<UpdateI18nKeyResponses, UpdateI18nKeyErrors, ThrowOnError> => (options.client ?? client).put<UpdateI18nKeyResponses, UpdateI18nKeyErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/i18n/keys/{id}',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * List translation drafts\n *\n * List staged translation drafts awaiting review/publish.\n *\n * **Use case:** Review machine-translation drafts before publishing them to a locale.\n */\nexport const listI18nDrafts = <ThrowOnError extends boolean = false>(options?: Options<ListI18nDraftsData, ThrowOnError>): RequestResult<ListI18nDraftsResponses, ListI18nDraftsErrors, ThrowOnError> => (options?.client ?? client).get<ListI18nDraftsResponses, ListI18nDraftsErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/i18n/drafts',\n ...options\n});\n\n/**\n * Create a translation draft\n *\n * Stage a new translation draft against a target profile, optionally seeding its keys from a source profile.\n *\n * **Use case:** Open a machine-translation draft for review before publishing it to a locale.\n */\nexport const createI18nDraft = <ThrowOnError extends boolean = false>(options: Options<CreateI18nDraftData, ThrowOnError>): RequestResult<CreateI18nDraftResponses, CreateI18nDraftErrors, ThrowOnError> => (options.client ?? client).post<CreateI18nDraftResponses, CreateI18nDraftErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/i18n/drafts',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * Delete a translation draft\n *\n * Permanently delete a staged translation draft. Its staged keys are removed with it; the target profile's live keys are untouched.\n *\n * **Use case:** Discard a draft that will never ship instead of leaving it abandoned.\n */\nexport const deleteI18nDraft = <ThrowOnError extends boolean = false>(options: Options<DeleteI18nDraftData, ThrowOnError>): RequestResult<DeleteI18nDraftResponses, DeleteI18nDraftErrors, ThrowOnError> => (options.client ?? client).delete<DeleteI18nDraftResponses, DeleteI18nDraftErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/i18n/drafts/{draftId}',\n ...options\n});\n\n/**\n * Update a translation draft\n *\n * Transition a draft's lifecycle state (`open` / `merged` / `abandoned`).\n *\n * **Use case:** Mark a reviewed draft as merged, or abandon one that should not ship.\n */\nexport const updateI18nDraft = <ThrowOnError extends boolean = false>(options: Options<UpdateI18nDraftData, ThrowOnError>): RequestResult<UpdateI18nDraftResponses, UpdateI18nDraftErrors, ThrowOnError> => (options.client ?? client).patch<UpdateI18nDraftResponses, UpdateI18nDraftErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/i18n/drafts/{draftId}',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * Delete an i18n profile\n *\n * Soft-delete a locale profile. The project's default profile cannot be deleted (409). The profile's keys are retained in the database but the profile no longer resolves for listing or publishing.\n *\n * **Use case:** Retire a locale that is no longer shipped.\n */\nexport const deleteI18nProfile = <ThrowOnError extends boolean = false>(options: Options<DeleteI18nProfileData, ThrowOnError>): RequestResult<DeleteI18nProfileResponses, DeleteI18nProfileErrors, ThrowOnError> => (options.client ?? client).delete<DeleteI18nProfileResponses, DeleteI18nProfileErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/i18n/profiles/{profileId}',\n ...options\n});\n\n/**\n * List a draft's staged keys\n *\n * Returns every staged key in a translation draft — the values queued to ship when the draft is merged.\n *\n * **Use case:** Review a machine-translation draft's staged strings before marking it merged.\n */\nexport const listI18nDraftKeys = <ThrowOnError extends boolean = false>(options: Options<ListI18nDraftKeysData, ThrowOnError>): RequestResult<ListI18nDraftKeysResponses, ListI18nDraftKeysErrors, ThrowOnError> => (options.client ?? client).get<ListI18nDraftKeysResponses, ListI18nDraftKeysErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/i18n/drafts/{draftId}/keys',\n ...options\n});\n\n/**\n * Upsert one staged draft key\n *\n * Upsert a single staged key into an **open** draft — inserted when new, overwritten when it already exists. A draft that is `merged` or `abandoned` rejects the write (400). `{{var}}` placeholder names are auto-derived from the value.\n *\n * **Use case:** Stage or correct one translation in a draft under review without touching the live profile.\n */\nexport const upsertI18nDraftKey = <ThrowOnError extends boolean = false>(options: Options<UpsertI18nDraftKeyData, ThrowOnError>): RequestResult<UpsertI18nDraftKeyResponses, UpsertI18nDraftKeyErrors, ThrowOnError> => (options.client ?? client).post<UpsertI18nDraftKeyResponses, UpsertI18nDraftKeyErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/i18n/drafts/{draftId}/keys',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * Publish a profile live\n *\n * Publish a profile to the CDN — rebuild its KV snapshot + purge the edge. Publishing is PROFILE-WIDE: the whole profile is snapshotted into one KV blob, so the body takes no options.\n *\n * **Use case:** Ship the latest translations live after pushing/updating keys.\n */\nexport const publishI18nProfile = <ThrowOnError extends boolean = false>(options: Options<PublishI18nProfileData, ThrowOnError>): RequestResult<PublishI18nProfileResponses, PublishI18nProfileErrors, ThrowOnError> => (options.client ?? client).post<PublishI18nProfileResponses, PublishI18nProfileErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/i18n/profiles/{profileId}/publish',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * Set a key's value and publish it live\n *\n * Upsert a single key's value into a profile and immediately publish the whole profile (KV rebuild + CDN purge) so the new value is live in one call. The key is inserted when new and overwritten when it already exists. `profile` is a profile name — omit it to target the project's default-marked profile, or pass a name to target another locale.\n *\n * **Use case:** Correct or replace one live string and ship it without a separate `push` + `publish`.\n */\nexport const setI18nLabel = <ThrowOnError extends boolean = false>(options: Options<SetI18nLabelData, ThrowOnError>): RequestResult<SetI18nLabelResponses, SetI18nLabelErrors, ThrowOnError> => (options.client ?? client).post<SetI18nLabelResponses, SetI18nLabelErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/i18n/set',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * List tracked errors\n *\n * Returns a single page of tracked production errors as a **bare JSON array** (no pagination envelope), ordered by `lastSeenAt desc`. Filter with `status`, free-text-search with `q`, and cap the page with `limit`.\n *\n * Tracked errors are never filed by hand — an ingestion path (worker log drain / the `see()` SDK reporter) folds each occurrence into a row keyed by `fingerprint`, bumping `count` and `lastSeenAt`. This surface only reads them and (via PATCH) flips their `status`.\n *\n * **Use case:** Snapshot the project's open issues for a triage dashboard, or drive a CI gate that fails the build when any `open` error of `kind: uncaught` exists in `prod`.\n */\nexport const listErrors = <ThrowOnError extends boolean = false>(options?: Options<ListErrorsData, ThrowOnError>): RequestResult<ListErrorsResponses, ListErrorsErrors, ThrowOnError> => (options?.client ?? client).get<ListErrorsResponses, ListErrorsErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/errors',\n ...options\n});\n\n/**\n * Get a tracked error\n *\n * Returns a single tracked error by its id, including the latest occurrence's stack, extras, and consequence, plus `occurrences` — the sampled per-instance detail rows behind the issue (newest first; exhaustive while the issue is small, thinned at volume, capped at 100). Returns `404` if no such error exists in the project.\n *\n * **Use case:** Drill into one issue — fetch its full stack and `seenUrls` to investigate, or walk `occurrences` to see how the failing message/stack varies across instances.\n */\nexport const getError = <ThrowOnError extends boolean = false>(options: Options<GetErrorData, ThrowOnError>): RequestResult<GetErrorResponses, GetErrorErrors, ThrowOnError> => (options.client ?? client).get<GetErrorResponses, GetErrorErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/errors/{id}',\n ...options\n});\n\n/**\n * Update a tracked error's status\n *\n * Flips the triage state of one error — the only mutation this surface allows. Valid transitions are between `open`, `resolved`, and `ignored`; the body must carry exactly `{ \"status\": … }`.\n *\n * A `resolved` error reopens automatically (ingestion-side) if it recurs; `ignored` is sticky until flipped back here. Returns the updated row.\n *\n * **Use cases**\n *\n * - **Triage** — `{ \"status\": \"ignored\" }` to suppress a known-benign issue from the open list.\n * - **Close out** — `{ \"status\": \"resolved\" }` once the fix lands; it reopens on its own if the error recurs.\n */\nexport const updateErrorStatus = <ThrowOnError extends boolean = false>(options: Options<UpdateErrorStatusData, ThrowOnError>): RequestResult<UpdateErrorStatusResponses, UpdateErrorStatusErrors, ThrowOnError> => (options.client ?? client).patch<UpdateErrorStatusResponses, UpdateErrorStatusErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/errors/{id}',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * File a feedback ticket for an error\n *\n * Files a feedback ticket (`type: \"error\"`) for a tracked production error — the \"File an issue\" action on the errors dashboard. The ticket carries the error's fingerprint as its `sourceRef` so it dedupes against, and joins back to, the tracked error. Takes no body.\n *\n * Idempotent: if an open `error` ticket already tracks this fingerprint (hand- or auto-filed), that existing ticket is returned instead of creating a duplicate. Returns `404` if the error does not exist.\n *\n * **Use case:** Promote a noisy tracked error into an actionable ticket in the ops queue (the same item the worker auto-files once an error crosses its occurrence threshold), so it can be triaged, assigned, and burned down via the `shipeasy-ops-work` skill.\n */\nexport const fileErrorTicket = <ThrowOnError extends boolean = false>(options: Options<FileErrorTicketData, ThrowOnError>): RequestResult<FileErrorTicketResponses, FileErrorTicketErrors, ThrowOnError> => (options.client ?? client).post<FileErrorTicketResponses, FileErrorTicketErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/errors/{id}/file',\n ...options\n});\n\n/**\n * Resolve a tracked error\n *\n * Marks one tracked error `resolved` — the single-purpose \"close out\" action. Takes no body; it is `PATCH /api/admin/errors/{id}` pinned to `{ \"status\": \"resolved\" }`, exposed so tooling can close an error without being handed the full open/resolved/ignored status machine. A resolved error reopens automatically (ingestion-side) if it recurs, so resolving is always safe: a premature resolve un-does itself on the next occurrence. Returns the updated row; `404` if the error does not exist.\n *\n * **Use case:** Close out a tracked error from an agent or script once its fix has shipped — e.g. after a deploy, resolve every open issue the change addressed and let recurrence reopen anything that wasn't actually fixed.\n */\nexport const resolveError = <ThrowOnError extends boolean = false>(options: Options<ResolveErrorData, ThrowOnError>): RequestResult<ResolveErrorResponses, ResolveErrorErrors, ThrowOnError> => (options.client ?? client).post<ResolveErrorResponses, ResolveErrorErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/errors/{id}/resolve',\n ...options\n});\n\n/**\n * Get an error's occurrence series\n *\n * Returns a bucketed occurrence timeseries for one tracked error (by its fingerprint), read from the `shipeasy_errors` Analytics Engine dataset (near-real-time; ingest lag is seconds). The window bounds are epoch **seconds**; `to` must be strictly greater than `from`. The response echoes the SQL that produced the rows.\n *\n * **Use case:** Render the trend sparkline / occurrence chart on the error detail panel, or pull the raw bucketed counts to alert when an issue's rate spikes.\n */\nexport const getErrorSeries = <ThrowOnError extends boolean = false>(options: Options<GetErrorSeriesData, ThrowOnError>): RequestResult<GetErrorSeriesResponses, GetErrorSeriesErrors, ThrowOnError> => (options.client ?? client).post<GetErrorSeriesResponses, GetErrorSeriesErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/errors/{id}/series',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * List connectors\n *\n * Returns every connector in the project as a bare array (no pagination envelope).\n *\n * The encrypted credentials backing each connector are never serialised — only the connector's non-secret `config`, `accountLabel`, and last-attempt health (`lastError`, `lastAttemptAt`, `lastSuccessAt`) are returned.\n *\n * **Use case:** Render the integrations/triggers settings page, or drive a CI check that asserts every `github` connector is `enabled` and last dispatched without error.\n */\nexport const listConnectors = <ThrowOnError extends boolean = false>(options?: Options<ListConnectorsData, ThrowOnError>): RequestResult<ListConnectorsResponses, ListConnectorsErrors, ThrowOnError> => (options?.client ?? client).get<ListConnectorsResponses, ListConnectorsErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/connectors',\n ...options\n});\n\n/**\n * Create a connector\n *\n * Creates a connector. The request body is discriminated on `provider`.\n *\n * - **OAuth/app providers** (`google_sheets`, `github`, `slack`) — supply `{ provider, name, events }`. The connector is created `enabled: false` with empty `config` and no credentials; the provider's OAuth flow then attaches credentials and enables it.\n * - **Trigger providers** (`claude_trigger`, `cursor_trigger`, `copilot_trigger`, `jules_trigger`) — supply `config` plus the provider's credential field(s) and the connector is fireable immediately. Trigger creates are **idempotent** by their natural key (`config.routineId` / `config.repoUrl` / `config.owner`+`config.repo` / `config.source`): re-creating updates the existing row rather than duplicating it.\n *\n * **Use cases**\n *\n * - **File bugs as GitHub Issues** — `{ \"provider\": \"github\", \"name\": \"Bugs → acme/app\", \"events\": [\"bug.created\"] }`, then finish the GitHub App install.\n * - **Nightly ops sweep** — register a `claude_trigger` with its `routineId` and (optionally) a fire `token`; subscribe `events` later to auto-fire on new bugs.\n * - **Cold cloud-agent run** — register a `cursor_trigger`/`jules_trigger` with the repo coordinates plus both keys, or a `copilot_trigger` with the repo + user PAT.\n */\nexport const createConnector = <ThrowOnError extends boolean = false>(options: Options<CreateConnectorData, ThrowOnError>): RequestResult<CreateConnectorResponses, CreateConnectorErrors, ThrowOnError> => (options.client ?? client).post<CreateConnectorResponses, CreateConnectorErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/connectors',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * Delete a connector\n *\n * Permanently removes the connector and its stored credentials.\n *\n * **Use case:** Disconnect an integration for good — e.g. tear down a `github` connector after migrating bug routing elsewhere.\n */\nexport const deleteConnector = <ThrowOnError extends boolean = false>(options: Options<DeleteConnectorData, ThrowOnError>): RequestResult<DeleteConnectorResponses, DeleteConnectorErrors, ThrowOnError> => (options.client ?? client).delete<DeleteConnectorResponses, DeleteConnectorErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/connectors/{id}',\n ...options\n});\n\n/**\n * Get a connector\n *\n * Returns a single connector by id. The encrypted credentials are never serialised.\n *\n * **Use case:** Inspect one connector's health — its `enabled` state, subscribed `events`, and last-attempt outcome (`lastError`/`lastSuccessAt`).\n */\nexport const getConnector = <ThrowOnError extends boolean = false>(options: Options<GetConnectorData, ThrowOnError>): RequestResult<GetConnectorResponses, GetConnectorErrors, ThrowOnError> => (options.client ?? client).get<GetConnectorResponses, GetConnectorErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/connectors/{id}',\n ...options\n});\n\n/**\n * Update a connector\n *\n * Partial update — only supplied fields change. `events` and `config` **replace** wholesale; there is no merge or append. Secrets cannot be set through this endpoint (credential rotation goes through the provider-specific re-register flow).\n *\n * The response carries only `{ id }` — re-fetch via `GET /api/admin/connectors/{id}` for the new row.\n *\n * **Use cases**\n *\n * - **Pause a connector** — `{ \"enabled\": false }`. Stops all dispatch / auto-fire without deleting it.\n * - **Change subscribed events** — send the full new `events` array. An empty array unsubscribes the connector from every event.\n * - **Rename** — `{ \"name\": \"Bugs → acme/app issues\" }`.\n * - **Retarget** — send a new `config` (e.g. a different Sheets `sheetTitle`); it replaces the stored config wholesale.\n */\nexport const updateConnector = <ThrowOnError extends boolean = false>(options: Options<UpdateConnectorData, ThrowOnError>): RequestResult<UpdateConnectorResponses, UpdateConnectorErrors, ThrowOnError> => (options.client ?? client).patch<UpdateConnectorResponses, UpdateConnectorErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/connectors/{id}',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * Fire a trigger connector\n *\n * Manually kicks a trigger connector's run — Claude (kicks its preconfigured routine) or Cursor / Copilot / Jules (launches a cold cloud-agent run). Firing is event-less: it kicks the run with an optional caller-supplied prompt override rather than dispatching a single lifecycle payload.\n *\n * Only trigger providers can be fired, and only once authenticated (a tokenless trigger cannot fire). The attempt's outcome is recorded on the connector's `lastAttemptAt` / `lastError` / `lastSuccessAt`.\n *\n * **Use case:** Kick a one-off ops sweep on demand from the dashboard's \"Fire now\" button, optionally overriding the routine's default prompt.\n */\nexport const fireConnector = <ThrowOnError extends boolean = false>(options: Options<FireConnectorData, ThrowOnError>): RequestResult<FireConnectorResponses, FireConnectorErrors, ThrowOnError> => (options.client ?? client).post<FireConnectorResponses, FireConnectorErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/connectors/{id}/fire',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * Test a connector\n *\n * Dispatches a single synthetic `bug.created` payload to the connector's destination so you can verify the integration end-to-end. Unlike `fire`, this runs the real dispatch path (posts a Slack message / appends a Sheets row / files a GitHub Issue) with throwaway test content. The attempt's outcome is recorded on the connector's `lastAttemptAt` / `lastError` / `lastSuccessAt`.\n *\n * When the provider produces a linkable artifact (e.g. a GitHub Issue), its URL is returned as `issueUrl`; otherwise `issueUrl` is `null`.\n *\n * **Use case:** Click \"Send test\" after wiring up a connector to confirm credentials and config are correct before relying on it for real events.\n */\nexport const testConnector = <ThrowOnError extends boolean = false>(options: Options<TestConnectorData, ThrowOnError>): RequestResult<TestConnectorResponses, TestConnectorErrors, ThrowOnError> => (options.client ?? client).post<TestConnectorResponses, TestConnectorErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/connectors/{id}/test',\n ...options\n});\n\n/**\n * Update a trigger connector\n *\n * Edit an existing coding-agent **trigger** connector (`claude_trigger` / `cursor_trigger` / `copilot_trigger` / `jules_trigger`) — replace its non-secret `config` and, optionally, rotate its credential secret(s). Discriminated on `provider`; the id in the path selects the connector and its `provider` must match the body.\n *\n * Unlike the generic `PATCH /api/admin/connectors/{id}` (which cannot touch secrets), this endpoint always replaces the non-secret `config` wholesale and merges any supplied secret over the stored credential cipher — so a single half of a two-key pair (e.g. just the ops key) can be rotated on its own. A blank/omitted secret leaves the stored cipher untouched.\n *\n * The response carries only `{ id }` — re-fetch via `GET /api/admin/connectors/{id}` for the new row.\n *\n * **Use case:** Re-point a Cursor trigger at a new repo ref, or rotate a Claude trigger's fire token, without deleting and re-creating the connector.\n */\nexport const updateTriggerConnector = <ThrowOnError extends boolean = false>(options: Options<UpdateTriggerConnectorData, ThrowOnError>): RequestResult<UpdateTriggerConnectorResponses, UpdateTriggerConnectorErrors, ThrowOnError> => (options.client ?? client).patch<UpdateTriggerConnectorResponses, UpdateTriggerConnectorErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/connectors/{id}/trigger',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * Create a recurring coding-agent trigger\n *\n * Creates (or idempotently updates) a coding-agent **trigger** connector — the recurring, unattended run that burns down the ops queue in `--pr` mode. Discriminated on `provider`; only the four Shipeasy-fireable providers are accepted (`claude_trigger`, `cursor_trigger`, `copilot_trigger`, `jules_trigger`). Config + credential(s) arrive together; creates are idempotent by the provider's natural key, so re-creating updates the existing row.\n *\n * Platforms without a fire endpoint (Codex, Windsurf, Cline, OpenClaw, OpenCode, Continue) cannot be created here — they are scheduled on their own platform (typically a GitHub Actions `schedule:` cron running the platform's headless CLI with the trigger prompt).\n *\n * **Use cases**\n *\n * - **Register a Claude routine** — after `RemoteTrigger {action:\"create\"}` returns `trig_…`, `{ \"provider\": \"claude_trigger\", \"config\": { \"routineId\": \"trig_…\" } }` (tokenless is fine; add the fire token later).\n * - **Cold Cursor/Jules run** — repo coordinates + both keys; Shipeasy launches the run and the PR opens via the provider's GitHub App.\n * - **Copilot cloud agent** — repo + a Copilot-licensed user PAT with the \"Agent tasks\" permission.\n */\nexport const createTriggerConnector = <ThrowOnError extends boolean = false>(options: Options<CreateTriggerConnectorData, ThrowOnError>): RequestResult<CreateTriggerConnectorResponses, CreateTriggerConnectorErrors, ThrowOnError> => (options.client ?? client).post<CreateTriggerConnectorResponses, CreateTriggerConnectorErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/connectors/trigger',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * List API keys\n *\n * Returns a single page of the project's API keys ordered by `created_at desc, id desc`, in the standard `{ data, next_cursor }` envelope. Use the `cursor` query parameter to paginate.\n *\n * Response fields are **snake_case** (`created_at`, `revoked_at`, `created_by_email`, `last4`). The raw token is never returned — only its `last4` tail, so a held key can be matched against the masked row. Revoked keys are included (with a non-null `revoked_at`).\n *\n * **Use case:** Audit which keys exist for a project — surface stale or never-expiring keys, or drive a CI check that asserts no `client` key is still active in `prod` after a rotation.\n */\nexport const listKeys = <ThrowOnError extends boolean = false>(options?: Options<ListKeysData, ThrowOnError>): RequestResult<ListKeysResponses, ListKeysErrors, ThrowOnError> => (options?.client ?? client).get<ListKeysResponses, ListKeysErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/keys',\n ...options\n});\n\n/**\n * Create an API key\n *\n * Mints a new API key and returns the plaintext token **once** — it is stored hashed and can never be retrieved again, so capture it on creation.\n *\n * Only `type` is required. `env` is **required** for `server` and `client` keys (the key is bound to one environment, which is the read-env isolation boundary); for `admin` and `ops` keys `env` is ignored and the key is pinned to `prod`. Expiry is fixed for some types: `admin` keys always get a 90-day expiry and `ops` keys a short sliding window, regardless of `expiresInDays`. Only `server`/`client` keys count toward the plan key limit.\n *\n * **Use cases**\n *\n * - **Back-end key** — `{ \"type\": \"server\", \"env\": \"prod\" }` for the production server SDK.\n * - **Public browser key** — `{ \"type\": \"client\", \"env\": \"prod\", \"name\": \"marketing site\" }` to embed in the browser SDK.\n * - **Scoped, expiring key** — `{ \"type\": \"server\", \"env\": \"staging\", \"scopes\": [\"gates:evaluate\"], \"expiresInDays\": 30 }` for a time-boxed integration.\n */\nexport const createKey = <ThrowOnError extends boolean = false>(options: Options<CreateKeyData, ThrowOnError>): RequestResult<CreateKeyResponses, CreateKeyErrors, ThrowOnError> => (options.client ?? client).post<CreateKeyResponses, CreateKeyErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/keys',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * Update an API key's label\n *\n * Renames a key or re-notes what it is for. **Only `name` and `description` are editable** — everything that gives the key its authority (`type`, `env`, `scopes`, `expires_at`) is fixed at mint, because the worker derives the read env and permissions from the key itself. To change any of those, rotate: mint a replacement and revoke this one.\n *\n * Omitted fields are left untouched; send `null` to clear one. Returns the updated key row. Revoked keys can still be relabelled (the audit trail outlives the credential). Returns `404` if no such key exists in the project.\n *\n * **Use case:** A key minted by `shipeasy setup` carries an auto-composed provenance label — rename it to the service that actually holds it and note the rotation owner.\n */\nexport const updateKey = <ThrowOnError extends boolean = false>(options: Options<UpdateKeyData, ThrowOnError>): RequestResult<UpdateKeyResponses, UpdateKeyErrors, ThrowOnError> => (options.client ?? client).patch<UpdateKeyResponses, UpdateKeyErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/keys/{id}',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * Revoke an API key\n *\n * Revokes a key by id — stamps its `revoked_at` and deletes the hot-path KV entry so the token stops authenticating immediately. Takes no body.\n *\n * Idempotent: revoking an already-revoked key is a no-op and returns the same `{ id, revoked: true }`. Returns `404` if no such key exists in the project.\n *\n * **Use case:** Rotate a leaked or stale credential — mint the replacement, then revoke the old key.\n */\nexport const revokeKey = <ThrowOnError extends boolean = false>(options: Options<RevokeKeyData, ThrowOnError>): RequestResult<RevokeKeyResponses, RevokeKeyErrors, ThrowOnError> => (options.client ?? client).post<RevokeKeyResponses, RevokeKeyErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/keys/{id}/revoke',\n ...options\n});\n\n/**\n * Search project resources\n *\n * Universal substring search across the project's primary resources — feature gates, experiments, dynamic configs, killswitches, metrics, and team members. Matches the trimmed `q` against each resource's immutable `name` and its human title/display name (members match on display name or email), newest-first, capped per resource family so one noisy type can't crowd out the rest.\n *\n * Returns a flat, ranked-by-type list of hits (members first); an empty or whitespace-only `q` returns no hits. Each hit carries a project-relative `href` that deep-links to the row.\n *\n * **Use case:** Back a command-palette / quick-switcher in the dashboard, or look up the id of a resource by a fragment of its name before driving another API call.\n */\nexport const searchResources = <ThrowOnError extends boolean = false>(options?: Options<SearchResourcesData, ThrowOnError>): RequestResult<SearchResourcesResponses, SearchResourcesErrors, ThrowOnError> => (options?.client ?? client).get<SearchResourcesResponses, SearchResourcesErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/search',\n ...options\n});\n\n/**\n * List the project's tags\n *\n * Returns every tag in the project — the shared roster any item (queue items, flags, configs, kill switches, metrics, tracked errors, alert rules, experiments) can carry. Sorted by name.\n *\n * **Use case:** See which tags already exist before tagging an item, so you reuse `ios` instead of minting `iOS-app`.\n */\nexport const listTags = <ThrowOnError extends boolean = false>(options?: Options<ListTagsData, ThrowOnError>): RequestResult<ListTagsResponses, ListTagsErrors, ThrowOnError> => (options?.client ?? client).get<ListTagsResponses, ListTagsErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/tags',\n ...options\n});\n\n/**\n * Read an item's tags\n *\n * Returns the tags attached to one item. The item is addressed by kind (`entityType`) plus its handle, so the same call reads tags off a queue item, a flag, a config, a kill switch, a metric, a tracked error, an alert rule, or an experiment.\n *\n * **Use case:** Check an item's current tags before editing them.\n */\nexport const getEntityTags = <ThrowOnError extends boolean = false>(options: Options<GetEntityTagsData, ThrowOnError>): RequestResult<GetEntityTagsResponses, GetEntityTagsErrors, ThrowOnError> => (options.client ?? client).get<GetEntityTagsResponses, GetEntityTagsErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/tags/{entityType}/{entityId}',\n ...options\n});\n\n/**\n * Add or remove tags on an item\n *\n * Edits an item's tags incrementally: attaches every name in `add` (creating project tags as needed) and detaches every name in `remove`, leaving the item's other tags untouched. Matching is case-insensitive; a name in both lists ends up removed.\n *\n * **Use cases**\n *\n * - **Add a tag** — `{ \"add\": [\"regression\"] }`.\n * - **Swap a tag** — `{ \"add\": [\"p1\"], \"remove\": [\"p2\"] }`.\n */\nexport const updateEntityTags = <ThrowOnError extends boolean = false>(options: Options<UpdateEntityTagsData, ThrowOnError>): RequestResult<UpdateEntityTagsResponses, UpdateEntityTagsErrors, ThrowOnError> => (options.client ?? client).patch<UpdateEntityTagsResponses, UpdateEntityTagsErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/tags/{entityType}/{entityId}',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n\n/**\n * Replace an item's tags\n *\n * Replaces the item's whole tag set with `tags`: names not yet in the project are created, attached names not in the list are detached, and `[]` clears every tag. Names are deduped case-insensitively, reusing an existing tag's casing (sending `iOS` when `ios` exists attaches `ios`).\n *\n * **Use cases**\n *\n * - **Tag an item** — `{ \"tags\": [\"checkout\", \"ios\"] }`.\n * - **Clear tags** — `{ \"tags\": [] }`.\n *\n * To add or remove a few tags without restating the rest, use the incremental `PATCH` instead.\n */\nexport const setEntityTags = <ThrowOnError extends boolean = false>(options: Options<SetEntityTagsData, ThrowOnError>): RequestResult<SetEntityTagsResponses, SetEntityTagsErrors, ThrowOnError> => (options.client ?? client).put<SetEntityTagsResponses, SetEntityTagsErrors, ThrowOnError>({\n security: [{ scheme: 'bearer', type: 'http' }],\n url: '/api/admin/tags/{entityType}/{entityId}',\n ...options,\n headers: {\n 'Content-Type': 'application/json',\n ...options.headers\n }\n});\n","/**\n * `@shipeasy/openapi/client` — the generated, typed admin SDK.\n *\n * Re-exports every per-operation function (`createGate`, `listExperiments`, …),\n * the bundled fetch `client`, and `createClient`/`createConfig` for callers that\n * want an isolated client instance. Plus `configure()`, the one-call helper that\n * points the default client at a base URL and injects admin auth.\n *\n * This is generated from the hand-authored `spec/` tree — never hand-edit\n * `src/generated`. Regenerate with `pnpm gen`.\n */\nexport * from \"./generated/sdk.gen.js\";\nexport { client, type CreateClientConfig } from \"./generated/client.gen.js\";\nexport {\n createClient,\n // Aliased: the bare `createConfig` name belongs to the `createConfig`\n // operation (POST /configs) re-exported above via `sdk.gen`. This is hey-api's\n // client-config builder.\n createConfig as createClientConfig,\n type Client,\n type Config,\n type Options,\n type RequestResult,\n} from \"./generated/client/index.js\";\n\nimport { client } from \"./generated/client.gen.js\";\n\nexport interface ConfigureOptions {\n /** Admin SDK key — sent as `Authorization: Bearer <apiKey>`. */\n apiKey: string;\n /** Project to scope every request to — sent as the `X-Project-Id` header. */\n projectId?: string;\n /** Override the API origin (defaults to `https://shipeasy.ai`). */\n baseUrl?: string;\n}\n\n/**\n * Point the default `client` at an environment and attach admin auth. Call once\n * at startup; every generated SDK function then carries the bearer key and the\n * `X-Project-Id` scope. Pass a per-call `{ client }` to talk to a different\n * project without re-configuring the global.\n */\nexport function configure({ apiKey, projectId, baseUrl }: ConfigureOptions): void {\n client.setConfig({\n ...(baseUrl ? { baseUrl } : {}),\n auth: () => apiKey,\n headers: projectId ? { \"X-Project-Id\": projectId } : {},\n });\n}\n"],"mappings":";AA2DO,IAAM,qBAAqB;AAAA,EAChC,gBAAgB,CAAC,SACf,KAAK,UAAU,MAAM,CAAC,MAAM,UAAW,OAAO,UAAU,WAAW,MAAM,SAAS,IAAI,KAAM;AAChG;;;AClBA,IAAM,mBAAyC;AAAA,EAC7C,QAAQ;AAAA,EACR,WAAW;AAAA,EACX,QAAQ;AAAA,EACR,SAAS;AACX;AACA,IAAM,gBAAgB,OAAO,QAAQ,gBAAgB;;;AC+B9C,SAAS,gBAAiC;AAAA,EAC/C;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA,GAAG;AACL,GAA2D;AACzD,MAAI;AAEJ,QAAM,QAAQ,eAAe,CAAC,OAAe,IAAI,QAAQ,CAAC,YAAY,WAAW,SAAS,EAAE,CAAC;AAE7F,QAAM,eAAe,mBAAmB;AACtC,QAAI,aAAqB,wBAAwB;AACjD,QAAI,UAAU;AACd,UAAM,SAAS,QAAQ,UAAU,IAAI,gBAAgB,EAAE;AAEvD,WAAO,MAAM;AACX,UAAI,OAAO,QAAS;AAEpB;AAEA,YAAM,UACJ,QAAQ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