@vectorize-io/vectorize-client
Version:
Client for the Vectorize API
85 lines (74 loc) • 2.38 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';
/**
* Authentication configuration for SharePoint
* @export
* @interface SHAREPOINTAuthConfig
*/
export interface SHAREPOINTAuthConfig {
/**
* Client Id. Example: Enter Client Id
* @type {string}
* @memberof SHAREPOINTAuthConfig
*/
msClientId: string;
/**
* Tenant Id. Example: Enter Tenant Id
* @type {string}
* @memberof SHAREPOINTAuthConfig
*/
msTenantId: string;
/**
* Client Secret. Example: Enter Client Secret
* @type {string}
* @memberof SHAREPOINTAuthConfig
*/
msClientSecret: string;
}
/**
* Check if a given object implements the SHAREPOINTAuthConfig interface.
*/
export function instanceOfSHAREPOINTAuthConfig(value: object): value is SHAREPOINTAuthConfig {
if (!('msClientId' in value) || value['msClientId'] === undefined) return false;
if (!('msTenantId' in value) || value['msTenantId'] === undefined) return false;
if (!('msClientSecret' in value) || value['msClientSecret'] === undefined) return false;
return true;
}
export function SHAREPOINTAuthConfigFromJSON(json: any): SHAREPOINTAuthConfig {
return SHAREPOINTAuthConfigFromJSONTyped(json, false);
}
export function SHAREPOINTAuthConfigFromJSONTyped(json: any, ignoreDiscriminator: boolean): SHAREPOINTAuthConfig {
if (json == null) {
return json;
}
return {
'msClientId': json['ms-client-id'],
'msTenantId': json['ms-tenant-id'],
'msClientSecret': json['ms-client-secret'],
};
}
export function SHAREPOINTAuthConfigToJSON(json: any): SHAREPOINTAuthConfig {
return SHAREPOINTAuthConfigToJSONTyped(json, false);
}
export function SHAREPOINTAuthConfigToJSONTyped(value?: SHAREPOINTAuthConfig | null, ignoreDiscriminator: boolean = false): any {
if (value == null) {
return value;
}
return {
'ms-client-id': value['msClientId'],
'ms-tenant-id': value['msTenantId'],
'ms-client-secret': value['msClientSecret'],
};
}