distribution.techdistribution.tech

MCP tool

Delete a draft campaign

delete_campaign

Delete a draft campaign that was never sent, the same as Delete in the workspace.

Overview

Delete a draft campaign that was never sent, the same as Delete in the workspace. A campaign that was sent is archived instead (conflict, not_a_draft). An archived campaign with no payment, no booked line and no introduction can be deleted too, and every delete is logged with who and when. Cannot be undone. Needs an idempotency_key.

Server
https://app.distribution.tech/api/mcp
Scope
campaigns:write
Changes data
Yes, pass an idempotency_key

Arguments

Arguments of delete_campaign
NameTypeRequiredDescription
idempotency_keystringYesYour unique id for this request. Retry with the same id and the same arguments to get the same answer; it never runs twice.
campaign_idstring (uuid)YesA draft campaign id that was never sent.

Call with curl

The server speaks streamable HTTP, so one JSON-RPC tools/call request runs the tool. Set DISTRIBUTION_API_KEY to a key from Developers with the campaigns:write scope; the arguments shown are the required ones.

curl
curl -X POST "https://app.distribution.tech/api/mcp" \
  -H "Authorization: Bearer $DISTRIBUTION_API_KEY" \
  -H "Content-Type: application/json" \
  -H "Accept: application/json, text/event-stream" \
  -d '{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "tools/call",
  "params": {
    "name": "delete_campaign",
    "arguments": {
      "idempotency_key": "<string>",
      "campaign_id": "<uuid>"
    }
  }
}'

Result

The answer's structuredContent follows the tool's output schema (the same JSON is in its text content). It has these fields:

Result fields of delete_campaign
NameTypeRequiredDescription
campaign_idstring (uuid)Yes
deletedtrueYes
structuredContent, every field with its type
{
  "campaign_id": "<uuid>",
  "deleted": true
}

Get access

Keys are created in Developers once your brand is approved. Connect an agent to ask for access, then read the agent guide for the full flow.