Content Binding
Assign a template and sender configuration to a campaign.
Base URL: https://api.experiture.ai/public/v1
Replace Campaign Content
Replaces the content binding on a campaign — the template used to render the message, the sender profile, and the subject line (for email).
PUT /campaigns/:id/content
Authorization: Bearer <token>
Content-Type: application/jsonRequired scope: campaigns:update
Draft only. Content binding is only permitted while the campaign has authoringStatus: "draft". Attempting to update a scheduled or sent campaign returns 409 NOT_DRAFT.
Template must be published. Only templates in published status can be bound to a campaign. A draft or archived template will return 409 TEMPLATE_NOT_PUBLISHED. The template's channel must also match the campaign's channel — a direct_mail template cannot be bound to an email campaign.
Path parameters
| Name | Type | Description |
|---|---|---|
campaign_id | string (UUID) | Campaign identifier. |
Request body
| Field | Type | Required | Description |
|---|---|---|---|
templateId | string (UUID) | ✅ | ID of a published template whose channel matches the campaign channel. |
senderProfileId | string | null | — | Sender profile ID (e.g. from address for email, short code for SMS). |
subjectLine | string | null | — | Email subject line. Ignored for non-email channels. |
Example request
curl -X PUT https://api.experiture.ai/public/v1/campaigns/4130bada-9264-465f-bc0c-a26bebcfcc81/content \
-H "Authorization: Bearer <your_access_token>" \
-H "Content-Type: application/json" \
-d '{
"templateId": "bbbbbbbb-bbbb-bbbb-bbbb-bbbbbbbbbbbb",
"senderProfileId": "cccccccc-cccc-cccc-cccc-cccccccccccc",
"subjectLine": "Your spring offer is here"
}'Response — 200 OK
Returns the full campaign object reflecting the updated content binding. Same shape as Get Campaign.
Errors
| Code | HTTP | Meaning |
|---|---|---|
JOURNEY_API.PUBLIC.CAMPAIGNS.NOT_FOUND | 404 | Campaign not found in this tenant. |
JOURNEY_API.PUBLIC.CAMPAIGNS.NOT_DRAFT | 409 | Campaign is not in draft status. |
JOURNEY_API.PUBLIC.CAMPAIGNS.INVALID_CHANNEL | 409 | Campaign has no channel set — set it on create or update before binding content. |
JOURNEY_API.PUBLIC.CAMPAIGNS.CONTENT.TEMPLATE_NOT_FOUND | 404 | templateId does not exist in this tenant. |
JOURNEY_API.PUBLIC.CAMPAIGNS.CONTENT.TEMPLATE_NOT_PUBLISHED | 409 | Template is not in published status. |
JOURNEY_API.PUBLIC.CAMPAIGNS.CONTENT.CHANNEL_MISMATCH | 409 | Template channel does not match campaign channel. |
JOURNEY_API.PUBLIC.CAMPAIGNS.SUMMARY_UNAVAILABLE | 409 | Campaign is missing required persisted state. |
JOURNEY_API.AUTH.INSUFFICIENT_SCOPE | 403 | Token lacks campaigns:update. |
Constraints
- Full replacement. Each call replaces the entire content binding. To update only the subject line, re-submit
templateIdalong with the newsubjectLine. - Published templates only. Drafts and archived templates cannot be bound.
- Channel match. The template's primary channel must exactly match the campaign's channel at bind time.
- Proof status. After binding a new template,
content.proofStatusresets. Re-run preflight to check proof readiness.
See Also
- Campaign Object — create and manage campaign containers
- Audience Binding — configure who receives the campaign
- Preflight — validate template and proof are approved before send
- Campaigns Overview — lifecycle and scope reference