mailslurp-client
Version:
Official client for MailSlurp Email and SMS API. Create email addresses and phone numbers in Javascript without a mail server. Send and receive real emails in applications or tests.
217 lines (212 loc) • 5.54 kB
text/typescript
/* 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';
/**
*
* @export
* @interface ConnectorImapConnectionDto
*/
export interface ConnectorImapConnectionDto {
/**
*
* @type {string}
* @memberof ConnectorImapConnectionDto
*/
connectorId: string;
/**
*
* @type {string}
* @memberof ConnectorImapConnectionDto
*/
imapHost: string;
/**
*
* @type {number}
* @memberof ConnectorImapConnectionDto
*/
imapPort?: number;
/**
*
* @type {string}
* @memberof ConnectorImapConnectionDto
*/
imapUsername?: string;
/**
*
* @type {string}
* @memberof ConnectorImapConnectionDto
*/
imapPassword?: string;
/**
*
* @type {boolean}
* @memberof ConnectorImapConnectionDto
*/
imapSsl?: boolean;
/**
*
* @type {string}
* @memberof ConnectorImapConnectionDto
*/
selectFolder?: string;
/**
*
* @type {string}
* @memberof ConnectorImapConnectionDto
*/
searchTerms?: string;
/**
*
* @type {boolean}
* @memberof ConnectorImapConnectionDto
*/
startTls?: boolean;
/**
*
* @type {string}
* @memberof ConnectorImapConnectionDto
*/
proxyHost?: string;
/**
*
* @type {number}
* @memberof ConnectorImapConnectionDto
*/
proxyPort?: number;
/**
*
* @type {boolean}
* @memberof ConnectorImapConnectionDto
*/
proxyEnabled?: boolean;
/**
*
* @type {string}
* @memberof ConnectorImapConnectionDto
*/
localHostName?: string;
/**
*
* @type {Array<string>}
* @memberof ConnectorImapConnectionDto
*/
mechanisms?: Array<string>;
/**
*
* @type {Array<string>}
* @memberof ConnectorImapConnectionDto
*/
sslProtocols?: Array<string>;
/**
*
* @type {string}
* @memberof ConnectorImapConnectionDto
*/
sslTrust?: string;
/**
*
* @type {boolean}
* @memberof ConnectorImapConnectionDto
*/
enabled?: boolean;
/**
*
* @type {Date}
* @memberof ConnectorImapConnectionDto
*/
createdAt: Date;
/**
*
* @type {string}
* @memberof ConnectorImapConnectionDto
*/
id: string;
}
export function ConnectorImapConnectionDtoFromJSON(
json: any
): ConnectorImapConnectionDto {
return ConnectorImapConnectionDtoFromJSONTyped(json, false);
}
export function ConnectorImapConnectionDtoFromJSONTyped(
json: any,
ignoreDiscriminator: boolean
): ConnectorImapConnectionDto {
if (json === undefined || json === null) {
return json;
}
return {
connectorId: json['connectorId'],
imapHost: json['imapHost'],
imapPort: !exists(json, 'imapPort') ? undefined : json['imapPort'],
imapUsername: !exists(json, 'imapUsername')
? undefined
: json['imapUsername'],
imapPassword: !exists(json, 'imapPassword')
? undefined
: json['imapPassword'],
imapSsl: !exists(json, 'imapSsl') ? undefined : json['imapSsl'],
selectFolder: !exists(json, 'selectFolder')
? undefined
: json['selectFolder'],
searchTerms: !exists(json, 'searchTerms') ? undefined : json['searchTerms'],
startTls: !exists(json, 'startTls') ? undefined : json['startTls'],
proxyHost: !exists(json, 'proxyHost') ? undefined : json['proxyHost'],
proxyPort: !exists(json, 'proxyPort') ? undefined : json['proxyPort'],
proxyEnabled: !exists(json, 'proxyEnabled')
? undefined
: json['proxyEnabled'],
localHostName: !exists(json, 'localHostName')
? undefined
: json['localHostName'],
mechanisms: !exists(json, 'mechanisms') ? undefined : json['mechanisms'],
sslProtocols: !exists(json, 'sslProtocols')
? undefined
: json['sslProtocols'],
sslTrust: !exists(json, 'sslTrust') ? undefined : json['sslTrust'],
enabled: !exists(json, 'enabled') ? undefined : json['enabled'],
createdAt: new Date(json['createdAt']),
id: json['id'],
};
}
export function ConnectorImapConnectionDtoToJSON(
value?: ConnectorImapConnectionDto | null
): any {
if (value === undefined) {
return undefined;
}
if (value === null) {
return null;
}
return {
connectorId: value.connectorId,
imapHost: value.imapHost,
imapPort: value.imapPort,
imapUsername: value.imapUsername,
imapPassword: value.imapPassword,
imapSsl: value.imapSsl,
selectFolder: value.selectFolder,
searchTerms: value.searchTerms,
startTls: value.startTls,
proxyHost: value.proxyHost,
proxyPort: value.proxyPort,
proxyEnabled: value.proxyEnabled,
localHostName: value.localHostName,
mechanisms: value.mechanisms,
sslProtocols: value.sslProtocols,
sslTrust: value.sslTrust,
enabled: value.enabled,
createdAt: value.createdAt.toISOString(),
id: value.id,
};
}