UNPKG

@vectorize-io/vectorize-client

Version:
103 lines (88 loc) 2.35 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 { GITHUBAuthConfig } from './GITHUBAuthConfig'; import { GITHUBAuthConfigFromJSON, GITHUBAuthConfigFromJSONTyped, GITHUBAuthConfigToJSON, GITHUBAuthConfigToJSONTyped, } from './GITHUBAuthConfig'; /** * * @export * @interface Github */ export interface Github { /** * Name of the connector * @type {string} * @memberof Github */ name: string; /** * Connector type (must be "GITHUB") * @type {string} * @memberof Github */ type: GithubTypeEnum; /** * * @type {GITHUBAuthConfig} * @memberof Github */ config: GITHUBAuthConfig; } /** * @export */ export const GithubTypeEnum = { Github: 'GITHUB' } as const; export type GithubTypeEnum = typeof GithubTypeEnum[keyof typeof GithubTypeEnum]; /** * Check if a given object implements the Github interface. */ export function instanceOfGithub(value: object): value is Github { 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 GithubFromJSON(json: any): Github { return GithubFromJSONTyped(json, false); } export function GithubFromJSONTyped(json: any, ignoreDiscriminator: boolean): Github { if (json == null) { return json; } return { 'name': json['name'], 'type': json['type'], 'config': GITHUBAuthConfigFromJSON(json['config']), }; } export function GithubToJSON(json: any): Github { return GithubToJSONTyped(json, false); } export function GithubToJSONTyped(value?: Github | null, ignoreDiscriminator: boolean = false): any { if (value == null) { return value; } return { 'name': value['name'], 'type': value['type'], 'config': GITHUBAuthConfigToJSON(value['config']), }; }