Skip to content
Proud to collaborate with Microsoft for Startups

dgi.workflow-request.create ​

Capture a user's request for a workflow that does not exist yet

Capture a request for a workflow/capability that does not exist yet.

Inputs:

  • organization_uuid: UUID of the organization (required)
  • user_uuid: deprecated; the request is always owned by the authenticated caller
  • requested_capability: natural-language description of the desired capability (required)
  • requested_workflow_type: optional best-guess canonical workflow name
  • conversation_uuid: optional originating conversation uuid
  • source: origin surface (default "dgi")
  • context: free-form triage context snapshot

Outputs (terminal state_data):

  • request_uuid: WorkflowRequest.uuid
  • status: lifecycle status ("pending")
  • created_at: ISO-8601 timestamp

Failure reasons:

  • organization_not_found_or_unauthorized
  • validation_failed
  • database_error

Overview ​

PropertyValue
Workflow typeAtomic
LibraryApp-dgi
Version1.0

Input Schema ​

FieldTypeRequiredDefaultDescription
organization_uuiduuidYes—UUID of the organization that owns the request
user_uuiduuidNo—Deprecated. The request is always owned by the authenticated caller; this value is not used for authorization or attribution
requested_capabilitystringYes—Natural-language description of the desired capability (max 4000 chars)
requested_workflow_typestringNo—Optional best-guess canonical workflow name (max 255 chars)
conversation_uuidstringNo—Optional originating chat/DGI conversation uuid
sourcestringNo—Origin surface (default 'dgi', max 32 chars)
contextjsonNo—Free-form triage context snapshot (reasoning trace, last message, ...)

Output Schema ​

FieldTypeRequiredDefaultDescription
request_uuiduuidYes—Created WorkflowRequest.uuid (external identifier)
statusstringYes—Lifecycle status of the request (pending on creation)
created_atstringYes—ISO-8601 creation timestamp
failure_reasonstringNo—Controlled-vocabulary failure key OR raw engine message
errorstringNo—Human-readable error detail (echoed by action_fail)
error_typestringNo—Exception class name (engine-stamped)
failed_at_statestringNo—State name where the failure occurred (engine-stamped)
failed_stepstringNo—DAG step name where the failure occurred (engine-stamped)
failed_layerstringNo—DAG layer where the failure occurred (engine-stamped)
organization_uuiduuidNo—Organization UUID echoed by action_fail
user_uuiduuidNo—User UUID echoed by action_fail

States ​

StateInitialTerminalSuccessAuto-advanceDescription
pendingYesNo—execute—
completedNoYesYes——
failedNoYesNo——

State Diagram ​

Transitions ​

FromActionToDescription
pendingexecutecompleted—
* (any state)failfailed—

API Usage ​

bash
POST /api/workflows/start
Content-Type: application/json

{
  "workflow_type": "dgi.workflow-request.create",
  "initial_data": {
    "organization_uuid": "value",
    "requested_capability": "value"
  }
}