@types/nodemailer

  • Version 6.4.2
  • Published
  • 85.8 kB
  • 1 dependency
  • MIT license

Install

npm i @types/nodemailer
yarn add @types/nodemailer
pnpm add @types/nodemailer

Overview

TypeScript definitions for Nodemailer

Index

Functions

function createTestAccount

createTestAccount: {
(
apiUrl: string,
callback: (err: Error | null, testAccount: TestAccount) => void
): void;
(callback: (err: Error, testAccount: TestAccount) => void): void;
(apiUrl?: string): Promise<TestAccount>;
};

    function createTransport

    createTransport: {
    (
    transport?: SMTPTransport | SMTPTransport.Options | string,
    defaults?: SMTPTransport.Options
    ): Transporter<SMTPTransport.SentMessageInfo>;
    (
    transport: SMTPPool | SMTPPool.Options,
    defaults?: SMTPPool.Options
    ): Transporter<SMTPPool.SentMessageInfo>;
    (
    transport: SendmailTransport | SendmailTransport.Options,
    defaults?: SendmailTransport.Options
    ): Transporter<SendmailTransport.SentMessageInfo>;
    (
    transport: StreamTransport | StreamTransport.Options,
    defaults?: StreamTransport.Options
    ): Transporter<StreamTransport.SentMessageInfo>;
    (
    transport: JSONTransport | JSONTransport.Options,
    defaults?: JSONTransport.Options
    ): Transporter<JSONTransport.SentMessageInfo>;
    (
    transport: SESTransport | SESTransport.Options,
    defaults?: SESTransport.Options
    ): Transporter<SESTransport.SentMessageInfo>;
    <T>(
    transport: TransportOptions | Transport<T>,
    defaults?: TransportOptions
    ): Transporter<T>;
    };

      function getTestMessageUrl

      getTestMessageUrl: (
      info: SESTransport.SentMessageInfo | SMTPTransport.SentMessageInfo
      ) => string | false;

        Interfaces

        interface TestAccount

        interface TestAccount {}

          property imap

          imap: { host: string; port: number; secure: boolean };

            property pass

            pass: string;

              property pop3

              pop3: { host: string; port: number; secure: boolean };

                property smtp

                smtp: { host: string; port: number; secure: boolean };

                  property user

                  user: string;

                    property web

                    web: string;

                      interface Transport

                      interface Transport<T = any> {}

                        property mailer

                        mailer?: Transporter<T>;

                          property name

                          name: string;

                            property version

                            version: string;

                              method close

                              close: () => void;

                                method send

                                send: (
                                mail: MailMessage<T>,
                                callback: (err: Error | null, info: T) => void
                                ) => void;

                                  method verify

                                  verify: {
                                  (callback: (err: Error | null, success: true) => void): void;
                                  (): Promise<true>;
                                  };

                                    interface TransportOptions

                                    interface TransportOptions {}

                                      property component

                                      component?: string;

                                        Type Aliases

                                        type SendMailOptions

                                        type SendMailOptions = Mail.Options;

                                          type SentMessageInfo

                                          type SentMessageInfo = any;

                                            type Transporter

                                            type Transporter<T = any> = Mail<T>;

                                              Package Files (1)

                                              Dependencies (1)

                                              Dev Dependencies (0)

                                              No dev dependencies.

                                              Peer Dependencies (0)

                                              No peer dependencies.

                                              Badge

                                              To add a badge like this onejsDocs.io badgeto your package's README, use the codes available below.

                                              You may also use Shields.io to create a custom badge linking to https://www.jsdocs.io/package/@types/nodemailer.

                                              • Markdown
                                                [![jsDocs.io](https://img.shields.io/badge/jsDocs.io-reference-blue)](https://www.jsdocs.io/package/@types/nodemailer)
                                              • HTML
                                                <a href="https://www.jsdocs.io/package/@types/nodemailer"><img src="https://img.shields.io/badge/jsDocs.io-reference-blue" alt="jsDocs.io"></a>