UNPKG

@vectorize-io/vectorize-client

Version:
103 lines (88 loc) 2.33 kB
/* tslint:disable */ /* eslint-disable */ /** * Vectorize API * API for Vectorize services (Beta) * * The version of the OpenAPI document: 0.1.2 * * * 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 { VOYAGEAuthConfig } from './VOYAGEAuthConfig'; import { VOYAGEAuthConfigFromJSON, VOYAGEAuthConfigFromJSONTyped, VOYAGEAuthConfigToJSON, VOYAGEAuthConfigToJSONTyped, } from './VOYAGEAuthConfig'; /** * * @export * @interface Voyage */ export interface Voyage { /** * Name of the connector * @type {string} * @memberof Voyage */ name: string; /** * Must be "VOYAGE" * @type {string} * @memberof Voyage */ type: VoyageTypeEnum; /** * * @type {VOYAGEAuthConfig} * @memberof Voyage */ config: VOYAGEAuthConfig; } /** * @export */ export const VoyageTypeEnum = { Voyage: 'VOYAGE' } as const; export type VoyageTypeEnum = typeof VoyageTypeEnum[keyof typeof VoyageTypeEnum]; /** * Check if a given object implements the Voyage interface. */ export function instanceOfVoyage(value: object): value is Voyage { if (!('name' in value) || value['name'] === undefined) return false; if (!('type' in value) || value['type'] === undefined) return false; if (!('config' in value) || value['config'] === undefined) return false; return true; } export function VoyageFromJSON(json: any): Voyage { return VoyageFromJSONTyped(json, false); } export function VoyageFromJSONTyped(json: any, ignoreDiscriminator: boolean): Voyage { if (json == null) { return json; } return { 'name': json['name'], 'type': json['type'], 'config': VOYAGEAuthConfigFromJSON(json['config']), }; } export function VoyageToJSON(json: any): Voyage { return VoyageToJSONTyped(json, false); } export function VoyageToJSONTyped(value?: Voyage | null, ignoreDiscriminator: boolean = false): any { if (value == null) { return value; } return { 'name': value['name'], 'type': value['type'], 'config': VOYAGEAuthConfigToJSON(value['config']), }; }