Create Definition
POST
/api/v1/workflows/definitions
const url = 'https://api.ultimateteam.ai/api/v1/workflows/definitions';const options = { method: 'POST', headers: {'X-API-Key': '<X-API-Key>', 'Content-Type': 'application/json'}, body: '{"category":"operations","definition":{},"description":"","icon":"workflow","layout":{},"name":"example"}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://api.ultimateteam.ai/api/v1/workflows/definitions \ --header 'Content-Type: application/json' \ --header 'X-API-Key: <X-API-Key>' \ --data '{ "category": "operations", "definition": {}, "description": "", "icon": "workflow", "layout": {}, "name": "example" }'Create a new workflow definition.
Persists a workflow definition for the authenticated tenant. Requires the AUTOMATION_TEMPLATES feature gate.
Authorizations
Section titled “Authorizations”Request Bodyrequired
Section titled “Request Bodyrequired”Media typeapplication/json
CreateDefinitionRequest
Request body for creating a workflow definition.
Attributes: name: Display name for the workflow. description: Human-readable description. definition: Full WorkflowDefinition as a dict. layout: Optional visual builder layout metadata (node positions). category: Workflow category for filtering. icon: Icon identifier for UI display.
Responses
Section titled “ Responses ”Successful Response
Media typeapplication/json
Response Create Definition Api V1 Workflows Definitions Post
object
key
additional properties
any
Examplegenerated
{}Validation Error
Media typeapplication/json
HTTPValidationError
object
detail
Detail
Array<object>
ValidationErrorobject
ctx
Context
object
input
Input
loc
required
Location
Array
msg
required
Message
string
type
required
Error Type
string
Examplegenerated
{ "detail": [ { "ctx": {}, "input": "example", "loc": [ "example" ], "msg": "example", "type": "example" } ]}