Optimizely Batch sending API

Create and send messages as batches to recipients segmented in separate platform

Business capability
Digital Marketing Management BC-400.60

Operations 5

Each operation below carries the questions people ask an LLM about it and the instructions they give an agent to run it. Generated by API Evangelist overlay

GET /{clientId}/sending/batches/{sendingBatchId} Check the status of a sending batch · Get information about a sending batch #
Ask an LLM
“What state is my campaign sending batch in, and which recipient list does it use?”
“Can I see which campaign a particular sending batch belongs to?”
Tell an agent
Get sending batch {sendingBatchId} for client {clientId}.
Show the state and recipient list of batch {sendingBatchId} on client {clientId}.
PUT /{clientId}/sending/batches/{sendingBatchId} Upload a chunk of recipients to a batch · Persist chunked recipients #
Ask an LLM
“How do I upload recipients to a sending batch in chunks before sending anything?”
“Can I stage recipients on a batch without starting the Optimizely campaign yet?”
Tell an agent
Add recipients {recipients} as chunk {chunk} to batch {sendingBatchId} for client {clientId}, without sending.
Stage another recipient chunk on sending batch {sendingBatchId} of client {clientId}.
POST /{clientId}/sending/batches/{sendingBatchId} Import recipients and send the batch campaign · Send campaign to the chunked recipients #
Ask an LLM
“How do I finish a sending batch and actually start the campaign going out?”
“Can I include a final chunk of recipients in the same call that sends the batch?”
Tell an agent destructive · confirm first
Import the staged recipients and send batch {sendingBatchId} for client {clientId}.
Send batch {sendingBatchId} on client {clientId}, including final recipients {recipients}, and mark it finished.
GET /{clientId}/sending/batches List all sending batches · Get information about all sending batches #
Ask an LLM
“Which sending batches exist for my client, and what state is each in?”
“Can I page through sending batches using an offset and limit?”
Tell an agent
List all sending batches for client {clientId}.
Show {limit} sending batches for client {clientId} starting at offset {offset}.
POST /{clientId}/sending/batches Prepare a new campaign sending batch · Prepares new sending batch #
Ask an LLM
“How do I set up a new sending batch from a campaign definition?”
“Does preparing a batch pick the next free recipient list from the pool automatically?”
Tell an agent
Prepare a new sending batch for client {clientId} with campaign {campaign} and action {campaignAction}.
Create a sending batch on client {clientId} tagged {tag} for campaign {campaign} using action {campaignAction}.

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/optimizely:optimizely-batch-sending-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

optimizely-batch-sending-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: Optimizely Campaign REST Batch sending API
  description: This documentation lists all available resources and endpoints of the Optimizely Campaign REST API.
  version: '1'
servers:
- url: https://api.campaign.episerver.net/rest
tags:
- name: Batch sending
  description: Create and send messages as batches to recipients segmented in separate platform
