UNPKG

@emergentmethods/asknews-typescript-sdk

Version:
75 lines (64 loc) 1.71 kB
/* tslint:disable */ /* eslint-disable */ /** * AskNews API * AskNews API * * The version of the OpenAPI document: 0.19.10 * Contact: contact@emergentmethods.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'; /** * * @export * @interface EmailParams */ export interface EmailParams { /** * The email to send the alert to when it triggers * @type {string} * @memberof EmailParams */ to: string; /** * * @type {string} * @memberof EmailParams */ subject?: string | null; } /** * Check if a given object implements the EmailParams interface. */ export function instanceOfEmailParams(value: object): value is EmailParams { if (!('to' in value) || value['to'] === undefined) return false; return true; } export function EmailParamsFromJSON(json: any): EmailParams { return EmailParamsFromJSONTyped(json, false); } export function EmailParamsFromJSONTyped(json: any, ignoreDiscriminator: boolean): EmailParams { if (json == null) { return json; } return { 'to': json['to'], 'subject': json['subject'] == null ? undefined : json['subject'], }; } export function EmailParamsToJSON(json: any): EmailParams { return EmailParamsToJSONTyped(json, false); } export function EmailParamsToJSONTyped(value?: EmailParams | null, ignoreDiscriminator: boolean = false): any { if (value == null) { return value; } return { 'to': value['to'], 'subject': value['subject'], }; }