WorkflowRun
WorkflowRun
wfr_1B2M2Y8AsgTpgAmY7PhCfgPossible values: [running, stopped, completed, failed]
completedworkflow object
Flujo automatizado compuesto por pasos conectados.
Identificador único del workflow.
wf_1B2M2Y8AsgTpgAmY7PhCfgNombre del workflow.
Flujo de revisión legal DSRDescripción del workflow.
Orquesta revisión legal y transición de estadoEstado de publicación del workflow.
Possible values: [draft, published]
draftCantidad total de ejecuciones históricas del workflow.
42created_by objectnullable
Identificador único del usuario de empresa que creó el workflow.
cusr_1B2M2Y8AsgTpgAmY7PhCfgNombre del usuario de empresa.
Catalina SepúlvedaEmail del usuario de empresa.
catalina@company.comsettings object
failure_alerts object
Envía un correo cuando una ejecución del workflow termina en estado failed.
falseID del paso inicial. Debe apuntar a un bloque trigger.
66f01d4f1d0b5a4f7a9c1111steps object[]
Pasos que componen el workflow.
- WorkflowStepActionBlock
- WorkflowStepConditionBlock
- WorkflowStepFilterBlock
- WorkflowStepSplitBlock
- WorkflowStepJoinBlock
- WorkflowStepSwitchBlock
- WorkflowStepDelayedActionBlock
- WorkflowStepDsrStateTransitionActionBlock
- WorkflowStepEmailActionBlock
- WorkflowStepFormBlock
- WorkflowStepHttpRequestActionBlock
- WorkflowStepProcessDsrTriggerBlock
- WorkflowStepTriggerBlock
- WorkflowStepWebhookTriggerBlock
ID del paso (Mongoid embedded document id).
66f01d4f1d0b5a4f7a9c1111ActionBlockSiguiente paso para secuencia lineal.
66f01d4f1d0b5a4f7a9c22222024-03-21T10:00:00Z2024-03-21T10:05:00ZID del paso (Mongoid embedded document id).
66f01d4f1d0b5a4f7a9c1111ConditionBlockSiguiente paso para secuencia lineal.
66f01d4f1d0b5a4f7a9c22222024-03-21T10:00:00Z2024-03-21T10:05:00Zconditions object[]required
66f01d4f1d0b5a4f7a9c6666Expresión evaluable sobre metadata del contexto. Soporta operadores ==, !=, >, >=, <, <=, contains, not contains, starts with, ends with, empty, not empty; y rutas anidadas con notación de punto (ej. person.profile.locale).
legal_review_approved == truePaso destino cuando la condición es verdadera.
66f01d4f1d0b5a4f7a9c4444false66f01d4f1d0b5a4f7a9c5555ID del paso (Mongoid embedded document id).
66f01d4f1d0b5a4f7a9c1111FilterBlockSiguiente paso para secuencia lineal.
66f01d4f1d0b5a4f7a9c22222024-03-21T10:00:00Z2024-03-21T10:05:00Zcondition objectrequired
66f01d4f1d0b5a4f7a9c6666Expresión evaluable sobre metadata del contexto. Soporta operadores ==, !=, >, >=, <, <=, contains, not contains, starts with, ends with, empty, not empty; y rutas anidadas con notación de punto (ej. person.profile.locale).
legal_review_approved == truePaso destino cuando la condición es verdadera.
66f01d4f1d0b5a4f7a9c4444falseID del paso (Mongoid embedded document id).
66f01d4f1d0b5a4f7a9c1111SplitBlockSiguiente paso para secuencia lineal.
66f01d4f1d0b5a4f7a9c22222024-03-21T10:00:00Z2024-03-21T10:05:00Zbranch_slots object[]
66f01d4f1d0b5a4f7a9c444466f01d4f1d0b5a4f7a9c2222ID del paso (Mongoid embedded document id).
66f01d4f1d0b5a4f7a9c1111JoinBlockSiguiente paso para secuencia lineal.
66f01d4f1d0b5a4f7a9c22222024-03-21T10:00:00Z2024-03-21T10:05:00Z66f01d4f1d0b5a4f7a9c3333ID del paso (Mongoid embedded document id).
66f01d4f1d0b5a4f7a9c1111SwitchBlockSiguiente paso para secuencia lineal.
66f01d4f1d0b5a4f7a9c22222024-03-21T10:00:00Z2024-03-21T10:05:00Zconditions object[]required
66f01d4f1d0b5a4f7a9c6666Expresión evaluable sobre metadata del contexto. Soporta operadores ==, !=, >, >=, <, <=, contains, not contains, starts with, ends with, empty, not empty; y rutas anidadas con notación de punto (ej. person.profile.locale).
legal_review_approved == truePaso destino cuando la condición es verdadera.
66f01d4f1d0b5a4f7a9c4444false66f01d4f1d0b5a4f7a9c5555ID del paso (Mongoid embedded document id).
66f01d4f1d0b5a4f7a9c1111DelayedActionBlockSiguiente paso para secuencia lineal.
66f01d4f1d0b5a4f7a9c22222024-03-21T10:00:00Z2024-03-21T10:05:00ZPossible values: >= 1 and <= 524160
10approval.delay_valuePossible values: [minutes, hours, days, weeks]
daysID del paso (Mongoid embedded document id).
66f01d4f1d0b5a4f7a9c1111DsrStateTransitionActionBlockSiguiente paso para secuencia lineal.
66f01d4f1d0b5a4f7a9c22222024-03-21T10:00:00Z2024-03-21T10:05:00ZPossible values: [resolve]
resolvePossible values: [approved, partially_approved, rejected]
approvedFalta validar {{data_subject_request.contact_information.email}}Hola {{data_subject_request.contact_information.email}}, tu solicitud fue resuelta.ID del paso (Mongoid embedded document id).
66f01d4f1d0b5a4f7a9c1111EmailActionBlockSiguiente paso para secuencia lineal.
66f01d4f1d0b5a4f7a9c22222024-03-21T10:00:00Z2024-03-21T10:05:00Zlegal@company.comRevisión pendienteRevisa la solicitud pendienteID del paso (Mongoid embedded document id).
66f01d4f1d0b5a4f7a9c1111FormBlockSiguiente paso para secuencia lineal.
66f01d4f1d0b5a4f7a9c22222024-03-21T10:00:00Z2024-03-21T10:05:00ZConfirm legal reviewInternal reviewer handoffCollect an internal decision before continuing.Send formPossible values: [specific_company_user, dsr_assignee]
specific_company_usercusr_1B2M2Y8AsgTpgAmY7PhCfgfields object[]required
Clave estable para almacenar la respuesta del campo.
decisionEtiqueta visible del campo en el formulario.
DecisionPossible values: [text, textarea, boolean, select]
selecttrueOpciones permitidas cuando type es select.
["approve","reject"]ID del paso (Mongoid embedded document id).
66f01d4f1d0b5a4f7a9c1111HttpRequestActionBlockSiguiente paso para secuencia lineal.
66f01d4f1d0b5a4f7a9c22222024-03-21T10:00:00Z2024-03-21T10:05:00Zhttps://api.example.com/orders/{{order.id}}Possible values: [GET, POST, PUT, PATCH, DELETE]
POSTheaders object[]
Nombre del header.
AuthorizationValor del header.
Bearer {{token}}{"status":"approved"}Possible values: >= 1 and <= 120
15expected_response_schema object[]
Ruta del campo en payload, con notación de punto para anidados.
reviewer.idPossible values: [string, integer, number, boolean, object, array, any]
stringIndica si el campo es obligatorio para disparar el workflow.
trueresponse_extractors object[]
Ruta del campo en el body de respuesta JSON.
result.ticket_idNombre de la variable extraída en metadata.
ticket_idPossible values: [string, integer, number, boolean, object, array, any]
stringIndica si el valor extraído es obligatorio.
trueID del paso (Mongoid embedded document id).
66f01d4f1d0b5a4f7a9c1111ProcessDsrTriggerBlockSiguiente paso para secuencia lineal.
66f01d4f1d0b5a4f7a9c22222024-03-21T10:00:00Z2024-03-21T10:05:00Zsettings object
ID del paso (Mongoid embedded document id).
66f01d4f1d0b5a4f7a9c1111TriggerBlockSiguiente paso para secuencia lineal.
66f01d4f1d0b5a4f7a9c22222024-03-21T10:00:00Z2024-03-21T10:05:00Zsettings object
ID del paso (Mongoid embedded document id).
66f01d4f1d0b5a4f7a9c1111WebhookTriggerBlockSiguiente paso para secuencia lineal.
66f01d4f1d0b5a4f7a9c22222024-03-21T10:00:00Z2024-03-21T10:05:00Zsettings object
Token público generado para recibir llamadas webhook.
whk_YWJjMTIzZXhhbXBsZV90b2tlbgexpected_payload_schema object[]
Campos del payload esperados para disparar el workflow.
Ruta del campo en payload, con notación de punto para anidados.
reviewer.idPossible values: [string, integer, number, boolean, object, array, any]
stringIndica si el campo es obligatorio para disparar el workflow.
true2024-03-21T10:00:00Z2024-03-21T10:05:00ZVersión del workflow capturada al iniciar la ejecución.
3workflow_snapshot object
wf_1B2M2Y8AsgTpgAmY7PhCfgCustomer OnboardingOrquesta revisión legal y transición de estadopublishedsettings object
failure_alerts object
Envía un correo cuando una ejecución del workflow termina en estado failed.
false66f01d4f1d0b5a4f7a9c1111pending_form_submissions object[]
66f01d4f1d0b5a4f7a9c888866f01d4f1d0b5a4f7a9c1111branch_166f01d4f1d0b5a4f7a9c3333Possible values: [pending, submitted]
pendingConfirm legal reviewCollect an internal decision before continuing.Send formfields object[]
Clave estable para almacenar la respuesta del campo.
decisionEtiqueta visible del campo en el formulario.
DecisionPossible values: [text, textarea, boolean, select]
selecttrueOpciones permitidas cuando type es select.
["approve","reject"]values object
Possible values: [specific_company_user, dsr_assignee]
specific_company_usercusr_1B2M2Y8AsgTpgAmY7PhCfgreviewer@company.comAda Lovelace2024-03-21T10:00:00Z2024-03-21T10:05:00Zcontext object
66f01d4f1d0b5a4f7a9c777766f01d4f1d0b5a4f7a9c2222run_results object[]
66f01d4f1d0b5a4f7a9c1111Estado registrado para la ejecución del paso.
successDSR trigger block firedbranch_12024-03-21T10:00:00Zstep_events object[]
66f01d4f1d0b5a4f7a9c1111Estado normalizado de ejecución para el paso.
Possible values: [started, running, completed, stopped, failed]
completedEmail sent successfullyPaso de destino resuelto después de ejecutar el bloque.
66f01d4f1d0b5a4f7a9c2222Duración de ejecución del paso en milisegundos.
153branch_12024-03-21T10:00:00Zmetadata object
branch_states object
property name* WorkflowBranchState
branch_166f01d4f1d0b5a4f7a9c2222waiting66f01d4f1d0b5a4f7a9c3333branch_1__root__66f01d4f1d0b5a4f7a9c2222metadata object
join_states object
property name* WorkflowJoinState
66f01d4f1d0b5a4f7a9c999966f01d4f1d0b5a4f7a9c3333__root__waiting2024-03-21T10:00:00Z2024-03-21T10:00:05ZDuración en segundos.
5.342024-03-21T10:00:00Z2024-03-21T10:00:05Z{
"id": "wfr_1B2M2Y8AsgTpgAmY7PhCfg",
"status": "completed",
"workflow": {
"id": "wf_1B2M2Y8AsgTpgAmY7PhCfg",
"name": "Flujo de revisión legal DSR",
"description": "Orquesta revisión legal y transición de estado",
"status": "draft",
"runs_count": 42,
"created_by": {
"id": "cusr_1B2M2Y8AsgTpgAmY7PhCfg",
"name": "Catalina Sepúlveda",
"email": "catalina@company.com"
},
"settings": {
"failure_alerts": {
"enabled": false
}
},
"starting_step_id": "66f01d4f1d0b5a4f7a9c1111",
"steps": [
{
"id": "66f01d4f1d0b5a4f7a9c1111",
"type": "string",
"next_step_id": "66f01d4f1d0b5a4f7a9c2222",
"created_at": "2024-03-21T10:00:00Z",
"updated_at": "2024-03-21T10:05:00Z"
},
{
"id": "66f01d4f1d0b5a4f7a9c1111",
"type": "string",
"next_step_id": "66f01d4f1d0b5a4f7a9c2222",
"created_at": "2024-03-21T10:00:00Z",
"updated_at": "2024-03-21T10:05:00Z",
"conditions": [
{
"id": "66f01d4f1d0b5a4f7a9c6666",
"expression": "legal_review_approved == true",
"step_id": "66f01d4f1d0b5a4f7a9c4444",
"_destroy": false
}
],
"else_step_id": "66f01d4f1d0b5a4f7a9c5555"
},
{
"id": "66f01d4f1d0b5a4f7a9c1111",
"type": "string",
"next_step_id": "66f01d4f1d0b5a4f7a9c2222",
"created_at": "2024-03-21T10:00:00Z",
"updated_at": "2024-03-21T10:05:00Z",
"condition": {
"id": "66f01d4f1d0b5a4f7a9c6666",
"expression": "legal_review_approved == true",
"step_id": "66f01d4f1d0b5a4f7a9c4444",
"_destroy": false
}
},
{
"id": "66f01d4f1d0b5a4f7a9c1111",
"type": "string",
"next_step_id": "66f01d4f1d0b5a4f7a9c2222",
"created_at": "2024-03-21T10:00:00Z",
"updated_at": "2024-03-21T10:05:00Z",
"branch_slots": [
{
"id": "66f01d4f1d0b5a4f7a9c4444",
"step_id": "66f01d4f1d0b5a4f7a9c2222"
}
]
},
{
"id": "66f01d4f1d0b5a4f7a9c1111",
"type": "string",
"next_step_id": "66f01d4f1d0b5a4f7a9c2222",
"created_at": "2024-03-21T10:00:00Z",
"updated_at": "2024-03-21T10:05:00Z",
"split_step_id": "66f01d4f1d0b5a4f7a9c3333"
},
{
"id": "66f01d4f1d0b5a4f7a9c1111",
"type": "string",
"next_step_id": "66f01d4f1d0b5a4f7a9c2222",
"created_at": "2024-03-21T10:00:00Z",
"updated_at": "2024-03-21T10:05:00Z",
"conditions": [
{
"id": "66f01d4f1d0b5a4f7a9c6666",
"expression": "legal_review_approved == true",
"step_id": "66f01d4f1d0b5a4f7a9c4444",
"_destroy": false
}
],
"else_step_id": "66f01d4f1d0b5a4f7a9c5555"
},
{
"id": "66f01d4f1d0b5a4f7a9c1111",
"type": "string",
"next_step_id": "66f01d4f1d0b5a4f7a9c2222",
"created_at": "2024-03-21T10:00:00Z",
"updated_at": "2024-03-21T10:05:00Z",
"delay_minutes": 10,
"delay_variable_path": "approval.delay_value",
"delay_variable_unit": "days"
},
{
"id": "66f01d4f1d0b5a4f7a9c1111",
"type": "string",
"next_step_id": "66f01d4f1d0b5a4f7a9c2222",
"created_at": "2024-03-21T10:00:00Z",
"updated_at": "2024-03-21T10:05:00Z",
"action": "resolve",
"terminal_state": "approved",
"rejection_reason_template": "Falta validar {{data_subject_request.contact_information.email}}",
"email_content_template": "Hola {{data_subject_request.contact_information.email}}, tu solicitud fue resuelta."
},
{
"id": "66f01d4f1d0b5a4f7a9c1111",
"type": "string",
"next_step_id": "66f01d4f1d0b5a4f7a9c2222",
"created_at": "2024-03-21T10:00:00Z",
"updated_at": "2024-03-21T10:05:00Z",
"to": "legal@company.com",
"subject": "Revisión pendiente",
"body": "Revisa la solicitud pendiente"
},
{
"id": "66f01d4f1d0b5a4f7a9c1111",
"type": "string",
"next_step_id": "66f01d4f1d0b5a4f7a9c2222",
"created_at": "2024-03-21T10:00:00Z",
"updated_at": "2024-03-21T10:05:00Z",
"title": "Confirm legal review",
"description": "Internal reviewer handoff",
"form_description": "Collect an internal decision before continuing.",
"submit_button_label": "Send form",
"recipient_type": "specific_company_user",
"recipient_company_user_token": "cusr_1B2M2Y8AsgTpgAmY7PhCfg",
"fields": [
{
"key": "decision",
"label": "Decision",
"type": "select",
"required": true,
"options": [
"approve",
"reject"
]
}
]
},
{
"id": "66f01d4f1d0b5a4f7a9c1111",
"type": "string",
"next_step_id": "66f01d4f1d0b5a4f7a9c2222",
"created_at": "2024-03-21T10:00:00Z",
"updated_at": "2024-03-21T10:05:00Z",
"url": "https://api.example.com/orders/{{order.id}}",
"method": "POST",
"headers": [
{
"key": "Authorization",
"value": "Bearer {{token}}"
}
],
"body": "{\"status\":\"approved\"}",
"timeout_seconds": 15,
"expected_response_schema": [
{
"path": "reviewer.id",
"type": "string",
"required": true
}
],
"response_extractors": [
{
"path": "result.ticket_id",
"key": "ticket_id",
"type": "string",
"required": true
}
]
},
{
"id": "66f01d4f1d0b5a4f7a9c1111",
"type": "string",
"next_step_id": "66f01d4f1d0b5a4f7a9c2222",
"created_at": "2024-03-21T10:00:00Z",
"updated_at": "2024-03-21T10:05:00Z",
"settings": {}
},
{
"id": "66f01d4f1d0b5a4f7a9c1111",
"type": "string",
"next_step_id": "66f01d4f1d0b5a4f7a9c2222",
"created_at": "2024-03-21T10:00:00Z",
"updated_at": "2024-03-21T10:05:00Z",
"settings": {}
},
{
"id": "66f01d4f1d0b5a4f7a9c1111",
"type": "string",
"next_step_id": "66f01d4f1d0b5a4f7a9c2222",
"created_at": "2024-03-21T10:00:00Z",
"updated_at": "2024-03-21T10:05:00Z",
"settings": {},
"public_webhook_token": "whk_YWJjMTIzZXhhbXBsZV90b2tlbg",
"expected_payload_schema": [
{
"path": "legal_review_approved",
"type": "boolean",
"required": true
},
{
"path": "reviewer.id",
"type": "string",
"required": true
}
]
}
],
"created_at": "2024-03-21T10:00:00Z",
"updated_at": "2024-03-21T10:05:00Z"
},
"workflow_version": 3,
"workflow_snapshot": {
"token": "wf_1B2M2Y8AsgTpgAmY7PhCfg",
"name": "Customer Onboarding",
"description": "Orquesta revisión legal y transición de estado",
"status": "published",
"settings": {
"failure_alerts": {
"enabled": false
}
},
"starting_step_id": "66f01d4f1d0b5a4f7a9c1111",
"steps": [
{}
]
},
"pending_form_submissions": [
{
"id": "66f01d4f1d0b5a4f7a9c8888",
"step_id": "66f01d4f1d0b5a4f7a9c1111",
"branch_id": "branch_1",
"split_step_id": "66f01d4f1d0b5a4f7a9c3333",
"status": "pending",
"title": "Confirm legal review",
"description": "Collect an internal decision before continuing.",
"submit_button_label": "Send form",
"fields": [
{
"key": "decision",
"label": "Decision",
"type": "select",
"required": true,
"options": [
"approve",
"reject"
]
}
],
"values": {},
"recipient_type": "specific_company_user",
"recipient_company_user_token": "cusr_1B2M2Y8AsgTpgAmY7PhCfg",
"recipient_email": "reviewer@company.com",
"recipient_name": "Ada Lovelace",
"requested_at": "2024-03-21T10:00:00Z",
"submitted_at": "2024-03-21T10:05:00Z"
}
],
"context": {
"id": "66f01d4f1d0b5a4f7a9c7777",
"error": "string",
"current_step_id": "66f01d4f1d0b5a4f7a9c2222",
"run_results": [
{
"step_id": "66f01d4f1d0b5a4f7a9c1111",
"status": "success",
"message": "DSR trigger block fired",
"branch_id": "branch_1",
"timestamp": "2024-03-21T10:00:00Z"
}
],
"step_events": [
{
"step_id": "66f01d4f1d0b5a4f7a9c1111",
"status": "completed",
"message": "Email sent successfully",
"next_step_id": "66f01d4f1d0b5a4f7a9c2222",
"duration_ms": 153,
"branch_id": "branch_1",
"timestamp": "2024-03-21T10:00:00Z"
}
],
"metadata": {},
"branch_states": {},
"join_states": {}
},
"started_at": "2024-03-21T10:00:00Z",
"completed_at": "2024-03-21T10:00:05Z",
"duration": 5.34,
"created_at": "2024-03-21T10:00:00Z",
"updated_at": "2024-03-21T10:00:05Z"
}