@vectorize-io/vectorize-client
Version:
Client for the Vectorize API
103 lines (92 loc) • 2.73 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';
/**
* Configuration for Notion connector
* @export
* @interface NOTIONConfig
*/
export interface NOTIONConfig {
/**
* Select Notion Resources
* @type {string}
* @memberof NOTIONConfig
*/
selectResources: string;
/**
* Database IDs
* @type {string}
* @memberof NOTIONConfig
*/
databaseIds: string;
/**
* Database Names
* @type {string}
* @memberof NOTIONConfig
*/
databaseNames: string;
/**
* Page IDs
* @type {string}
* @memberof NOTIONConfig
*/
pageIds: string;
/**
* Page Names
* @type {string}
* @memberof NOTIONConfig
*/
pageNames: string;
}
/**
* Check if a given object implements the NOTIONConfig interface.
*/
export function instanceOfNOTIONConfig(value: object): value is NOTIONConfig {
if (!('selectResources' in value) || value['selectResources'] === undefined) return false;
if (!('databaseIds' in value) || value['databaseIds'] === undefined) return false;
if (!('databaseNames' in value) || value['databaseNames'] === undefined) return false;
if (!('pageIds' in value) || value['pageIds'] === undefined) return false;
if (!('pageNames' in value) || value['pageNames'] === undefined) return false;
return true;
}
export function NOTIONConfigFromJSON(json: any): NOTIONConfig {
return NOTIONConfigFromJSONTyped(json, false);
}
export function NOTIONConfigFromJSONTyped(json: any, ignoreDiscriminator: boolean): NOTIONConfig {
if (json == null) {
return json;
}
return {
'selectResources': json['select-resources'],
'databaseIds': json['database-ids'],
'databaseNames': json['database-names'],
'pageIds': json['page-ids'],
'pageNames': json['page-names'],
};
}
export function NOTIONConfigToJSON(json: any): NOTIONConfig {
return NOTIONConfigToJSONTyped(json, false);
}
export function NOTIONConfigToJSONTyped(value?: NOTIONConfig | null, ignoreDiscriminator: boolean = false): any {
if (value == null) {
return value;
}
return {
'select-resources': value['selectResources'],
'database-ids': value['databaseIds'],
'database-names': value['databaseNames'],
'page-ids': value['pageIds'],
'page-names': value['pageNames'],
};
}