/* tslint:disable */ /* eslint-disable */ /** * Boat Public API v1 * Public JSON API for creating, operating, prompting, observing, and exposing Boat sandboxes from backend services, CI jobs, hosted workers, and Boat automation products. The v1 reference intentionally documents the developer integration surface only. Dashboard billing actions are not part of v1. * * The version of the OpenAPI document: 1.0.0 * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech * Do not edit the class manually. */ import { mapValues } from '../runtime'; import type { PromptRun } from './PromptRun'; import { PromptRunFromJSON, PromptRunFromJSONTyped, PromptRunToJSON, PromptRunToJSONTyped, } from './PromptRun'; /** * * @export * @interface PromptResponse */ export interface PromptResponse { /** * * @type {boolean} * @memberof PromptResponse */ ok: boolean; /** * * @type {PromptResponseTypeEnum} * @memberof PromptResponse */ type: PromptResponseTypeEnum; /** * Box id. * @type {string} * @memberof PromptResponse */ id: string; /** * * @type {string} * @memberof PromptResponse */ promptId: string; /** * The conversation this prompt was queued in. A new one when `new` was set, the one named by `conversationId`, or the Box's most-recently-active conversation. See [Integrated agents](/box/integrated-agents). * @type {string} * @memberof PromptResponse */ conversationId?: string | null; /** * * @type {PromptRun} * @memberof PromptResponse */ promptRun: PromptRun; /** * * @type {PromptResponseStatusEnum} * @memberof PromptResponse */ status: PromptResponseStatusEnum; /** * * @type {string} * @memberof PromptResponse */ provider: string; /** * * @type {string} * @memberof PromptResponse */ model?: string | null; /** * * @type {string} * @memberof PromptResponse */ reasoningEffort?: string | null; } /** * @export */ export const PromptResponseTypeEnum = { PromptQueued: 'prompt.queued' } as const; export type PromptResponseTypeEnum = typeof PromptResponseTypeEnum[keyof typeof PromptResponseTypeEnum]; /** * @export */ export const PromptResponseStatusEnum = { Queued: 'queued' } as const; export type PromptResponseStatusEnum = typeof PromptResponseStatusEnum[keyof typeof PromptResponseStatusEnum]; /** * Check if a given object implements the PromptResponse interface. */ export function instanceOfPromptResponse(value: object): value is PromptResponse { if (!('ok' in value) || value['ok'] === undefined) return false; if (!('type' in value) || value['type'] === undefined) return false; if (!('id' in value) || value['id'] === undefined) return false; if (!('promptId' in value) || value['promptId'] === undefined) return false; if (!('promptRun' in value) || value['promptRun'] === undefined) return false; if (!('status' in value) || value['status'] === undefined) return false; if (!('provider' in value) || value['provider'] === undefined) return false; return true; } export function PromptResponseFromJSON(json: any): PromptResponse { return PromptResponseFromJSONTyped(json, false); } export function PromptResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): PromptResponse { if (json == null) { return json; } return { 'ok': json['ok'], 'type': json['type'], 'id': json['id'], 'promptId': json['promptId'], 'conversationId': json['conversationId'] == null ? undefined : json['conversationId'], 'promptRun': PromptRunFromJSON(json['promptRun']), 'status': json['status'], 'provider': json['provider'], 'model': json['model'] == null ? undefined : json['model'], 'reasoningEffort': json['reasoningEffort'] == null ? undefined : json['reasoningEffort'], }; } export function PromptResponseToJSON(json: any): PromptResponse { return PromptResponseToJSONTyped(json, false); } export function PromptResponseToJSONTyped(value?: PromptResponse | null, ignoreDiscriminator: boolean = false): any { if (value == null) { return value; } return { 'ok': value['ok'], 'type': value['type'], 'id': value['id'], 'promptId': value['promptId'], 'conversationId': value['conversationId'], 'promptRun': PromptRunToJSON(value['promptRun']), 'status': value['status'], 'provider': value['provider'], 'model': value['model'], 'reasoningEffort': value['reasoningEffort'], }; }