The documentation you are viewing is for Dapr v0.11 which is an older version of Dapr. For up-to-date documentation, see the latest version.

Postmark binding spec

Detailed documentation on the Postmark binding component

Setup Dapr component

apiVersion: dapr.io/v1alpha1
kind: Component
metadata:
  name: postmark
  namespace: default
spec:
  type: bindings.postmark
  metadata:
  - name: accountToken
    value: "YOUR_ACCOUNT_TOKEN" # required, this is your Postmark account token
  - name: serverToken
    value: "YOUR_SERVER_TOKEN" # required, this is your Postmark server token
  - name: emailFrom
    value: "testapp@dapr.io" # optional
  - name: emailTo
    value: "dave@dapr.io" # optional
  - name: subject
    value: "Hello!" # optional
  • accountToken is your Postmark account token, this should be considered a secret value. Required.
  • serverToken is your Postmark server token, this should be considered a secret value. Required.
  • emailFrom If set this specifies the ‘from’ email address of the email message. Optional field, see below.
  • emailTo If set this specifies the ‘to’ email address of the email message. Optional field, see below.
  • emailCc If set this specifies the ‘cc’ email address of the email message. Optional field, see below.
  • emailBcc If set this specifies the ‘bcc’ email address of the email message. Optional field, see below.
  • subject If set this specifies the subject of the email message. Optional field, see below.

You can specify any of the optional metadata properties on the output binding request too (e.g. emailFrom, emailTo, subject, etc.)

Combined, the optional metadata properties in the component configuration and the request payload should at least contain the emailFrom, emailTo and subject fields, as these are required to send an email with success.

Example request payload

{
  "operation": "create",
  "metadata": {
    "emailTo": "changeme@example.net",
    "subject": "An email from Dapr Postmark binding"
  },
  "data": "<h1>Testing Dapr Bindings</h1>This is a test.<br>Bye!"
}

Output Binding Supported Operations

  • create
Last modified July 7, 2022: update nav bar v0.11 (#2633) (b309d3d)