Skip to main content
POST
Preview. This endpoint is available to organisations in the Wordsmith MCP pilot. Other organisations receive 403 mcp_not_enabled. See the preview overview.
Starts building a playbook with AI, as the Wordsmith app’s playbook import does. Wordsmith reads your precedent contracts and drafts the checks, each with its instructions and standard position. Generation usually takes several minutes, so the call returns an operation straight away. See Long-running operations for how to wait for it. The operation’s resource names the new playbook. It has no checks until the operation succeeds; checks appear one by one while it runs, and progress.completed counts them. If the operation fails, Wordsmith deletes the playbook when it still has no checks. A generation cannot be cancelled. On success, result holds { "playbook_id" }. Read the checks with Get Playbook and adjust them with Update Check. Like any new playbook, it is visible only to you until you share it with Update Sharing.

Authentication

Requires an API key, or an OAuth token with playbooks:write and files:read.

Headers

string
A unique key for this request. A retry with the same key and body within 30 days returns the same operation instead of starting a second one. See Retrying safely.

Body parameters

string
required
The name of the new playbook, up to 200 characters.
string[]
required
1 to 10 example or precedent contracts, as file_ids from the files API. Signed agreements on your own terms work best: Wordsmith takes their positions as your standard. A file_id comes from Complete Upload or Import File, not from Upload URL, which returns a job_id.
integer
default:"0"
Seconds to wait for the operation to finish before responding, from 0 to 20. Generation rarely finishes this fast, so expect a running operation.
string
An HTTPS URL that receives a signed POST with the operation when it finishes. API keys only. See Callbacks.

Response

Returns 202 with the operation, of type playbook_generation. A repeat with the same Idempotency-Key returns 200 with the same operation.

Errors