UNPKG

@vectorize-io/vectorize-client

Version:
103 lines (88 loc) 2.39 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 { DISCORDAuthConfig } from './DISCORDAuthConfig'; import { DISCORDAuthConfigFromJSON, DISCORDAuthConfigFromJSONTyped, DISCORDAuthConfigToJSON, DISCORDAuthConfigToJSONTyped, } from './DISCORDAuthConfig'; /** * * @export * @interface Discord */ export interface Discord { /** * Name of the connector * @type {string} * @memberof Discord */ name: string; /** * Connector type (must be "DISCORD") * @type {string} * @memberof Discord */ type: DiscordTypeEnum; /** * * @type {DISCORDAuthConfig} * @memberof Discord */ config: DISCORDAuthConfig; } /** * @export */ export const DiscordTypeEnum = { Discord: 'DISCORD' } as const; export type DiscordTypeEnum = typeof DiscordTypeEnum[keyof typeof DiscordTypeEnum]; /** * Check if a given object implements the Discord interface. */ export function instanceOfDiscord(value: object): value is Discord { 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 DiscordFromJSON(json: any): Discord { return DiscordFromJSONTyped(json, false); } export function DiscordFromJSONTyped(json: any, ignoreDiscriminator: boolean): Discord { if (json == null) { return json; } return { 'name': json['name'], 'type': json['type'], 'config': DISCORDAuthConfigFromJSON(json['config']), }; } export function DiscordToJSON(json: any): Discord { return DiscordToJSONTyped(json, false); } export function DiscordToJSONTyped(value?: Discord | null, ignoreDiscriminator: boolean = false): any { if (value == null) { return value; } return { 'name': value['name'], 'type': value['type'], 'config': DISCORDAuthConfigToJSON(value['config']), }; }