> This page is part of EVVA for Developers (https://developers.evvahub.com), the documentation of the EVVA Partner API. The API is in developer preview and the SDK packages are not yet published: do not suggest installing them. Index: https://developers.evvahub.com/llms.txt

# Send messages in bulk

POST https://api.evvahub.com/partner/v1/bulk/messages
Content-Type: application/json

Sends up to 100 messages in one request, as one or more creators, and returns one result per item.

Every item is a single send in every respect: it follows all the rules of `POST /partner/v1/accounts/{creatorId}/conversations/{conversationId}/messages`. Only an application token can call this operation. The answer is `207` with one result per item, in request order.

**Access and authorship**

Each item is authorised on its own: its creator goes through every access check of a single send, including the `write:messages` scope. Each item must declare `authorship` (see [message authorship](/message-authorship)). `AI_AUTOMATED` needs `write:messages:automated` and `BULK_MESSAGING`; an operator's message needs `write:messages:operator` and `operatorRef`. A refusal is that item's result (`400 AUTHORSHIP_REQUIRED`, `403 AUTHORSHIP_NOT_PERMITTED`, …). The access checks and the authorship are decided once per distinct creator (and declaration) in a batch. Each item is also recorded on its own in the agency's audit trail.

**Limits**

Your application's request limit charges the batch one unit per item before it runs. Over the window, the whole batch is refused with `429` and `Retry-After`, and nothing is sent. Each item also spends the message send limits like a single send, so an item can fail alone with `429 TOO_MANY_MESSAGES`. See [rate limits](/authentication/rate-limits).

**Idempotency**

The batch `Idempotency-Key` is required. Item `i` is sent with the derived key `base64url(SHA-256("evva.bulk.messages.v1:" + batchKey + ":" + i))`.

* Retrying the batch with the same key replays each item already sent (`200`) and sends only the rest.
* A different item at the same index fails with `409 IDEMPOTENCY_KEY_REUSED` for that item.
* You can also retry one item alone through the single send, with its derived key.

There is no exactly-once promise. See [idempotency](/conventions/idempotency).

**View-once and expiring items**

An item that sets a lifetime (`viewOnce` or `expiresAt`) needs `write:messages:view_once` and goes through [action approval](/approvals) per item. The agency's policy may refuse it (`403 ACTION_DENIED_BY_POLICY`) or, under `AUTO_WITHIN_LIMITS`, send it within its own limits. Otherwise the item's result is `202 APPROVAL_REQUIRED` (`error.details.approvalId`) and nothing is sent for it: re-send that item alone through the single send, with `Partner-Approval-Id`.

**Errors**

The request as a whole is refused only for what no item could change:

* `400` — no valid batch key, or not 1 to 100 items.
* `403` — the caller is not an application.
* `403 INSUFFICIENT_SCOPE` — the token lacks the send's scopes.
* `413` — the body is over the API's 100 KB JSON limit.
* `500`, `503` — an outage mid-batch. Retry with the same key.

**Required scopes:** `write:messages`.

Reference: https://developers.evvahub.com/api-reference/bulk/send-messages

## Authentication

- `Authorization` header (bearer token, required) — OAuth 2.0 client credentials. Request an access token at `POST /partner/v1/oauth/token` (`grant_type=client_credentials`) with the application's client secret or a `private_key_jwt` assertion, then send it as `Authorization: Bearer evpa_live_…` (or `evpa_test_…` for a sandbox application). Tokens are opaque and short lived (see `expires_in`); there is no refresh token. Each operation lists the scopes it requires.

## Request

### Headers

- `Idempotency-Key` (string, required) — The key for the whole batch, required because a batch retried without one would send every message twice. 1..128 characters of `[A-Za-z0-9_-]`, otherwise `400 INVALID_REQUEST` before anything is sent. Item `i` is sent under its own key, `base64url(SHA-256("evva.bulk.messages.v1:" + key + ":" + i))` (43 characters), in your application's key space; see `bulkSendMessages`. The key is never echoed.

### Body (application/json)

This endpoint expects a BulkMessagesRequest.

- `items` (list of BulkMessagesRequestItemsItems, required)

## Response

### 207

One result per item, in request order (each item succeeds or fails on its own).

- `items` (list of BulkMessagesResultItemsItems, required) — One result per request item, in request order.

## Errors

### 400 Bad Request Error

Invalid or missing parameters: `INVALID_REQUEST` (`details` names the fields), or a more specific code of the operation.

- `code` (string, required) — A stable machine-readable code (see `KnownErrorCode`; new codes may appear within v1).
- `error` (string, required)
- `requestId` (string, required, nullable) — The same value as the `X-Request-Id` response header — quote it when reporting a problem.
- `details` (any, optional) — Extra detail for the code, specific to the operation, such as field errors, limits or the creator's account-status details.

### 401 Unauthorized Error

Token missing, malformed, expired or revoked: `INVALID_TOKEN` (or `UNAUTHORIZED` when no bearer token was sent). Request a new token and retry.

- `code` (string, required) — A stable machine-readable code (see `KnownErrorCode`; new codes may appear within v1).
- `error` (string, required)
- `requestId` (string, required, nullable) — The same value as the `X-Request-Id` response header — quote it when reporting a problem.
- `details` (any, optional) — Extra detail for the code, specific to the operation, such as field errors, limits or the creator's account-status details.

### 403 Forbidden Error

Not allowed with this token: the token lacks a scope (`INSUFFICIENT_SCOPE`), the application is not active (`APPLICATION_NOT_ACTIVE`), or its agency is suspended (`AGENCY_SUSPENDED`).

- `code` (string, required) — A stable machine-readable code (see `KnownErrorCode`; new codes may appear within v1).
- `error` (string, required)
- `requestId` (string, required, nullable) — The same value as the `X-Request-Id` response header — quote it when reporting a problem.
- `details` (any, optional) — Extra detail for the code, specific to the operation, such as field errors, limits or the creator's account-status details.

### 413 Content Too Large Error

`INVALID_REQUEST` — the body is over the API's JSON limit (100 KB); send smaller batches.

- `code` (string, required) — A stable machine-readable code (see `KnownErrorCode`; new codes may appear within v1).
- `error` (string, required)
- `requestId` (string, required, nullable) — The same value as the `X-Request-Id` response header — quote it when reporting a problem.
- `details` (any, optional) — Extra detail for the code, specific to the operation, such as field errors, limits or the creator's account-status details.

### 429 Too Many Requests Error

Rate limited: `RATE_LIMIT_EXCEEDED`. Wait `Retry-After` seconds before retrying.

- `code` (enum, required) — A stable machine-readable code (see `KnownErrorCode`; new codes may appear within v1).
  - Allowed values: `RATE_LIMIT_EXCEEDED`, `TOO_MANY_MESSAGES`
- `error` (string, required)
- `requestId` (string, required, nullable) — The same value as the `X-Request-Id` response header — quote it when reporting a problem.
- `details` (RateLimitErrorDetails, optional) — Extra detail for the code, specific to the operation, such as field errors, limits or the creator's account-status details.

### 500 Internal Server Error

Unexpected server error: `INTERNAL_ERROR`. Nothing internal is disclosed; quote the `X-Request-Id` when you report it.

- `code` (string, required) — A stable machine-readable code (see `KnownErrorCode`; new codes may appear within v1).
- `error` (string, required)
- `requestId` (string, required, nullable) — The same value as the `X-Request-Id` response header — quote it when reporting a problem.
- `details` (any, optional) — Extra detail for the code, specific to the operation, such as field errors, limits or the creator's account-status details.

### 503 Service Unavailable Error

Temporarily unavailable: `SERVICE_UNAVAILABLE`, `TEMPORARILY_UNAVAILABLE`, `MEDIA_STORAGE_UNAVAILABLE` or `CREATOR_STANDING_UNAVAILABLE`. Retry after `Retry-After` seconds.

- `code` (string, required) — A stable machine-readable code (see `KnownErrorCode`; new codes may appear within v1).
- `error` (string, required)
- `requestId` (string, required, nullable) — The same value as the `X-Request-Id` response header — quote it when reporting a problem.
- `details` (any, optional) — Extra detail for the code, specific to the operation, such as field errors, limits or the creator's account-status details.

## Types

### BulkMessagesRequestItemsItems

- `creatorId` (string, required)
- `conversationId` (string, required)
- `body` (string, required)
- `attachments` (list of string, optional)
- `viewOnce` (boolean, optional) — As `sendMessage`; an item needing approval answers `202 APPROVAL_REQUIRED`.
- `expiresAt` (datetime, optional) — CONDITIONAL per item, as `viewOnce`.
- `authorship` (enum, optional) — REQUIRED, as on `sendMessage`: `AI_AUTOMATED`, or `HUMAN_AUTHORED` / `AI_DRAFTED_HUMAN_SENT` with `operatorRef`; a missing or undeclarable one is that item's `400 AUTHORSHIP_REQUIRED` / `AUTHORSHIP_INVALID`, an unconsented one its `403 AUTHORSHIP_NOT_PERMITTED`.
  - Allowed values: `UNRECORDED`, `HUMAN_AUTHORED`, `AI_DRAFTED_HUMAN_SENT`, `AI_GENERATED_APPROVED`, `AI_AUTOMATED`, `PLATFORM_AUTOMATED`
- `operatorRef` (string, optional) — As on `sendMessage`: the external CRM's opaque operator id — required with `HUMAN_AUTHORED` / `AI_DRAFTED_HUMAN_SENT`, refused otherwise. Stored in the agency audit only.
- `fencingToken` (string, optional) — The current fencing token of the conversation's live lease, as on `sendMessage`. An application must send it while that lease is live, even as the lease holder: without it the item answers `409 LEASE_HELD`. A token that is not current is the item's `409 STALE_FENCING_TOKEN`. See [conversation leases](/conversation-leases).

### BulkMessagesResultItemsItems

- `index` (integer, required) — The item's position in the request.
- `status` (integer, required) — The status the single send would have answered for this item. * `201` — sent. * `200` — replayed (same key and item). * `202` — a conditional item, such as one with a lifetime, waits for a person, and nothing was sent. `error.code` is `APPROVAL_REQUIRED` and `error.details` is `{approvalId, status, reason, expiresAt}`. Re-send the item alone through `sendMessage` with `Partner-Approval-Id`. * `400`, `403`, `404`, `409`, `429` or `503` — the error's status.
- `message` (DirectMessage, optional)
- `error` (Error, optional) — The common error envelope. Branch on `code`; `error` is human-readable and may change.

### RateLimitErrorDetails

Extra detail for the code, specific to the operation, such as field errors, limits or the creator's account-status details.

- `retryAfterSec` (integer, required)
- `level` (enum, optional) — The DM send limit that refused the message, set only with `TOO_MANY_MESSAGES`. It is never a quota, a count or a key. - `conversation` — one side of one thread. - `sender` — a person's own ceiling; it does not apply to applications. - `creator` — everything sent for the creator, studio included. - `application` — everything your application sends. - `agency` — everything your agency sends. - `platform` — the agency's fair share of the platform: its throughput or its concurrency. See [rate limits](/authentication/rate-limits).
  - Allowed values: `conversation`, `sender`, `creator`, `application`, `agency`, `platform`

### DirectMessage

- `id` (string, required)
- `senderRole` (enum, required)
  - Allowed values: `USER`, `CREATOR`
- `body` (string, required, nullable)
- `createdAt` (datetime, required)
- `kind` (enum, required)
  - Allowed values: `UNRECORDED`, `STANDARD`, `PAID`, `PAID_BROADCAST`, `PAID_ICE_BREAKER`, `TIP`, `ICE_BREAKER`, `BROADCAST`, `AUTOMATED`
- `authorship` (enum, required)
  - Allowed values: `UNRECORDED`, `HUMAN_AUTHORED`, `AI_DRAFTED_HUMAN_SENT`, `AI_GENERATED_APPROVED`, `AI_AUTOMATED`, `PLATFORM_AUTOMATED`
- `lifetime` (DirectMessageLifetime, required, nullable)
- `media` (list of MessageMedia, required)
- `receipt` (enum, required, nullable) — The actual status of a message the creator sent; null on the fan's messages. - `sent` — the message was saved. - `delivered` — the fan's client acknowledged delivery. A realtime publish or a partner call never counts. - `read` — the fan's read position reached it, subject to the fan's receipt setting. - `purchased` — the same as `paid.purchased`, and only with `read:revenue`.
  - Allowed values: `sent`, `delivered`, `read`
- `editedAt` (datetime, required, nullable)
- `revision` (integer, required)
- `replyTo` (DirectMessageReplyTo, required, nullable) — The quoted message this one answers (on the Partner reads).
- `reactions` (list of DirectMessageReactionsItems, required) — Reaction chips folded for the creator (on the Partner reads).
- `paid` (PaidMessageTerms, required, nullable) — The PPV facet as the seller sees it, with `purchased` (on the Partner reads). The PPV send answers its own terms in `PaidMessageSendResult.paid`.
- `tip` (DirectMessageTip, required, nullable) — Always null on the Partner surface (no per-fan gross spend for an agency).
- `senderBuyerRef` (string, optional, nullable) — APPLICATIONS ONLY, on the message page — the application's pairwise pseudonym of the buyer on a message the buyer wrote (`senderRole: USER`); `null` on the creator's side.

### Error

The common error envelope. Branch on `code`; `error` is human-readable and may change.

- `code` (string, required) — A stable machine-readable code (see `KnownErrorCode`; new codes may appear within v1).
- `error` (string, required)
- `requestId` (string, required, nullable) — The same value as the `X-Request-Id` response header — quote it when reporting a problem.
- `details` (any, optional) — Extra detail for the code, specific to the operation, such as field errors, limits or the creator's account-status details.

### DirectMessageLifetime

- `viewOnce` (boolean, required)
- `opened` (boolean, required)
- `expiresAt` (datetime, required, nullable)

### MessageMedia

- `mediaAssetId` (string, required)
- `kind` (string, required)
- `position` (integer, required)
- `available` (boolean, required)
- `durationLabel` (string, required, nullable) — The media's duration, as `m:ss`.
- `width` (integer, required, nullable)
- `height` (integer, required, nullable)
- `freeSample` (boolean, required)
- `caption` (string, required, nullable)
- `displayName` (string, required, nullable)
- `sizeBytes` (integer, required)

### DirectMessageReplyTo

The quoted message this one answers (on the Partner reads).

- `id` (string, required)
- `senderRole` (enum, required)
  - Allowed values: `USER`, `CREATOR`
- `preview` (string, required)
- `hasMedia` (boolean, required)
- `retracted` (boolean, required)

### DirectMessageReactionsItems

- `kind` (string, required)
- `count` (integer, required)
- `mine` (boolean, required)

### PaidMessageTerms

- `priceMinor` (string, required)
- `currency` (string, required)
- `blurPreview` (boolean, required)
- `unlocked` (boolean, required)
- `offerExpiresAt` (datetime, optional, nullable)
- `orderRef` (string, optional, nullable) — The reader's own order — always null for the seller side.
- `purchased` (boolean, optional, nullable) — Whether the offer sold, as the seller (the creator) sees it. On the Partner reads (history, window, after, status) it is set only when the reader's consent covers `read:revenue`, because a purchase is a money fact on every channel; otherwise `null`.

### DirectMessageTip

Always null on the Partner surface (no per-fan gross spend for an agency).

- `amountMinor` (string, required)
- `currency` (string, required)
- `settled` (boolean, required)
- `payment` (enum, optional)
  - Allowed values: `OPEN`, `IN_FLIGHT`, `CLOSED`

## Examples

**Request**

```json
{
  "items": [
    {
      "creatorId": "cm4r7k2xq0001qz8w3n5v6b2d",
      "conversationId": "cm4r8a1vz0007qz8wk2j9h4mt",
      "body": "Thank you! There's more from that trip — the full set goes live on Friday.",
      "authorship": "AI_AUTOMATED",
      "fencingToken": "42"
    },
    {
      "creatorId": "cm4r7k2xq0001qz8w3n5v6b2d",
      "conversationId": "cm4r6t3pw0005qz8wh8c2v7nb",
      "body": "Good morning! A new set drops this Friday.",
      "authorship": "AI_AUTOMATED"
    },
    {
      "creatorId": "cm4s9h2kd0021qz8wm5n7p3rt",
      "conversationId": "cm4r5m9ka0004qz8wg1d6s3yf",
      "body": "Thanks for subscribing — welcome aboard!",
      "authorship": "AI_AUTOMATED"
    }
  ]
}
```

**Response**

```json
{
  "items": [
    {
      "index": 0,
      "status": 201,
      "message": {
        "id": "cm4sd3h8q002bqz8wv9k2n5wc",
        "senderRole": "CREATOR",
        "body": "Thank you! There's more from that trip — the full set goes live on Friday.",
        "createdAt": "2026-12-01T18:42:07.512Z",
        "kind": "STANDARD",
        "authorship": "AI_AUTOMATED",
        "lifetime": null,
        "media": [],
        "receipt": null,
        "editedAt": null,
        "revision": 0,
        "replyTo": null,
        "reactions": [],
        "paid": null,
        "tip": null
      }
    },
    {
      "index": 1,
      "status": 409,
      "error": {
        "code": "LEASE_HELD",
        "error": "Another sender is handling this conversation",
        "requestId": "27d8c312-489a-4812-a20d-a40d3c5bc79e"
      }
    },
    {
      "index": 2,
      "status": 403,
      "error": {
        "code": "GRANT_REVOKED",
        "error": "Creator is not linked to this agency or the grant was revoked",
        "requestId": "c7d5dc08-91b8-43f3-883b-54e8d2bd41b6"
      }
    }
  ]
}
```

**SDK Code**

```python Bulk_sendMessages_example
import requests

url = "https://api.evvahub.com/partner/v1/bulk/messages"

payload = { "items": [
        {
            "creatorId": "cm4r7k2xq0001qz8w3n5v6b2d",
            "conversationId": "cm4r8a1vz0007qz8wk2j9h4mt",
            "body": "Thank you! There's more from that trip — the full set goes live on Friday.",
            "authorship": "AI_AUTOMATED",
            "fencingToken": "42"
        },
        {
            "creatorId": "cm4r7k2xq0001qz8w3n5v6b2d",
            "conversationId": "cm4r6t3pw0005qz8wh8c2v7nb",
            "body": "Good morning! A new set drops this Friday.",
            "authorship": "AI_AUTOMATED"
        },
        {
            "creatorId": "cm4s9h2kd0021qz8wm5n7p3rt",
            "conversationId": "cm4r5m9ka0004qz8wg1d6s3yf",
            "body": "Thanks for subscribing — welcome aboard!",
            "authorship": "AI_AUTOMATED"
        }
    ] }
headers = {
    "Idempotency-Key": "ee7d072a-58f0-4e6e-8cfb-4755336ccbed",
    "Authorization": "Bearer <token>",
    "Content-Type": "application/json"
}

response = requests.post(url, json=payload, headers=headers)

print(response.json())
```

```go Bulk_sendMessages_example
package main

import (
	"fmt"
	"strings"
	"net/http"
	"io"
)

func main() {

	url := "https://api.evvahub.com/partner/v1/bulk/messages"

	payload := strings.NewReader("{\n  \"items\": [\n    {\n      \"creatorId\": \"cm4r7k2xq0001qz8w3n5v6b2d\",\n      \"conversationId\": \"cm4r8a1vz0007qz8wk2j9h4mt\",\n      \"body\": \"Thank you! There's more from that trip — the full set goes live on Friday.\",\n      \"authorship\": \"AI_AUTOMATED\",\n      \"fencingToken\": \"42\"\n    },\n    {\n      \"creatorId\": \"cm4r7k2xq0001qz8w3n5v6b2d\",\n      \"conversationId\": \"cm4r6t3pw0005qz8wh8c2v7nb\",\n      \"body\": \"Good morning! A new set drops this Friday.\",\n      \"authorship\": \"AI_AUTOMATED\"\n    },\n    {\n      \"creatorId\": \"cm4s9h2kd0021qz8wm5n7p3rt\",\n      \"conversationId\": \"cm4r5m9ka0004qz8wg1d6s3yf\",\n      \"body\": \"Thanks for subscribing — welcome aboard!\",\n      \"authorship\": \"AI_AUTOMATED\"\n    }\n  ]\n}")

	req, _ := http.NewRequest("POST", url, payload)

	req.Header.Add("Idempotency-Key", "ee7d072a-58f0-4e6e-8cfb-4755336ccbed")
	req.Header.Add("Authorization", "Bearer <token>")
	req.Header.Add("Content-Type", "application/json")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
```

```php Bulk_sendMessages_example
<?php
require_once('vendor/autoload.php');

$client = new \GuzzleHttp\Client();

$response = $client->request('POST', 'https://api.evvahub.com/partner/v1/bulk/messages', [
  'body' => '{
  "items": [
    {
      "creatorId": "cm4r7k2xq0001qz8w3n5v6b2d",
      "conversationId": "cm4r8a1vz0007qz8wk2j9h4mt",
      "body": "Thank you! There\'s more from that trip — the full set goes live on Friday.",
      "authorship": "AI_AUTOMATED",
      "fencingToken": "42"
    },
    {
      "creatorId": "cm4r7k2xq0001qz8w3n5v6b2d",
      "conversationId": "cm4r6t3pw0005qz8wh8c2v7nb",
      "body": "Good morning! A new set drops this Friday.",
      "authorship": "AI_AUTOMATED"
    },
    {
      "creatorId": "cm4s9h2kd0021qz8wm5n7p3rt",
      "conversationId": "cm4r5m9ka0004qz8wg1d6s3yf",
      "body": "Thanks for subscribing — welcome aboard!",
      "authorship": "AI_AUTOMATED"
    }
  ]
}',
  'headers' => [
    'Authorization' => 'Bearer <token>',
    'Content-Type' => 'application/json',
    'Idempotency-Key' => 'ee7d072a-58f0-4e6e-8cfb-4755336ccbed',
  ],
]);

echo $response->getBody();
```