UNPKG

@vectorize-io/vectorize-client

Version:
85 lines (74 loc) 2.17 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'; /** * Authentication configuration for Elasticsearch * @export * @interface ELASTICAuthConfig */ export interface ELASTICAuthConfig { /** * Host. Example: Enter your host * @type {string} * @memberof ELASTICAuthConfig */ host: string; /** * Port. Example: Enter your port * @type {string} * @memberof ELASTICAuthConfig */ port: string; /** * API Key. Example: Enter your API key * @type {string} * @memberof ELASTICAuthConfig */ apiKey: string; } /** * Check if a given object implements the ELASTICAuthConfig interface. */ export function instanceOfELASTICAuthConfig(value: object): value is ELASTICAuthConfig { if (!('host' in value) || value['host'] === undefined) return false; if (!('port' in value) || value['port'] === undefined) return false; if (!('apiKey' in value) || value['apiKey'] === undefined) return false; return true; } export function ELASTICAuthConfigFromJSON(json: any): ELASTICAuthConfig { return ELASTICAuthConfigFromJSONTyped(json, false); } export function ELASTICAuthConfigFromJSONTyped(json: any, ignoreDiscriminator: boolean): ELASTICAuthConfig { if (json == null) { return json; } return { 'host': json['host'], 'port': json['port'], 'apiKey': json['api-key'], }; } export function ELASTICAuthConfigToJSON(json: any): ELASTICAuthConfig { return ELASTICAuthConfigToJSONTyped(json, false); } export function ELASTICAuthConfigToJSONTyped(value?: ELASTICAuthConfig | null, ignoreDiscriminator: boolean = false): any { if (value == null) { return value; } return { 'host': value['host'], 'port': value['port'], 'api-key': value['apiKey'], }; }