/* tslint:disable */ /* eslint-disable */ /** * Fabric API * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * 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'; /** * * @export * @interface AssistantMessagePartOneOf2 */ export interface AssistantMessagePartOneOf2 { /** * * @type {string} * @memberof AssistantMessagePartOneOf2 */ 'type': AssistantMessagePartOneOf2TypeEnum; /** * * @type {string} * @memberof AssistantMessagePartOneOf2 */ 'error': string; } /** * @export */ export const AssistantMessagePartOneOf2TypeEnum = { Error: 'error' } as const; export type AssistantMessagePartOneOf2TypeEnum = typeof AssistantMessagePartOneOf2TypeEnum[keyof typeof AssistantMessagePartOneOf2TypeEnum]; /** * Check if a given object implements the AssistantMessagePartOneOf2 interface. */ export function instanceOfAssistantMessagePartOneOf2(value: object): value is AssistantMessagePartOneOf2 { if (!('type' in value) || value['type'] === undefined) return false; if (!('error' in value) || value['error'] === undefined) return false; return true; } export function AssistantMessagePartOneOf2FromJSON(json: any): AssistantMessagePartOneOf2 { return AssistantMessagePartOneOf2FromJSONTyped(json, false); } export function AssistantMessagePartOneOf2FromJSONTyped(json: any, ignoreDiscriminator: boolean): AssistantMessagePartOneOf2 { if (json == null) { return json; } const result = { } as AssistantMessagePartOneOf2; if (json['type'] !== undefined) { result['type'] = json['type']; } if (json['error'] !== undefined) { result['error'] = json['error']; } return result; } export function AssistantMessagePartOneOf2ToJSON(json: any): AssistantMessagePartOneOf2 { return AssistantMessagePartOneOf2ToJSONTyped(json, false); } export function AssistantMessagePartOneOf2ToJSONTyped(value?: AssistantMessagePartOneOf2 | null, ignoreDiscriminator: boolean = false): any { if (value == null) { return value; } return { 'type': value['type'], 'error': value['error'], }; }