> ## Documentation Index
> Fetch the complete documentation index at: https://docs.shipthing.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Postmark

> Learn how to use Postmark for sending emails.

To use Postmark with ShipThing

<Steps>
  <Step title="Create a Postmark account">
    [Create a Postmark account](https://postmark.com/) and grab your API key.
  </Step>

  <Step title="Add environment variables">
    Add the `POSTMARK_TOKEN` environment variables to your .env.local file and your deployment environment:

    Then, make sure to activate Postmark:

    ```ts /packages/email/index.ts theme={"system"}
    export * from './providers/postmark';
    ```
  </Step>

  <Step title="Sending Emails">
    ```tsx apps/web/app/contact/actions/contact.tsx theme={"system"}
    import { postmarkClient } from '@repo/email';
    import { ContactTemplate } from '@repo/email/emails/contact';
    import { render } from "@react-email/components";

    const emailHtml = await render(<ContactTemplate name={name} email={email} message={message} />);

    await postmarkClient.send({
        From: 'sender@acme.com',
        To: 'recipient@acme.com',
        Subject: 'The email subject',
        HtmlBody: emailHtml,
    });
    ```
  </Step>
</Steps>