paths:
  /{clientId}/sending/batches/{sendingBatchId}:
    get:
      tags:
      - Batch sending
      summary: Get information about a sending batch
      description: Get detailed information about a sending batch, such as id, campaign, recipient list and state.
      operationId: getSendingBatch
      parameters:
      - name: clientId
        in: path
        description: Client ID
        required: true
        schema:
          type: number
      - name: sendingBatchId
        in: path
        description: Sending Batch ID
        required: true
        schema:
          type: number
      responses:
        '200':
          description: The sending batch was retrieved successfully
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/RestSendingBatch'
            application/vnd.optivo.broadmail.v1+json:
              schema:
                $ref: '#/components/schemas/RestSendingBatch'
        '404':
          description: The sending batch could not be found. Ensure that the required parameter is correct and the sending batch entry exists.
      security:
      - Authorization: []
    put:
      tags:
      - Batch sending
      summary: Persist chunked recipients
      description: Transfer recipients that will be used for the sending batch.
      operationId: addRecipients_1
      parameters:
      - name: clientId
        in: path
        description: Client ID
        required: true
        schema:
          type: number
      - name: sendingBatchId
        in: path
        description: Sending Batch ID
        required: true
        schema:
          type: number
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/RecipientsChunkRequestData'
        required: true
      responses:
        '200':
          description: Chunk with the number of pre-validated recipients.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/RestChunk'
            application/vnd.optivo.broadmail.v1+json:
              schema:
                $ref: '#/components/schemas/RestChunk'
        '400':
          description: <ul><li>the request data is not provided</li><li>chunk value is not alphanumeric (with '-' and '_' accepted) or not limited with 250 characters</li></ul>
        '404':
          description: The sending batch could not be found. Ensure that the required parameter is correct and the sending batch entry exists.
        '409':
          description: The sending batch is already sent.
      security:
      - Authorization: []
    post:
      tags:
      - Batch sending
      summary: Send campaign to the chunked recipients
      description: Imports the recipients (chunked recipients can be provided with this call as well) and starts the campaign. The sending batch is marked as finished afterwards.
      operationId: importRecipientsAndSendBatch
      parameters:
      - name: clientId
        in: path
        description: Client ID
        required: true
        schema:
          type: number
      - name: sendingBatchId
        in: path
        description: Sending Batch ID
        required: true
        schema:
          type: number
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/RecipientsChunkRequestData'
      responses:
        '202':
          description: The import of recipients is initiated, the campaign will be started after import is finished.
        '400':
          description: Chunk value is not alphanumeric (with '-' and '_' accepted) or not limited with 250 characters.
        '404':
          description: The sending batch could not be found. Ensure that the required parameter is correct and the sending batch entry exists.
        '409':
          description: <ul><li>the sending batch is already sent</li><li>the sending batch has no chunks</li><li>associated campaign is invalid</li></ul>
      security:
      - Authorization: []
  /{clientId}/sending/batches:
    get:
      tags:
      - Batch sending
      summary: Get information about all sending batches
      description: Get detailed information about all sending batches, such as id, campaign, recipient list and state.
      operationId: selectSendingBatches
      parameters:
      - name: clientId
        in: path
        description: Client ID
        required: true
        schema:
          type: number
      - name: offset
        in: query
        description: 'Starting point of the result list <p><i>Default value</i> : 0</p>'
        schema:
          type: integer
          format: int32
      - name: limit
        in: query
        description: 'Maximum number of retrieved sending batches <p><i>Default value</i> : 100</p>'
        schema:
          type: integer
          format: int32
      responses:
        '200':
          description: The sending batches were retrieved successfully (empty result if none was found).
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/RestSendingBatchStreamingCollection'
            application/vnd.optivo.broadmail.v1+json:
              schema:
                $ref: '#/components/schemas/RestSendingBatchStreamingCollection'
        '400':
          description: Invalid limit request. Change the limit to less than 10000.
      security:
      - Authorization: []
    post:
      tags:
      - Batch sending
      summary: Prepares new sending batch
      description: Creates a new sending batch based on configured campaign parameters and the next available recipient list from the pool.
      operationId: prepareNewBatch
      parameters:
      - name: clientId
        in: path
        description: Client ID
        required: true
        schema:
          type: number
      requestBody:
        content:
          multipart/form-data:
            schema:
              $ref: '#/components/schemas/PrepareSendingBatchRequest'
      responses:
        '201':
          description: The batch was prepared successfully.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/RestSendingBatch'
            application/vnd.optivo.broadmail.v1+json:
              schema:
                $ref: '#/components/schemas/RestSendingBatch'
        '400':
          description: <ul><li>the values for required parameters [campaign/campaignAction] are not provided</li><li>provided campaign value is not a number or not recognized</li><li>referenced campaign is not a master campaign</li><li>campaignAction is not recognized</li><li>tag contains unsupported characters</li></ul>
        '409':
          description: <ul><li>referenced campaign for use is already finished</li><li>Recipient List Pool is not properly configured for the client</li></ul>
      security:
      - Authorization: []
components:
  schemas:
    RestApiLink:
      type: object
      properties:
        href:
          type: string
        rel:
          type: string
    Recipient:
      type: object
      properties:
        data:
          type: object
          additionalProperties:
            type: object
        id:
          type: string
    PrepareSendingBatchRequest:
      required:
      - campaign
      - campaignAction
      type: object
      properties:
        campaign:
          type: string
          description: Campaign definition based on the value of campaignAction
        campaignAction:
          type: string
          description: Campaign action
          enum:
          - use
          - copy
        tag:
          type: string
          description: Tag reference
    RestChunk:
      type: object
      properties:
        chunk:
          type: string
        count:
          type: integer
          format: int32
    RestSendingBatchStreamingCollection:
      type: object
      properties:
        elements:
          type: array
          items:
            $ref: '#/components/schemas/RestSendingBatch'
        links:
          type: array
          writeOnly: true
          items:
            $ref: '#/components/schemas/RestApiLink'
        count:
          type: integer
          format: int32
        offset:
          type: integer
          format: int32
        limit:
          type: integer
          format: int32
    RestSendingBatch:
      type: object
      properties:
        id:
          type: integer
          description: Batch ID
          format: int64
        campaignId:
          type: integer
          description: Campaign ID
          format: int64
        recipientListId:
          type: integer
          description: Recipient list ID
          format: int64
        tag:
          type: string
          description: Tag
        chunks:
          type: array
          description: Chunks
          items:
            type: string
            description: Chunks
        state:
          type: string
          description: State
          enum:
          - initiated
          - has_recipients
          - sent
          - invalid
        links:
          type: array
          items:
            type: object
            properties:
              uriBuilder:
                type: object
              rels:
                type: array
                items:
                  type: string
              rel:
                type: string
              type:
                type: string
              params:
                type: object
                additionalProperties:
                  type: string
              title:
                type: string
              uri:
                type: string
                format: uri
    RecipientsChunkRequestData:
      type: object
      properties:
        chunk:
          type: string
        recipients:
          type: array
          items:
            $ref: '#/components/schemas/Recipient'
  securitySchemes:
    Authorization:
      type: apiKey
      name: Authorization
      in: header
x-readme:
  explorer-enabled: true
  proxy-enabled: true