Postmark API

The Postmark API provides programmatic access to send and track transactional and broadcast emails, manage servers, templates, message streams, bounces, suppressions, statistics, webhooks, and inbound message processing.

OpenAPI Specification

postmark-api-openapi.yml Raw ↑
openapi: 3.0.0
info:
  title: Postmark API
  description: |-
    Postmark helps deliver and track application email. In a nutshell, the
    service replaces SMTP (or Sendmail) with a far more reliable, scalable and
    care-free environment. In addition, you can track statistics such as
    number of emails sent or processed, opens, bounces and spam complaints.
  version: 1.0.0
servers:
  - url: http://{{baseurl}}
tags:
  - name: Activate
  - name: Alias
  - name: Batch
  - name: Bounceid
  - name: Bounces
  - name: Browser Families
  - name: Bypass
  - name: Dump
  - name: Email
  - name: Emailclients
  - name: Inbound
  - name: Locations
  - name: Message Identifier
  - name: Messages
  - name: Messages > Inbound > {Messageid}
  - name: Messages > Outbound > Clicks
  - name: Messages > Outbound > Opens
  - name: Messages > Outbound > {Messageid}
  - name: Outbound
  - name: Platforms
  - name: Readtimes
  - name: Retry
  - name: Sends
  - name: Servers
  - name: Spam
  - name: Statistics
  - name: Stats/Outbound
  - name: Stats/Outbound > Clicks
  - name: Stats/Outbound > Opens
  - name: Template
  - name: Templates
  - name: Triggerid
  - name: Triggers
  - name: Triggers > Inboundrules
  - name: Triggers > Tags
  - name: Validate
