/* tslint:disable */
/* eslint-disable */
/**
* Squad API
* API for managing Squad resources
*
* The version of the OpenAPI document: 0.14.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/
/**
* Request schema for creating an organisation
* @export
* @interface OrganisationsPostRequest
*/
export interface OrganisationsPostRequest {
/**
*
* @type {string}
* @memberof OrganisationsPostRequest
*/
name: string;
/**
*
* @type {string}
* @memberof OrganisationsPostRequest
*/
stripeCustomerId?: string;
/**
*
* @type {number}
* @memberof OrganisationsPostRequest
*/
maxDailyTokens?: number;
/**
*
* @type {number}
* @memberof OrganisationsPostRequest
*/
maxEntities?: number;
/**
*
* @type {number}
* @memberof OrganisationsPostRequest
*/
entitiesCreatedCount?: number;
/**
*
* @type {string}
* @memberof OrganisationsPostRequest
*/
homepageUrl?: string;
/**
*
* @type {string}
* @memberof OrganisationsPostRequest
*/
logoUrl?: string;
/**
*
* @type {Array<string>}
* @memberof OrganisationsPostRequest
*/
outcomeIds?: Array<string>;
/**
*
* @type {string}
* @memberof OrganisationsPostRequest
*/
id?: string;
}
/**
* Check if a given object implements the OrganisationsPostRequest interface.
*/
export function instanceOfOrganisationsPostRequest(
value: object,
): value is OrganisationsPostRequest {
if (!("name" in value) || value["name"] === undefined) return false;
return true;
}
export function OrganisationsPostRequestFromJSON(
json: any,
): OrganisationsPostRequest {
return OrganisationsPostRequestFromJSONTyped(json, false);
}
export function OrganisationsPostRequestFromJSONTyped(
json: any,
ignoreDiscriminator: boolean,
): OrganisationsPostRequest {
if (json == null) {
return json;
}
return {
name: json["name"],
stripeCustomerId:
json["stripeCustomerId"] == null ? undefined : json["stripeCustomerId"],
maxDailyTokens:
json["maxDailyTokens"] == null ? undefined : json["maxDailyTokens"],
maxEntities: json["maxEntities"] == null ? undefined : json["maxEntities"],
entitiesCreatedCount:
json["entitiesCreatedCount"] == null
? undefined
: json["entitiesCreatedCount"],
homepageUrl: json["homepageUrl"] == null ? undefined : json["homepageUrl"],
logoUrl: json["logoUrl"] == null ? undefined : json["logoUrl"],
outcomeIds: json["outcomeIds"] == null ? undefined : json["outcomeIds"],
id: json["id"] == null ? undefined : json["id"],
};
}
export function OrganisationsPostRequestToJSON(
json: any,
): OrganisationsPostRequest {
return OrganisationsPostRequestToJSONTyped(json, false);
}
export function OrganisationsPostRequestToJSONTyped(
value?: OrganisationsPostRequest | null,
ignoreDiscriminator: boolean = false,
): any {
if (value == null) {
return value;
}
return {
name: value["name"],
stripeCustomerId: value["stripeCustomerId"],
maxDailyTokens: value["maxDailyTokens"],
maxEntities: value["maxEntities"],
entitiesCreatedCount: value["entitiesCreatedCount"],
homepageUrl: value["homepageUrl"],
logoUrl: value["logoUrl"],
outcomeIds: value["outcomeIds"],
id: value["id"],
};
}