> ## 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.

# Bulk subscribe a dynamic list

> The dynamic list counterpart to [bulk global subscribe](/marketing/subscriptions/bulk-global-subscribe).

- **Explicit** — supply `subscriber_ids` and the request behaves exactly
  like [`POST /subscriptions/subscribe`](/marketing/subscriptions/subscribe).
- **Select-all** — omit `subscriber_ids` and supply
  `from_subscription_list_id`, which here is a **dynamic list** UUID. The
  job resolves the list's current membership, subtracts `except_ids`, and
  clears the global opt-out on the rest. A Sidekiq job ID (`jid`) is
  returned immediately.

A dynamic list's membership is defined by the filters saved on the list itself, so any `filters` sent with the request is ignored in select-all mode.




## OpenAPI

````yaml openapi2 POST /subscriptions/dynamic_bulk_subscribe
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

    `https://api.paubox.com/v1/marketing`
  contact:
    name: Paubox Support
    url: https://www.paubox.com
  version: 1.0.0
servers:
  - url: https://api.paubox.com/v1/marketing
    description: Production server
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: subscriptions
    description: Subscriber opt-in and opt-out operations
  - name: tracking_links
    description: Tracking link analytics and data operations
paths:
  /subscriptions/dynamic_bulk_subscribe:
    post:
      tags:
        - subscriptions
      summary: Bulk subscribe a dynamic list
      description: >
        The dynamic list counterpart to [bulk global
        subscribe](/marketing/subscriptions/bulk-global-subscribe).


        - **Explicit** — supply `subscriber_ids` and the request behaves exactly
          like [`POST /subscriptions/subscribe`](/marketing/subscriptions/subscribe).
        - **Select-all** — omit `subscriber_ids` and supply
          `from_subscription_list_id`, which here is a **dynamic list** UUID. The
          job resolves the list's current membership, subtracts `except_ids`, and
          clears the global opt-out on the rest. A Sidekiq job ID (`jid`) is
          returned immediately.

        A dynamic list's membership is defined by the filters saved on the list
        itself, so any `filters` sent with the request is ignored in select-all
        mode.
      operationId: dynamicBulkSubscribe
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/BulkSubscriptionChangeRequest'
            example:
              from_subscription_list_id: 7c9e6679-7425-40de-944b-e07fc1f90ae7
              except_ids:
                - 8f14e45f-ceea-467a-9f2c-4b3d2a1e5c60
        required: true
      responses:
        '200':
          description: >-
            A job ID in select-all mode, or the affected subscribers when
            `subscriber_ids` was supplied.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/BulkSubscriptionChangeResponse'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
components:
  schemas:
    BulkSubscriptionChangeRequest:
      type: object
      properties:
        subscriber_ids:
          type: array
          description: >-
            UUIDs of specific subscribers to update. When present the request is
            handled synchronously and every other field is ignored.
          items:
            type: string
        from_subscription_list_id:
          type: string
          description: >-
            UUID of the list whose members are being updated. Required when
            `subscriber_ids` is omitted. On the `bulk_global_*` endpoints this
            is a subscription list UUID; on the `dynamic_bulk_*` endpoints it is
            a dynamic list UUID.
        search:
          type: string
          description: >-
            Search term used to narrow the list's members. Defaults to `*` (all
            members) on the `bulk_global_*` endpoints.
        filters:
          type: string
          description: >-
            URL-encoded JSON describing additional subscriber filters, as
            generated by the subscriber search in the Marketing dashboard. The
            decoded value is an array of filter groups, each group an array of
            `{"field": ..., "op": ..., "terms": [...]}` objects. Ignored by the
            `dynamic_bulk_*` endpoints, which use the filters saved on the
            dynamic list.
        except_ids:
          type: array
          description: >-
            UUIDs of subscribers to exclude from the operation. Use this to
            express "select all except these".
          items:
            type: string
    BulkSubscriptionChangeResponse:
      type: object
      properties:
        data:
          oneOf:
            - $ref: '#/components/schemas/BulkSubscriptionJob'
            - type: array
              description: >-
                The affected subscribers, returned when `subscriber_ids` was
                supplied.
              items:
                $ref: '#/components/schemas/DetailedSubscriber'
        errors:
          type: string
          description: Error message, present only when the operation failed
    BulkSubscriptionJob:
      type: object
      properties:
        jid:
          type: string
          description: >-
            Identifier of the background job processing the change. The change
            is applied asynchronously.
    DetailedSubscriber:
      type: object
      properties:
        id:
          type: string
          description: Unique identifier for the subscriber
        type:
          type: string
          description: Resource type
        attributes:
          $ref: '#/components/schemas/DetailedSubscriber_attributes'
    Error:
      type: object
      properties:
        error:
          type: string
          description: Error message
        code:
          type: string
          description: Error code
        details:
          type: object
          description: Additional error details
    DetailedSubscriber_attributes:
      type: object
      properties:
        email:
          type: string
          description: Subscriber's email address
          format: email
        first_name:
          type: string
          description: Subscriber's first name
        last_name:
          type: string
          description: Subscriber's last name
        unsubscribed:
          type: boolean
          description: Whether the subscriber is unsubscribed
        created_at:
          type: string
          description: Timestamp when subscriber was created
          format: date-time
        updated_at:
          type: string
          description: Timestamp when subscriber was last updated
          format: date-time
        custom_fields:
          type: array
          items:
            $ref: '#/components/schemas/DetailedSubscriber_attributes_custom_fields'
        subscription_lists:
          type: array
          items:
            $ref: >-
              #/components/schemas/DetailedSubscriber_attributes_subscription_lists
        statistics:
          $ref: '#/components/schemas/DetailedSubscriber_attributes_statistics'
    DetailedSubscriber_attributes_custom_fields:
      type: object
      properties:
        subscriber_custom_field_type_id:
          type: string
          description: ID of the custom field type
        custom_field_name:
          type: string
          description: Name of the custom field
        custom_field_value:
          type: string
          description: Value of the custom field
    DetailedSubscriber_attributes_subscription_lists:
      type: object
      properties:
        id:
          type: string
          description: Subscription list ID
        name:
          type: string
          description: Subscription list name
        unsubscribed:
          type: boolean
          description: Whether subscriber is unsubscribed from this list
    DetailedSubscriber_attributes_statistics:
      type: object
      properties:
        deliveries:
          type: integer
          description: Number of deliveries
        delivered:
          type: integer
          description: Number of delivered emails
        opened:
          type: integer
          description: Number of opened emails
        clicked:
          type: integer
          description: Number of clicked emails
        soft_bounced:
          type: integer
          description: Number of soft bounces
        hard_bounced:
          type: integer
          description: Number of hard bounces
        unsubscribed:
          type: integer
          description: Number of unsubscribes
        global_unsubscribed:
          type: integer
          description: Number of global unsubscribes
  responses:
    Unauthorized:
      description: Unauthorized
      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

````