Tools: Deals
create_deal
Create a deal (opportunity) in the pipeline. Search first: if a deal for this company and purpose already exists, use update_deal instead.
| Group | Deals |
| Scope | crm:write |
| Who can call it | Agents and people with this scope. |
| Kind | Write. Recorded in the change history with who made it. |
| Retries | Pass idempotency_key (MCP) or the Idempotency-Key header (REST); a retry with the same key within 24 hours returns the first result. |
| Widget | In hosts that support MCP Apps, the result shows where the write landed (the changed record, the pipeline, or the updated list). |
Parameters
| Parameter | Type | Required | Notes |
|---|---|---|---|
name | string | yes | |
stage | string | no | One of: lead, qualified, proposal, negotiation, won, lost. |
amount | number | no | Deal value in major units, e.g. 12500 for $12,500. |
currency | string | no | max 3 characters |
company_id | id (uuid) | no | |
contacts | array of object { person_id, role? } | no | People on the deal and their roles. Add more later with set_deal_contact.. max 20 items |
contacts[].person_id | id (uuid) | yes | |
contacts[].role | string | no | Their part in the deal. One of: champion, decision_maker, economic_buyer, technical_evaluator, influencer, user, blocker. |
custom | object | no | Values for this workspace's custom fields, by key (see describe_schema). Checked against each field's type; null clears one. |
source | object { name, url? } | no | |
source.name | string | yes | max 100 characters |
source.url | string | no |
Call it over MCP
{
"jsonrpc": "2.0",
"id": 1,
"method": "tools/call",
"params": {
"name": "create_deal",
"arguments": {
"name": "…",
"idempotency_key": "log-call-acme-2026-11-02"
}
}
}
Send it to https://api.tandemcrm.app/mcp (streamable HTTP). Most people never write this by hand: their agent picks the tool from its description.
Call it over REST
curl -X POST https://api.tandemcrm.app/v1/ops/create_deal \
-H "Authorization: Bearer $TANDEM_API_KEY" \
-H "Content-Type: application/json" \
-H "Idempotency-Key: log-call-acme-2026-11-02" \
-d '{"name":"…"}'
Input schema
The JSON Schema the MCP server advertises for this tool (over MCP it also accepts idempotency_key):
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {
"name": {
"type": "string",
"minLength": 1
},
"stage": {
"description": "One of: lead, qualified, proposal, negotiation, won, lost.",
"type": "string"
},
"amount": {
"type": "number",
"minimum": 0,
"description": "Deal value in major units, e.g. 12500 for $12,500."
},
"currency": {
"type": "string",
"minLength": 3,
"maxLength": 3
},
"company_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)$"
},
"contacts": {
"description": "People on the deal and their roles. Add more later with set_deal_contact.",
"maxItems": 20,
"type": "array",
"items": {
"type": "object",
"properties": {
"person_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)$"
},
"role": {
"description": "Their part in the deal. One of: champion, decision_maker, economic_buyer, technical_evaluator, influencer, user, blocker.",
"type": "string"
}
},
"required": [
"person_id"
]
}
},
"custom": {
"type": "object",
"propertyNames": {
"type": "string"
},
"additionalProperties": {},
"description": "Values for this workspace's custom fields, by key (see describe_schema). Checked against each field's type; null clears one."
},
"source": {
"type": "object",
"properties": {
"name": {
"type": "string",
"minLength": 1,
"maxLength": 100
},
"url": {
"type": "string",
"pattern": "^https?:\\/\\/"
}
},
"required": [
"name"
]
}
},
"required": [
"name"
]
}