Submit a deal wizard
Creates a deal from a completed wizard run, the same deal the in-app wizard would create. Send every answer. Returns template suggestions from the wizard's rules without attaching them; attach with addTemplatesToPackage. Idempotency-Key is required.
Requires the api_deals_create scope.
Authorization
bearerAuth Bearer token using a Clai API key secret (clai_live_*).
In: header
Path Parameters
| Name | Type | Description |
|---|---|---|
orgIdrequired | string | Organization ID the key is operating in |
wizardIdrequired | string | Wizard ID from listDealWizards or matchDealWizard |
Header Parameters
| Name | Type | Description |
|---|---|---|
Idempotency-Keyrequired | string | Required client-supplied idempotency key for safe retries Length 1 <= length |
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
| Name | Type | Description |
|---|---|---|
answersrequired | object | Every answer so far, keyed by question id. Send null to skip an optional question. See each question answerFormat. |
[key: string] | any | |
definitionVersion | string |
Response Body
application/json
application/json
application/json
application/json
application/json
application/json
application/json
application/json
application/json
curl -X POST "https://app.goclai.com/api/v1/orgs/org_2abc123/wizards/starter-real-estate-deal/submit" \ -H "Idempotency-Key: 550e8400-e29b-41d4-a716-446655440000" \ -H "Content-Type: application/json" \ -d '{ "answers": { "property1": null, "property2": null } }'{
"dealId": "f480fdfe-5c44-458b-b537-f3d9f40f9678",
"name": "string",
"packageId": "471cc1d4-ec27-4504-b7c2-949af95662bc",
"dealUrl": "http://example.com",
"documentsUrl": "http://example.com",
"isTemplate": true,
"prepareUrl": "http://example.com",
"suggestedTemplates": [
{
"name": "string",
"templateDealId": "string",
"required": true,
"reason": "string"
}
],
"warnings": [
{
"step": "property_lookup",
"message": "string"
}
]
}{
"error": {
"code": "ERROR_CODE",
"message": "Human-readable error message",
"details": {}
}
}{
"error": {
"code": "ERROR_CODE",
"message": "Human-readable error message",
"details": {}
}
}{
"error": {
"code": "ERROR_CODE",
"message": "Human-readable error message",
"details": {}
}
}{
"error": {
"code": "ERROR_CODE",
"message": "Human-readable error message",
"details": {}
}
}{
"error": {
"code": "ERROR_CODE",
"message": "Human-readable error message",
"details": {}
}
}{
"error": {
"code": "ERROR_CODE",
"message": "Human-readable error message",
"details": {}
}
}{
"error": {
"code": "ERROR_CODE",
"message": "Human-readable error message",
"details": {}
}
}{
"error": {
"code": "ERROR_CODE",
"message": "Human-readable error message",
"details": {}
}
}POSTGet the next wizard question
Validates the answers so far and returns the next question to ask, required or optional. Send every answer on every call; the server keeps no run state. Answer null to skip an optional question. When the wizard binds to property data and the key holds api_deals_create, a complete address triggers a property lookup whose values come back in prefill. Requires one of `api_deals_list` or `api_deals_create`.
MCP
Connect Clai from Cursor, GrokBot, Claude, ChatGPT, and other assistants that support remote servers with sign-in.