Create or update a campaign
Make an authorized change through your connected assistant.
outwrite_save_campaignoutwrite_save_campaign
Save an independent campaign schedule, feed and destination (a connected target key, or "draft" to keep articles as drafts in outwrite.ai with no website). Full selects/writes/publishes; planned publishes only chosen ideas; review writes for approval. May authorize recurring credit use and future publishing. Requires Pro publishing access even when disabled, because schedule and destination define future delivery. Review frequency, batch size and destination with the user first. Optional templateRotation lists ordered templateId/templateValues entries: none is automatic, one fixed, several rotate per article. Reordering restarts future articles at the top; queued snapshots stay unchanged. Requires explicit user intent, confirm:true, a UUID idempotencyKey and maximumCredits for this immediate action. Recurring settings require recurringConsent:true after the user approves their ongoing costs. Retry identical arguments with the same key; inspect an uncertain receipt before any new action.
Access and behavior
| Property | Value |
|---|---|
| Permission | pro:publish |
| Effect | Can change your workspace |
Read the current workspace state before making a change. Respect the returned proposal, revision and operation state rather than assuming the request has finished.
Parameters
| Parameter | Required | Type | Details |
|---|---|---|---|
workspaceId | Optional | string | Format: uuid. |
input | Required | object | See the complete schema below. |
idempotencyKey | Required | string | Format: uuid. |
confirm | Required | boolean | Value: true. |
maximumCredits | Required | number | Minimum 0. Maximum 100000. |
recurringConsent | Optional | boolean | Default: false. |
Complete input schema
The schema is generated from the registered tool contract. Account permissions, revision checks and cross-field validation also apply on the server.
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {
"workspaceId": {
"type": "string",
"format": "uuid",
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
},
"input": {
"type": "object",
"properties": {
"id": {
"type": "string",
"format": "uuid",
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
},
"version": {
"default": 0,
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"brandId": {
"type": "string",
"format": "uuid",
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
},
"name": {
"type": "string",
"minLength": 1,
"maxLength": 100
},
"templateId": {
"anyOf": [
{
"type": "string",
"format": "uuid",
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
},
{
"type": "null"
}
]
},
"templateValues": {
"type": "object",
"propertyNames": {
"type": "string",
"pattern": "^[a-z][a-z0-9_]{0,29}$"
},
"additionalProperties": {
"type": "string",
"maxLength": 300
}
},
"templateRotation": {
"maxItems": 10,
"type": "array",
"items": {
"type": "object",
"properties": {
"templateId": {
"type": "string",
"format": "uuid",
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
},
"templateValues": {
"default": {},
"type": "object",
"propertyNames": {
"type": "string",
"pattern": "^[a-z][a-z0-9_]{0,29}$"
},
"additionalProperties": {
"type": "string",
"maxLength": 300
}
}
},
"required": [
"templateId"
],
"additionalProperties": false
}
},
"feedId": {
"anyOf": [
{
"type": "string",
"format": "uuid",
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
},
{
"type": "string",
"const": "managed"
}
]
},
"mode": {
"type": "string",
"enum": [
"full",
"planned",
"review"
]
},
"targetKey": {
"type": "string",
"minLength": 1,
"maxLength": 200
},
"publishMode": {
"default": "publish",
"type": "string",
"enum": [
"draft",
"publish"
]
},
"timezone": {
"type": "string",
"maxLength": 80
},
"localTime": {
"type": "string",
"pattern": "^(?:[01]\\d|2[0-3]):[0-5]\\d$"
},
"intervalDays": {
"type": "integer",
"minimum": 1,
"maximum": 30
},
"batchSize": {
"type": "integer",
"minimum": 1,
"maximum": 10
},
"enabled": {
"default": false,
"type": "boolean"
}
},
"required": [
"id",
"brandId",
"name",
"feedId",
"mode",
"targetKey",
"timezone",
"localTime",
"intervalDays",
"batchSize"
],
"additionalProperties": false
},
"idempotencyKey": {
"type": "string",
"format": "uuid",
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
},
"confirm": {
"type": "boolean",
"const": true
},
"maximumCredits": {
"type": "number",
"minimum": 0,
"maximum": 100000
},
"recurringConsent": {
"default": false,
"type": "boolean"
}
},
"required": [
"input",
"idempotencyKey",
"confirm",
"maximumCredits"
],
"additionalProperties": false
}
Working safely
For an identical retry, reuse its idempotency key. If the saved state changed, read it again and prepare a new request. An operation that is queued or running is not complete.