paths:
  /bounces/{bounceid}:
    get:
      tags:
        - Bounceid
      summary: Postmark Get a single bounce
      parameters:
        - name: bounceid
          in: path
          schema:
            type: string
          required: true
          description: The ID of the bounce to retrieve.
          example: <integer>
      responses:
        '200':
          description: Successful response
          content:
            application/json: {}
  /bounces/{bounceid}/activate:
    put:
      tags:
        - Activate
        - Bounceid
      summary: Postmark Activate a bounce
      requestBody:
        content: {}
      parameters:
        - name: bounceid
          in: path
          schema:
            type: string
          required: true
          description: The ID of the bounce to retrieve.
          example: <integer>
      responses:
        '200':
          description: Successful response
          content:
            application/json: {}
  /bounces/{bounceid}/dump:
    get:
      tags:
        - Bounceid
        - Dump
      summary: Postmark Get bounce dump
      parameters:
        - name: bounceid
          in: path
          schema:
            type: string
          required: true
          description: The ID of the bounce to retrieve.
          example: <integer>
      responses:
        '200':
          description: Successful response
          content:
            application/json: {}
  /bounces:
    get:
      tags:
        - Bounces
      summary: Postmark Get bounces
      parameters:
        - name: count
          in: query
          schema:
            type: string
          description: Number of bounces to return per request. Max 500.
          example: <integer>
        - name: offset
          in: query
          schema:
            type: string
          description: Number of bounces to skip.
          example: <integer>
        - name: type
          in: query
          schema:
            type: string
          description: Filter by type of bounce
          example: <string>
        - name: inactive
          in: query
          schema:
            type: string
          description: >-
            Filter by emails that were deactivated by Postmark due to the
            bounce. Set to true or false. If this isn't specified it will return
            both active and inactive.
          example: <boolean>
        - name: emailFilter
          in: query
          schema:
            type: string
          description: Filter by email address
          example: <string>
        - name: messageID
          in: query
          schema:
            type: string
          description: Filter by messageID
          example: <string>
        - name: tag
          in: query
          schema:
            type: string
          description: Filter by tag
          example: <string>
        - name: todate
          in: query
          schema:
            type: string
          description: Filter messages up to the date specified. e.g. `2014-02-01`
          example: <string>
        - name: fromdate
          in: query
          schema:
            type: string
          description: Filter messages starting from the date specified. e.g. `2014-02-01`
          example: <string>
      responses:
        '200':
          description: Successful response
          content:
            application/json: {}
  /bounces/tags:
    get:
      tags: []
      summary: Postmark Get bounced tags
      responses:
        '200':
          description: Successful response
          content:
            application/json: {}
  /email:
    post:
      tags:
        - Email
      summary: Postmark Send a single email
      requestBody:
        content: {}
      responses:
        '200':
          description: Successful response
          content:
            application/json: {}
  /email/batch:
    post:
      tags:
        - Batch
        - Email
      summary: Postmark Send a batch of emails
      requestBody:
        content: {}
      responses:
        '200':
          description: Successful response
          content:
            application/json: {}
  /email/batchWithTemplates:
    post:
      tags:
        - Batch
        - Email
        - Templates
      summary: Postmark Send a batch of email using templates.
      requestBody:
        content: {}
      responses:
        '200':
          description: Successful response
          content:
            application/json: {}
  /email/withTemplate:
    post:
      tags:
        - Email
        - Template
      summary: Postmark Send an email using a Template
      requestBody:
        content: {}
      responses:
        '200':
          description: Successful response
          content:
            application/json: {}
  /messages/inbound/{messageid}/bypass:
    put:
      tags:
        - Bypass
        - Inbound
        - Messages
      summary: Postmark Bypass rules for a blocked inbound message
      requestBody:
        content: {}
      parameters:
        - name: messageid
          in: path
          schema:
            type: string
          required: true
          description: The ID of the message which should bypass inbound rules.
          example: <string>
      responses:
        '200':
          description: Successful response
          content:
            application/json: {}
  /messages/inbound/{messageid}/details:
    get:
      tags:
        - Inbound
        - Messages
        - Messages > Inbound > {Messageid}
      summary: Postmark Inbound message details
      parameters:
        - name: messageid
          in: path
          schema:
            type: string
          required: true
          description: The ID of the message which should bypass inbound rules.
          example: <string>
      responses:
        '200':
          description: Successful response
          content:
            application/json: {}
  /messages/inbound/{messageid}/retry:
    put:
      tags:
        - Inbound
        - Messages
        - Retry
      summary: Postmark Retry a failed inbound message for processing
      requestBody:
        content: {}
      parameters:
        - name: messageid
          in: path
          schema:
            type: string
          required: true
          description: The ID of the message which should bypass inbound rules.
          example: <string>
      responses:
        '200':
          description: Successful response
          content:
            application/json: {}
  /messages/inbound:
    get:
      tags:
        - Inbound
        - Messages
      summary: Postmark Inbound message search
      parameters:
        - name: count
          in: query
          schema:
            type: string
          description: Number of bounces to return per request. Max 500.
          example: <integer>
        - name: offset
          in: query
          schema:
            type: string
          description: Number of bounces to skip.
          example: <integer>
        - name: recipient
          in: query
          schema:
            type: string
          description: Filter by the user who was receiving the email
          example: <string>
        - name: fromemail
          in: query
          schema:
            type: string
          description: Filter by the sender email address
          example: <string>
        - name: subject
          in: query
          schema:
            type: string
          description: Filter by email subject
          example: <string>
        - name: mailboxhash
          in: query
          schema:
            type: string
          description: Filter by mailboxhash
          example: <string>
        - name: tag
          in: query
          schema:
            type: string
          description: Filter by tag
          example: <string>
        - name: status
          in: query
          schema:
            type: string
          description: >-
            Filter by status (`blocked`, `processed`, `queued`, `failed`,
            `scheduled`)
          example: <string>
        - name: todate
          in: query
          schema:
            type: string
          description: Filter messages up to the date specified. e.g. `2014-02-01`
          example: <string>
        - name: fromdate
          in: query
          schema:
            type: string
          description: Filter messages starting from the date specified. e.g. `2014-02-01`
          example: <string>
      responses:
        '200':
          description: Successful response
          content:
            application/json: {}
  /messages/outbound/clicks:
    get:
      tags:
        - Messages
        - Messages > Outbound > Clicks
        - Outbound
      summary: Postmark Clicks for a all messages
      parameters:
        - name: count
          in: query
          schema:
            type: string
          description: Number of bounces to return per request. Max 500.
          example: <integer>
        - name: offset
          in: query
          schema:
            type: string
          description: Number of bounces to skip.
          example: <integer>
        - name: recipient
          in: query
          schema:
            type: string
          description: Filter by the user who was receiving the email
          example: <string>
        - name: tag
          in: query
          schema:
            type: string
          description: Filter by tag
          example: <string>
        - name: client_name
          in: query
          schema:
            type: string
          description: Filter by client name, i.e. Outlook, Gmail
          example: <string>
        - name: client_company
          in: query
          schema:
            type: string
          description: Filter by company, i.e. Microsoft, Apple, Google
          example: <string>
        - name: client_family
          in: query
          schema:
            type: string
          description: Filter by client family, i.e. OS X, Chrome
          example: <string>
        - name: os_name
          in: query
          schema:
            type: string
          description: >-
            Filter by full OS name and specific version, i.e. OS X 10.9
            Mavericks, Windows 7
          example: <string>
        - name: os_family
          in: query
          schema:
            type: string
          description: >-
            Filter by kind of OS used without specific version, i.e. OS X,
            Windows
          example: <string>
        - name: os_company
          in: query
          schema:
            type: string
          description: >-
            Filter by company which produced the OS, i.e. Apple Computer, Inc.,
            Microsoft Corporation
          example: <string>
        - name: platform
          in: query
          schema:
            type: string
          description: Filter by platform, i.e. webmail, desktop, mobile
          example: <string>
        - name: country
          in: query
          schema:
            type: string
          description: Filter by country messages were opened in, i.e. Denmark, Russia
          example: <string>
        - name: region
          in: query
          schema:
            type: string
          description: >-
            Filter by full name of region messages were opened in, i.e. Moscow,
            New York
          example: <string>
        - name: city
          in: query
          schema:
            type: string
          description: >-
            Filter by full name of region messages were opened in, i.e. Moscow,
            New York
          example: <string>
      responses:
        '200':
          description: Successful response
          content:
            application/json: {}
  /messages/outbound/clicks/{messageid}:
    get:
      tags:
        - Message Identifier
        - Messages
        - Outbound
      summary: Postmark Retrieve Message Clicks
      parameters:
        - name: count
          in: query
          schema:
            type: string
          description: Number of bounces to return per request. Max 500.
          example: <integer>
        - name: offset
          in: query
          schema:
            type: string
          description: Number of bounces to skip.
          example: <integer>
        - name: messageid
          in: path
          schema:
            type: string
          required: true
          description: The ID of the message which should bypass inbound rules.
          example: <string>
      responses:
        '200':
          description: Successful response
          content:
            application/json: {}
  /messages/outbound/opens:
    get:
      tags:
        - Messages
        - Messages > Outbound > Opens
        - Outbound
      summary: Postmark Opens for all messages
      parameters:
        - name: count
          in: query
          schema:
            type: string
          description: Number of bounces to return per request. Max 500.
          example: <integer>
        - name: offset
          in: query
          schema:
            type: string
          description: Number of bounces to skip.
          example: <integer>
        - name: recipient
          in: query
          schema:
            type: string
          description: Filter by the user who was receiving the email
          example: <string>
        - name: tag
          in: query
          schema:
            type: string
          description: Filter by tag
          example: <string>
        - name: client_name
          in: query
          schema:
            type: string
          description: Filter by client name, i.e. Outlook, Gmail
          example: <string>
        - name: client_company
          in: query
          schema:
            type: string
          description: Filter by company, i.e. Microsoft, Apple, Google
          example: <string>
        - name: client_family
          in: query
          schema:
            type: string
          description: Filter by client family, i.e. OS X, Chrome
          example: <string>
        - name: os_name
          in: query
          schema:
            type: string
          description: >-
            Filter by full OS name and specific version, i.e. OS X 10.9
            Mavericks, Windows 7
          example: <string>
        - name: os_family
          in: query
          schema:
            type: string
          description: >-
            Filter by kind of OS used without specific version, i.e. OS X,
            Windows
          example: <string>
        - name: os_company
          in: query
          schema:
            type: string
          description: >-
            Filter by company which produced the OS, i.e. Apple Computer, Inc.,
            Microsoft Corporation
          example: <string>
        - name: platform
          in: query
          schema:
            type: string
          description: Filter by platform, i.e. webmail, desktop, mobile
          example: <string>
        - name: country
          in: query
          schema:
            type: string
          description: Filter by country messages were opened in, i.e. Denmark, Russia
          example: <string>
        - name: region
          in: query
          schema:
            type: string
          description: >-
            Filter by full name of region messages were opened in, i.e. Moscow,
            New York
          example: <string>
        - name: city
          in: query
          schema:
            type: string
          description: >-
            Filter by full name of region messages were opened in, i.e. Moscow,
            New York
          example: <string>
      responses:
        '200':
          description: Successful response
          content:
            application/json: {}
  /messages/outbound/opens/{messageid}:
    get:
      tags:
        - Message Identifier
        - Messages
        - Outbound
      summary: Postmark Retrieve Message Opens
      parameters:
        - name: count
          in: query
          schema:
            type: string
          description: Number of bounces to return per request. Max 500.
          example: <integer>
        - name: offset
          in: query
          schema:
            type: string
          description: Number of bounces to skip.
          example: <integer>
        - name: messageid
          in: path
          schema:
            type: string
          required: true
          description: The ID of the message which should bypass inbound rules.
          example: <string>
      responses:
        '200':
          description: Successful response
          content:
            application/json: {}
  /messages/outbound/{messageid}/details:
    get:
      tags:
        - Messages
        - Messages > Outbound > {Messageid}
        - Outbound
      summary: Postmark Outbound message details
      parameters:
        - name: messageid
          in: path
          schema:
            type: string
          required: true
          description: The ID of the message which should bypass inbound rules.
          example: <string>
      responses:
        '200':
          description: Successful response
          content:
            application/json: {}
  /messages/outbound/{messageid}/dump:
    get:
      tags:
        - Dump
        - Messages
        - Outbound
      summary: Postmark Outbound message dump
      parameters:
        - name: messageid
          in: path
          schema:
            type: string
          required: true
          description: The ID of the message which should bypass inbound rules.
          example: <string>
      responses:
        '200':
          description: Successful response
          content:
            application/json: {}
  /messages/outbound:
    get:
      tags:
        - Messages
        - Outbound
      summary: Postmark Outbound message search
      parameters:
        - name: count
          in: query
          schema:
            type: string
          description: Number of bounces to return per request. Max 500.
          example: <integer>
        - name: offset
          in: query
          schema:
            type: string
          description: Number of bounces to skip.
          example: <integer>
        - name: recipient
          in: query
          schema:
            type: string
          description: Filter by the user who was receiving the email
          example: <string>
        - name: fromemail
          in: query
          schema:
            type: string
          description: Filter by the sender email address
          example: <string>
        - name: tag
          in: query
          schema:
            type: string
          description: Filter by tag
          example: <string>
        - name: status
          in: query
          schema:
            type: string
          description: >-
            Filter by status (`blocked`, `processed`, `queued`, `failed`,
            `scheduled`)
          example: <string>
        - name: todate
          in: query
          schema:
            type: string
          description: Filter messages up to the date specified. e.g. `2014-02-01`
          example: <string>
        - name: fromdate
          in: query
          schema:
            type: string
          description: Filter messages starting from the date specified. e.g. `2014-02-01`
          example: <string>
      responses:
        '200':
          description: Successful response
          content:
            application/json: {}
  /stats/outbound/clicks:
    get:
      tags:
        - Outbound
        - Statistics
        - Stats/Outbound > Clicks
      summary: Postmark Get click counts
      parameters:
        - name: tag
          in: query
          schema:
            type: string
          description: Filter by tag
          example: <string>
        - name: fromdate
          in: query
          schema:
            type: string
          description: Filter messages starting from the date specified. e.g. `2014-02-01`
          example: <string>
        - name: todate
          in: query
          schema:
            type: string
          description: Filter messages up to the date specified. e.g. `2014-02-01`
          example: <string>
      responses:
        '200':
          description: Successful response
          content:
            application/json: {}
  /stats/outbound/clicks/browserfamilies:
    get:
      tags:
        - Browser Families
        - Outbound
        - Statistics
      summary: Postmark Get browser usage by family
      parameters:
        - name: tag
          in: query
          schema:
            type: string
          description: Filter by tag
          example: <string>
        - name: fromdate
          in: query
          schema:
            type: string
          description: Filter messages starting from the date specified. e.g. `2014-02-01`
          example: <string>
        - name: todate
          in: query
          schema:
            type: string
          description: Filter messages up to the date specified. e.g. `2014-02-01`
          example: <string>
      responses:
        '200':
          description: Successful response
          content:
            application/json: {}
  /stats/outbound/clicks/location:
    get:
      tags:
        - Locations
        - Outbound
        - Statistics
      summary: Postmark Get clicks by body location
      parameters:
        - name: tag
          in: query
          schema:
            type: string
          description: Filter by tag
          example: <string>
        - name: fromdate
          in: query
          schema:
            type: string
          description: Filter messages starting from the date specified. e.g. `2014-02-01`
          example: <string>
        - name: todate
          in: query
          schema:
            type: string
          description: Filter messages up to the date specified. e.g. `2014-02-01`
          example: <string>
      responses:
        '200':
          description: Successful response
          content:
            application/json: {}
  /stats/outbound/clicks/platforms:
    get:
      tags:
        - Outbound
        - Platforms
        - Statistics
      summary: Postmark Get browser plaform usage
      parameters:
        - name: tag
          in: query
          schema:
            type: string
          description: Filter by tag
          example: <string>
        - name: fromdate
          in: query
          schema:
            type: string
          description: Filter messages starting from the date specified. e.g. `2014-02-01`
          example: <string>
        - name: todate
          in: query
          schema:
            type: string
          description: Filter messages up to the date specified. e.g. `2014-02-01`
          example: <string>
      responses:
        '200':
          description: Successful response
          content:
            application/json: {}
  /stats/outbound/opens:
    get:
      tags:
        - Outbound
        - Statistics
        - Stats/Outbound > Opens
      summary: Postmark Get email open counts
      parameters:
        - name: tag
          in: query
          schema:
            type: string
          description: Filter by tag
          example: <string>
        - name: fromdate
          in: query
          schema:
            type: string
          description: Filter messages starting from the date specified. e.g. `2014-02-01`
          example: <string>
        - name: todate
          in: query
          schema:
            type: string
          description: Filter messages up to the date specified. e.g. `2014-02-01`
          example: <string>
      responses:
        '200':
          description: Successful response
          content:
            application/json: {}
  /stats/outbound/opens/emailclients:
    get:
      tags:
        - Emailclients
        - Outbound
        - Statistics
      summary: Postmark Get email client usage
      parameters:
        - name: tag
          in: query
          schema:
            type: string
          description: Filter by tag
          example: <string>
        - name: fromdate
          in: query
          schema:
            type: string
          description: Filter messages starting from the date specified. e.g. `2014-02-01`
          example: <string>
        - name: todate
          in: query
          schema:
            type: string
          description: Filter messages up to the date specified. e.g. `2014-02-01`
          example: <string>
      responses:
        '200':
          description: Successful response
          content:
            application/json: {}
  /stats/outbound/opens/platforms:
    get:
      tags:
        - Outbound
        - Platforms
        - Statistics
      summary: Postmark Get email platform usage
      parameters:
        - name: tag
          in: query
          schema:
            type: string
          description: Filter by tag
          example: <string>
        - name: fromdate
          in: query
          schema:
            type: string
          description: Filter messages starting from the date specified. e.g. `2014-02-01`
          example: <string>
        - name: todate
          in: query
          schema:
            type: string
          description: Filter messages up to the date specified. e.g. `2014-02-01`
          example: <string>
      responses:
        '200':
          description: Successful response
          content:
            application/json: {}
  /stats/outbound/opens/readtimes:
    get:
      tags:
        - Outbound
        - Readtimes
        - Statistics
      summary: Postmark Get email read times
      parameters:
        - name: tag
          in: query
          schema:
            type: string
          description: Filter by tag
          example: <string>
        - name: fromdate
          in: query
          schema:
            type: string
          description: Filter messages starting from the date specified. e.g. `2014-02-01`
          example: <string>
        - name: todate
          in: query
          schema:
            type: string
          description: Filter messages up to the date specified. e.g. `2014-02-01`
          example: <string>
      responses:
        '200':
          description: Successful response
          content:
            application/json: {}
  /stats/outbound:
    get:
      tags:
        - Outbound
        - Statistics
      summary: Postmark Get outbound overview
      parameters:
        - name: tag
          in: query
          schema:
            type: string
          description: Filter by tag
          example: <string>
        - name: fromdate
          in: query
          schema:
            type: string
          description: Filter messages starting from the date specified. e.g. `2014-02-01`
          example: <string>
        - name: todate
          in: query
          schema:
            type: string
          description: Filter messages up to the date specified. e.g. `2014-02-01`
          example: <string>
      responses:
        '200':
          description: Successful response
          content:
            application/json: {}
  /stats/outbound/bounces:
    get:
      tags:
        - Outbound
        - Statistics
        - Stats/Outbound
      summary: Postmark Get bounce counts
      parameters:
        - name: tag
          in: query
          schema:
            type: string
          description: Filter by tag
          example: <string>
        - name: fromdate
          in: query
          schema:
            type: string
          description: Filter messages starting from the date specified. e.g. `2014-02-01`
          example: <string>
        - name: todate
          in: query
          schema:
            type: string
          description: Filter messages up to the date specified. e.g. `2014-02-01`
          example: <string>
      responses:
        '200':
          description: Successful response
          content:
            application/json: {}
  /stats/outbound/sends:
    get:
      tags:
        - Outbound
        - Sends
        - Statistics
      summary: Postmark Get sent counts
      parameters:
        - name: tag
          in: query
          schema:
            type: string
          description: Filter by tag
          example: <string>
        - name: fromdate
          in: query
          schema:
            type: string
          description: Filter messages starting from the date specified. e.g. `2014-02-01`
          example: <string>
        - name: todate
          in: query
          schema:
            type: string
          description: Filter messages up to the date specified. e.g. `2014-02-01`
          example: <string>
      responses:
        '200':
          description: Successful response
          content:
            application/json: {}
  /stats/outbound/spam:
    get:
      tags:
        - Outbound
        - Spam
        - Statistics
      summary: Postmark Get spam complaints
      parameters:
        - name: tag
          in: query
          schema:
            type: string
          description: Filter by tag
          example: <string>
        - name: fromdate
          in: query
          schema:
            type: string
          description: Filter messages starting from the date specified. e.g. `2014-02-01`
          example: <string>
        - name: todate
          in: query
          schema:
            type: string
          description: Filter messages up to the date specified. e.g. `2014-02-01`
          example: <string>
      responses:
        '200':
          description: Successful response
          content:
            application/json: {}
  /stats/outbound/tracked:
    get:
      tags:
        - Outbound
        - Statistics
        - Stats/Outbound
      summary: Postmark Get tracked email counts
      parameters:
        - name: tag
          in: query
          schema:
            type: string
          description: Filter by tag
          example: <string>
        - name: fromdate
          in: query
          schema:
            type: string
          description: Filter messages starting from the date specified. e.g. `2014-02-01`
          example: <string>
        - name: todate
          in: query
          schema:
            type: string
          description: Filter messages up to the date specified. e.g. `2014-02-01`
          example: <string>
      responses:
        '200':
          description: Successful response
          content:
            application/json: {}
  /templates:
    get:
      tags:
        - Templates
      summary: Postmark Get the Templates associated with this Server
      parameters:
        - name: count
          in: query
          schema:
            type: string
          description: Number of bounces to return per request. Max 500.
          example: <integer>
        - name: offset
          in: query
          schema:
            type: string
          description: Number of bounces to skip.
          example: <integer>
      responses:
        '200':
          description: Successful response
          content:
            application/json: {}
  /templates/validate:
    post:
      tags:
        - Templates
        - Validate
      summary: Postmark Test Template Conten

# --- truncated at 32 KB (35 KB total) ---
# Full source: https://raw.githubusercontent.com/api-evangelist/postmark/refs/heads/main/openapi/postmark-api-openapi.yml