Lumaktaw sa pangunahing nilalaman

Mga workflow

Ang workflow ay automation na pinapatakbo ng produkto para sa iyo: isang trigger, isang graph ng mga hakbang, at mga run na umuusad habang dumarating ang mga event. Hiwalay ang draft at paglalathala, kaya ang isinasagawa ng trapiko ay palaging bersyon na sadyang inilabas ng isang tao.

At a glance

Shape
A trigger, a graph of steps, published versions
Triggers
Manual fire, or a cohort signal
Operate
fireWorkflow, signalWorkflow, cancelWorkflow
Live updates
workflow.run on the project room
Auth
Access token; runs execute server-side
  • Ang mga trigger ay manu-manong pagpapaputok o senyales ng cohort, kaya ang 'sino' ay isang cohort sa halip na kondisyong sulat-kamay.
  • Sakop ng mga hakbang ang mga aksyon, pagkaantala, sanga at bantay na talon; ang graph na tatanggihan ng engine ay pinangangalanan bago ilathala.
  • Iniingatan ng bawat run ang dahilan nito: pinangangalanan ng paghihintay ang senyales nito, dala ng kabiguan ang error nito.

Paano ito gumagana

A definition holds a draft graph and its published versions. The draft is edited freely and saved as it changes; publishing validates the graph and makes that version the one runs execute, so an edit in progress can never leak into traffic. A run advances node by node: actions do work, delays hold, branches choose a case or the otherwise, and a waiting node parks the run until its named signal arrives, from the product or by hand. Runs, their steps and their errors are all kept, which is what the console's runs tab and the Home screen's Needs you list read.

Saan ito maaabot

SurfaceOperation
RESTNone: workflows are authored and operated, not ingested
GraphQLworkflowDefinitions, workflowRuns queries · publishWorkflowVersion, fireWorkflow, signalWorkflow, cancelWorkflow mutations
Realtimeworkflow.run on the project room, as a run advances
MCPprodantix.workflows.list

Halimbawa

Bash
curl "https://api.prodantix.com/graphql" \
  -H "Authorization: Bearer $ACCESS_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "query": "mutation ($p: String!, $d: String!) { fireWorkflow(projectId: $p, definitionId: $d) { runId } }",
    "variables": { "p": "'$PROJECT_ID'", "d": "'$DEFINITION_ID'" }
  }'