Build task draft from recipe
POST
/ai/gateway/recipes/{id}/draftContract
Parameter | Value |
|---|---|
| Section | ai-gateway |
| Authentication | AIKeyAuth |
| Consumes | application/json |
| Produces | application/json |
Parameters
2 parameters
Name | Location | Required | Type | Description |
|---|---|---|---|---|
| id | path | yes | string | Recipe ID |
| request | body | no | object | Draft input: inputs (recipe variables), validate (boolean, true by default) |
{}
Responses
6 responses
Status | Description | Type |
|---|---|---|
200 | Successful response | object |
400 | Recipe ID is required, the request body is invalid, or the recipe does not support draft assembly | object |
401 | API key is missing or invalid | object |
403 | Required tasks:draft scope is missing or the object is outside the allowlist | object |
404 | Recipe not found | object |
500 | Internal server error | object |
{ "cursor": { "count": 0, "currentPage": 0, "totalPages": 0, "totalRows": 0 }, "data": {} }{ "data": {}, "error": "<string>" }{ "data": {}, "error": "<string>" }{ "data": {}, "error": "<string>" }{ "data": {}, "error": "<string>" }{ "data": {}, "error": "<string>" }