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

# Send an email to one of more registered contacts.

> Send a personalized email to one more (up to 100 using 1 API call) contacts subscribed to a proviced mailing list. This is the recommended way to send an email to members of a team of your product. All provided emails must belong to your mailing list and must be members of provided mailing list. All contacts are automatically subscribed to `important` default mailing list. You can use peronalization tags such as `Hi {{firstName}}` to peronalize individual sent emails, and scheduled it to be sent with a delay.



## OpenAPI

````yaml post /email/contact
openapi: 3.0.3
info:
  title: IndiePitcher OpenAPI Spec
  description: >-
    ## Welcome


    IndiePitcher REST API allows you to send emails, manage your contacts, and
    generate portal session to manage user's contact lists.


    Please note that most destructive operations are currently not supported
    through the REST API for sesucurity reasons. Please use the [IndiePitcher
    dashboard](https://app.indiepitcher.com).


    ## Base URL

    All requests contain the following base URL:

    ```

    https://api.indiepitcher.com/v1

    ```


    ## Authentication


    - Create a free account at [IndiePitcher](https://app.indiepitcher.com) to
    get your API key. API keys are tied to a project.

    - After you've generated your API key you can use it to authenticate your
    requests by including it in the `Authorization` header.


    ```http

    Authorization: Bearer sc_xxxxxxxxxxxxxxxxxxxxxxxxxxxx

    ```


    ## SDKs


    SDKs are available for the following languages:

    - [Node.js](https://github.com/IndiePitcher/indiepitcher-node)

    - [Swift](https://github.com/IndiePitcher/indiepitcher-swift) (server-side
    usage only)


    ## Rate Limits


    Rate limits are applied to all requests to the IndiePitcher API. The rate
    limits are as follows:

    - **10 requests per second across API keys tied to a project.**


    After reaching the rate limit, you will receive a `429 Too Many Requests`
    response. The rate limit will reset after 1 second. We recommend using
    endpoints that support batch operations to reduce the number of requests
    made.


    ## Quick Start Guide

    ### Send a simple email


    ```bash

    curl --request POST \
      --url https://api.indiepitcher.com/v1/email/transactional \
      --header 'Authorization: Bearer <token>' \
      --header 'Content-Type: application/json' \
      --data '{
        "to": "john@acme.com",
        "subject": "You have been invited to IndiePitcher",
        "body": "This is a sample body that supports **markdown**. Plain html is also supported.",
        "bodyFormat": "markdown"
      }'
    ```
  version: 1.2.0
  termsOfService: http://indiepitcher.com/terms
  contact:
    email: petr@indiepitcher.com
servers:
  - url: https://api.indiepitcher.com/v1
security: []
tags:
  - name: Email
  - name: Contacts
  - name: Mailing Lists
externalDocs:
  description: Find out more about IndiePitcher
  url: http://docs.indiepitcher.com
paths:
  /email/contact:
    post:
      tags:
        - Email
      summary: Send an email to one of more registered contacts.
      description: >-
        Send a personalized email to one more (up to 100 using 1 API call)
        contacts subscribed to a proviced mailing list. This is the recommended
        way to send an email to members of a team of your product. All provided
        emails must belong to your mailing list and must be members of provided
        mailing list. All contacts are automatically subscribed to `important`
        default mailing list. You can use peronalization tags such as `Hi
        {{firstName}}` to peronalize individual sent emails, and scheduled it to
        be sent with a delay.
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/SendEmailToContact'
        required: true
      responses:
        '200':
          description: An empty response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/EmptyResponse'
      security:
        - apiKey: []
components:
  schemas:
    SendEmailToContact:
      type: object
      properties:
        contactEmail:
          type: string
          nullable: true
          description: The email of the contact to send.
          example: john@acme.com
        contactEmails:
          type: array
          items:
            type: string
          example: null
          nullable: true
          description: >-
            Allows you to send an email to multiple contacts using a single
            request.
        subject:
          type: string
          description: The subject of the email. Supports personalization.
          example: Welcome to IndiePitcher {{firstName}}!
        body:
          type: string
          description: >-
            The body of the email. Both HTML and markdown body do support
            personalization.
          example: >-
            Hi {{firstName}}, You can use **markdown** to generate the email.
            Plain HTML is also supported.
        bodyFormat:
          $ref: '#/components/schemas/EmailBodyFormat'
        list:
          type: string
          description: >-
            Specify a list the contact(s) can unsubscribe from if they don't
            wish to receive further emails like this. The contact(s) must be
            subscribed to this list. Pass 'important' to provide a list the
            contact(s) cannot unsubscribe from.
          example: important
        delaySeconds:
          type: number
          format: double
          example: null
          nullable: true
          description: Delay sending of this email by the amount of seconds you provide.
        delayUntilDate:
          type: string
          format: date-time
          nullable: true
          description: Delay sending of this email until specified date.
        trackEmailOpens:
          type: boolean
          description: >-
            Whether to track email opens. Allow you to overwrite the project's
            global setting. Default: `nil` - Uses the project's global setting.
          example: null
        trackEmailLinkClicks:
          type: boolean
          description: >-
            Whether to track when a users taps on a link in the email. Allow you
            to overwrite the project's global setting. Default: `nil` - Uses the
            project's global setting.
          example: null
      required:
        - subject
        - body
        - bodyFormat
        - list
    EmptyResponse:
      type: object
      properties:
        success:
          type: boolean
          description: Always true
    EmailBodyFormat:
      type: string
      enum:
        - markdown
        - html
      description: The format of the email body. It can be either 'markdown' or 'html'.
  securitySchemes:
    apiKey:
      type: http
      scheme: bearer

````