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

# Schedule a campaign mailing

> Schedules a new email campaign mailing with specified details for delivery at a future time



## OpenAPI

````yaml openapi2 POST /campaign_mailing_schedules
openapi: 3.0.3
info:
  title: Paubox Marketing API
  description: >
    Public documentation Paubox Marketing API. 


    All Paubox Marketing customers have access to the Paubox Marketing API to
    automate various tasks.


    ## Authentication

    Use the authorization header in requests with the format: `authorization:
    Token token=<API_KEY>`


    Replace `<API_KEY>` with your API key. Find your API key in the address bar
    from the email builder (note: each API Key is displayed only once upon
    creation).


    ## Base URL

    The base URL includes your username:
    `https://api.paubox.net/v1/orca/<USERNAME>`


    Replace `<USERNAME>` with your API endpoint username.
  contact:
    name: Paubox Support
    url: https://www.paubox.com
  version: 1.0.0
servers:
  - url: https://api.paubox.net/v1/orca/{username}
    description: Production server
    variables:
      username:
        description: Your API endpoint username
        default: YOUR_USERNAME
security:
  - TokenAuth: []
tags:
  - name: subscribers
    description: Subscriber management operations
  - name: analytics
    description: Campaign analytics and reporting operations
  - name: campaign_mailings
    description: Campaign mailing management and sending operations
  - name: drip_campaigns
    description: Drip campaign management and automation operations
  - name: subscription_lists
    description: Subscription list management operations
  - name: tracking_links
    description: Tracking link analytics and data operations
paths:
  /campaign_mailing_schedules:
    post:
      tags:
        - campaign_mailings
      summary: Schedule a new campaign mailing
      description: >-
        Schedules a new email campaign mailing with specified details for
        delivery at a future time
      operationId: scheduleCampaignMailing
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/ScheduleCampaignMailingRequest'
            example:
              send_at: '2023-05-01T15:00:00Z'
              from_email: no-reply@yourdomain.com
              from_name: Your Company Name
              sender_email: marketing@yourdomain.com
              subscription_list_id: 123e4567-e89b-12d3-a456-426614174000
              subject: Your Campaign Subject Line
              dynamic_list_id: optional-uuid-for-dynamic-list
              recipient_emails:
                - test1@example.com
                - test2@example.com
        required: true
      responses:
        '200':
          description: Campaign mailing scheduled successfully
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ScheduleCampaignMailingResponse'
        '400':
          description: Bad request - Invalid parameters
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/inline_response_400'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '422':
          $ref: '#/components/responses/UnprocessableEntity'
        '500':
          $ref: '#/components/responses/InternalServerError'
components:
  schemas:
    ScheduleCampaignMailingRequest:
      required:
        - from_email
        - from_name
        - send_at
        - sender_email
        - subject
        - subscription_list_id
      type: object
      properties:
        send_at:
          type: string
          description: The time at which to send the campaign, in RFC3339 format
          format: date-time
        from_email:
          type: string
          description: >-
            The email address from which the campaign will be sent. It should be
            from a verified domain from your Paubox Marketing settings page
          format: email
        from_name:
          type: string
          description: The name to appear as the sender of the campaign
        sender_email:
          type: string
          description: >-
            The email address of the person/entity sending this email. Should be
            a Paubox user email address and is NOT going to appear as the From
            email
          format: email
        subscription_list_id:
          type: string
          description: The uuid of the subscription list to which the campaign will be sent
          format: uuid
        subject:
          type: string
          description: The subject line of the campaign mailing
        dynamic_list_id:
          type: string
          description: >-
            The uuid of the dynamic list to which the campaign will be sent
            (optional)
          format: uuid
        recipient_emails:
          type: array
          description: >-
            A list of extra recipient email addresses for the campaign to be
            sent to. These are not tracked for analytics purposes and are
            usually just for verification and/or testing
          items:
            type: string
            format: email
    ScheduleCampaignMailingResponse:
      type: object
      properties:
        data:
          $ref: '#/components/schemas/ScheduleCampaignMailingResponse_data'
    inline_response_400:
      type: object
      properties:
        errors:
          type: string
          example: Invalid time format provided, please use RFC3339 format.
    ScheduleCampaignMailingResponse_data:
      type: object
      properties:
        send_at:
          type: string
          description: The scheduled send time in RFC3339 format
          format: date-time
        send_at_timestamp:
          type: string
          description: The scheduled send time as a Unix timestamp string
        jid:
          type: string
          description: Job ID string for the scheduled campaign
    Error:
      type: object
      properties:
        error:
          type: string
          description: Error message
        code:
          type: string
          description: Error code
        details:
          type: object
          description: Additional error details
  responses:
    Unauthorized:
      description: Unauthorized
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    UnprocessableEntity:
      description: Unprocessable entity
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    InternalServerError:
      description: Internal server error
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
  securitySchemes:
    TokenAuth:
      type: apiKey
      description: >-
        Token-based authentication. Use format: "Token token=<API_KEY>" where
        <API_KEY> is your API key
      name: authorization
      in: header

````