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

# Bulk create subscribers

> Create up to 100 subscribers in one request.

<Note>
  The body is a JSON array (max 100 items). Each item can set its own `status`; items with
  `pending` receive confirmation emails.
</Note>

<Warning>
  If any item fails validation, **no subscribers are created**. Bulk creation is all-or-nothing.
</Warning>


## OpenAPI

````yaml openapi.json POST /subscribers/bulk
openapi: 3.1.0
info:
  title: Newsletter Public API V1
  description: >-
    Create, list, update and unsubscribe newsletter subscribers from external
    integrations.
  version: 1.0.0
servers:
  - url: https://app.letterbucket.com/api/v1
    description: Production
security:
  - bearerAuth: []
paths:
  /subscribers/bulk:
    post:
      tags:
        - Subscribers
      summary: Bulk create subscribers
      description: >-
        Create up to 100 subscribers in a single request. The body is a JSON
        array. Bulk creation is all-or-nothing: if any item fails validation,
        none are created.
      operationId: bulkCreateSubscribers
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: array
              minItems: 1
              maxItems: 100
              items:
                $ref: '#/components/schemas/SubscriberInput'
            example:
              - email: a@example.com
                status: active
              - email: b@example.com
                status: pending
              - email: c@example.com
      responses:
        '201':
          description: Subscribers created.
          content:
            application/json:
              schema:
                type: object
                properties:
                  success:
                    type: boolean
                  data:
                    type: object
                    properties:
                      created:
                        type: array
                        items:
                          $ref: '#/components/schemas/Subscriber'
              example:
                success: true
                data:
                  created:
                    - id: 019756c2-aaaa
                      email: a@example.com
                      name: ''
                      status: active
                      created_at: '2026-06-11T17:00:00+00:00'
                    - id: 019756c2-bbbb
                      email: b@example.com
                      name: ''
                      status: pending
                      created_at: '2026-06-11T17:00:00+00:00'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          $ref: '#/components/responses/Forbidden'
        '422':
          $ref: '#/components/responses/ValidationError'
        '429':
          $ref: '#/components/responses/RateLimited'
components:
  schemas:
    SubscriberInput:
      type: object
      required:
        - email
      additionalProperties: false
      properties:
        email:
          type: string
          format: email
          maxLength: 254
          description: Subscriber email address.
          example: user@example.com
        name:
          type: string
          maxLength: 255
          nullable: true
          description: Full name. Stored as first + last name, split on the first space.
          example: John Doe
        status:
          type: string
          enum:
            - active
            - pending
          description: >-
            Optional. `active` makes the subscriber active directly; `pending`
            sends a confirmation email.
    Subscriber:
      type: object
      properties:
        id:
          type: string
          format: uuid
        email:
          type: string
          format: email
        name:
          type: string
          nullable: true
        status:
          type: string
          enum:
            - active
            - pending
            - unsubscribed
        created_at:
          type: string
          format: date-time
    Error:
      type: object
      properties:
        success:
          type: boolean
          example: false
        code:
          type: string
          description: Machine-readable error code.
        message:
          type: string
          description: Human-readable description.
        errors:
          type: object
          additionalProperties: true
          description: Optional field-level errors.
  responses:
    BadRequest:
      description: Malformed request.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
          example:
            success: false
            code: validation_error
            message: The request contains invalid data.
    Unauthorized:
      description: Missing or invalid API key.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
          example:
            success: false
            code: unauthorized
            message: Invalid API key.
    Forbidden:
      description: API access disabled for your plan.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
          example:
            success: false
            code: api_access_disabled
            message: API access is not enabled.
    ValidationError:
      description: Field-level validation errors.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
          example:
            success: false
            code: validation_error
            message: The request contains invalid data.
            errors:
              email:
                - Enter a valid email address.
    RateLimited:
      description: Rate limit exceeded or temporary lockout.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
          example:
            success: false
            code: rate_limit_exceeded
            message: Too many requests. Please try again later.
            errors:
              retry_after: 42
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: 'Your API key, sent as `Authorization: Bearer sk_...`.'

````