UpdateOutcomePayload.ts•3.49 kB
/* tslint:disable */
/* eslint-disable */
/**
* Squad API
* API for managing Squad resources
*
* The version of the OpenAPI document: 4.0.0
* Contact: help@meetsquad.ai
*
* 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.js';
/**
* Request schema for updating an outcome
* @export
* @interface UpdateOutcomePayload
*/
export interface UpdateOutcomePayload {
/**
* Title of the outcome
* @type {string}
* @memberof UpdateOutcomePayload
*/
title?: string;
/**
* Detailed description of the outcome
* @type {string}
* @memberof UpdateOutcomePayload
*/
description?: string;
/**
* Priority level of the outcome
* @type {number}
* @memberof UpdateOutcomePayload
*/
priority?: number;
/**
* Trend indicator for the outcome
* @type {number}
* @memberof UpdateOutcomePayload
*/
trend?: number;
/**
* List of analytic events associated with the outcome
* @type {Array<string>}
* @memberof UpdateOutcomePayload
*/
analyticEvents?: Array<string>;
/**
* ID of the owner of the outcome
* @type {string}
* @memberof UpdateOutcomePayload
*/
ownerId?: string;
/**
*
* @type {Array<string>}
* @memberof UpdateOutcomePayload
*/
opportunityIds?: Array<string>;
/**
*
* @type {Array<string>}
* @memberof UpdateOutcomePayload
*/
metricIds?: Array<string>;
}
/**
* Check if a given object implements the UpdateOutcomePayload interface.
*/
export function instanceOfUpdateOutcomePayload(value: object): value is UpdateOutcomePayload {
return true;
}
export function UpdateOutcomePayloadFromJSON(json: any): UpdateOutcomePayload {
return UpdateOutcomePayloadFromJSONTyped(json, false);
}
export function UpdateOutcomePayloadFromJSONTyped(json: any, ignoreDiscriminator: boolean): UpdateOutcomePayload {
if (json == null) {
return json;
}
return {
'title': json['title'] == null ? undefined : json['title'],
'description': json['description'] == null ? undefined : json['description'],
'priority': json['priority'] == null ? undefined : json['priority'],
'trend': json['trend'] == null ? undefined : json['trend'],
'analyticEvents': json['analyticEvents'] == null ? undefined : json['analyticEvents'],
'ownerId': json['ownerId'] == null ? undefined : json['ownerId'],
'opportunityIds': json['opportunityIds'] == null ? undefined : json['opportunityIds'],
'metricIds': json['metricIds'] == null ? undefined : json['metricIds'],
};
}
export function UpdateOutcomePayloadToJSON(json: any): UpdateOutcomePayload {
return UpdateOutcomePayloadToJSONTyped(json, false);
}
export function UpdateOutcomePayloadToJSONTyped(value?: UpdateOutcomePayload | null, ignoreDiscriminator: boolean = false): any {
if (value == null) {
return value;
}
return {
'title': value['title'],
'description': value['description'],
'priority': value['priority'],
'trend': value['trend'],
'analyticEvents': value['analyticEvents'],
'ownerId': value['ownerId'],
'opportunityIds': value['opportunityIds'],
'metricIds': value['metricIds'],
};
}