@vectorize-io/vectorize-client
Version:
Client for the Vectorize API
103 lines (88 loc) • 2.42 kB
text/typescript
/* 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 { SUPABASEAuthConfig } from './SUPABASEAuthConfig';
import {
SUPABASEAuthConfigFromJSON,
SUPABASEAuthConfigFromJSONTyped,
SUPABASEAuthConfigToJSON,
SUPABASEAuthConfigToJSONTyped,
} from './SUPABASEAuthConfig';
/**
*
* @export
* @interface Supabase
*/
export interface Supabase {
/**
* Name of the connector
* @type {string}
* @memberof Supabase
*/
name: string;
/**
* Connector type (must be "SUPABASE")
* @type {string}
* @memberof Supabase
*/
type: SupabaseTypeEnum;
/**
*
* @type {SUPABASEAuthConfig}
* @memberof Supabase
*/
config: SUPABASEAuthConfig;
}
/**
* @export
*/
export const SupabaseTypeEnum = {
Supabase: 'SUPABASE'
} as const;
export type SupabaseTypeEnum = typeof SupabaseTypeEnum[keyof typeof SupabaseTypeEnum];
/**
* Check if a given object implements the Supabase interface.
*/
export function instanceOfSupabase(value: object): value is Supabase {
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 SupabaseFromJSON(json: any): Supabase {
return SupabaseFromJSONTyped(json, false);
}
export function SupabaseFromJSONTyped(json: any, ignoreDiscriminator: boolean): Supabase {
if (json == null) {
return json;
}
return {
'name': json['name'],
'type': json['type'],
'config': SUPABASEAuthConfigFromJSON(json['config']),
};
}
export function SupabaseToJSON(json: any): Supabase {
return SupabaseToJSONTyped(json, false);
}
export function SupabaseToJSONTyped(value?: Supabase | null, ignoreDiscriminator: boolean = false): any {
if (value == null) {
return value;
}
return {
'name': value['name'],
'type': value['type'],
'config': SUPABASEAuthConfigToJSON(value['config']),
};
}