/* tslint:disable */ /* eslint-disable */ /** * MailSlurp API * MailSlurp is an API for sending and receiving emails and SMS from dynamically allocated email addresses and phone numbers. It\'s designed for developers and QA teams to test applications, process inbound emails, send templated notifications, attachments, and more. ## Resources - [Homepage](https://www.mailslurp.com) - Get an [API KEY](https://app.mailslurp.com/sign-up/) - Generated [SDK Clients](https://docs.mailslurp.com/) - [Examples](https://github.com/mailslurp/examples) repository * * The version of the OpenAPI document: 6.5.2 * Contact: contact@mailslurp.dev * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech * Do not edit the class manually. */ import { exists, mapValues } from '../runtime'; /** * Single event for a deliverability simulation job * @export * @interface DeliverabilitySimulationJobEventDto */ export interface DeliverabilitySimulationJobEventDto { /** * * @type {string} * @memberof DeliverabilitySimulationJobEventDto */ id: string; /** * * @type {string} * @memberof DeliverabilitySimulationJobEventDto */ eventType: DeliverabilitySimulationJobEventDtoEventTypeEnum; /** * * @type {number} * @memberof DeliverabilitySimulationJobEventDto */ sendIndex?: number | null; /** * * @type {string} * @memberof DeliverabilitySimulationJobEventDto */ entityId?: string | null; /** * * @type {string} * @memberof DeliverabilitySimulationJobEventDto */ targetLabel?: string | null; /** * * @type {string} * @memberof DeliverabilitySimulationJobEventDto */ expectationName?: string | null; /** * * @type {number} * @memberof DeliverabilitySimulationJobEventDto */ attempt?: number | null; /** * * @type {string} * @memberof DeliverabilitySimulationJobEventDto */ message?: string | null; /** * * @type {string} * @memberof DeliverabilitySimulationJobEventDto */ error?: string | null; /** * * @type {Date} * @memberof DeliverabilitySimulationJobEventDto */ createdAt: Date; } /** * @export * @enum {string} */ export enum DeliverabilitySimulationJobEventDtoEventTypeEnum { JOB_CREATED = 'JOB_CREATED', JOB_STARTED = 'JOB_STARTED', JOB_PAUSED = 'JOB_PAUSED', JOB_RESUMED = 'JOB_RESUMED', JOB_CANCELLED = 'JOB_CANCELLED', JOB_COMPLETED = 'JOB_COMPLETED', JOB_FAILED = 'JOB_FAILED', SEND_SUCCESS = 'SEND_SUCCESS', SEND_FAILURE = 'SEND_FAILURE', } export function DeliverabilitySimulationJobEventDtoFromJSON( json: any ): DeliverabilitySimulationJobEventDto { return DeliverabilitySimulationJobEventDtoFromJSONTyped(json, false); } export function DeliverabilitySimulationJobEventDtoFromJSONTyped( json: any, ignoreDiscriminator: boolean ): DeliverabilitySimulationJobEventDto { if (json === undefined || json === null) { return json; } return { id: json['id'], eventType: json['eventType'], sendIndex: !exists(json, 'sendIndex') ? undefined : json['sendIndex'], entityId: !exists(json, 'entityId') ? undefined : json['entityId'], targetLabel: !exists(json, 'targetLabel') ? undefined : json['targetLabel'], expectationName: !exists(json, 'expectationName') ? undefined : json['expectationName'], attempt: !exists(json, 'attempt') ? undefined : json['attempt'], message: !exists(json, 'message') ? undefined : json['message'], error: !exists(json, 'error') ? undefined : json['error'], createdAt: new Date(json['createdAt']), }; } export function DeliverabilitySimulationJobEventDtoToJSON( value?: DeliverabilitySimulationJobEventDto | null ): any { if (value === undefined) { return undefined; } if (value === null) { return null; } return { id: value.id, eventType: value.eventType, sendIndex: value.sendIndex, entityId: value.entityId, targetLabel: value.targetLabel, expectationName: value.expectationName, attempt: value.attempt, message: value.message, error: value.error, createdAt: value.createdAt.toISOString(), }; }