Hierarchy

  • Backup

Implements

Constructors

Accessors

Methods

Constructors

Properties

config: BackupConfig

Accessors

Methods

  • Parameters

    • ctx: Context
    • next: (() => Promise<void>)
        • (): Promise<void>
        • Returns Promise<void>

    Returns Promise<void>

  • Generates a key for storing the email message.

    Parameters

    • message_id: string

      The ID of the email message.

    • from: string

      The email address of the sender.

    • to: string

      The email address of the recipient.

    Returns string

    A string representing the unique key for the email message.

  • Retrieves a raw message from the bucket.

    Parameters

    • message_id: string

      The ID of the message to retrieve.

    • from: string

      The sender of the message.

    • to: string

      The recipient of the message.

    Returns Promise<null | (() => Promise<ArrayBuffer>)>

    A function that returns the raw message as an ArrayBuffer, or null if the message was not found.

  • Saves an email message to the backup storage.

    Parameters

    • message_id: undefined | null | string

      The ID of the message to save. If null or undefined, a new ID will be generated.

    • from: string

      The email address of the sender.

    • to: string

      The email address of the recipient.

    • body: string | Uint8Array

      The body of the email message.

    Returns Promise<void>

Generated using TypeDoc