Skip to content
Proud to collaborate with Microsoft for Startups

ifood.events.sweep ​

Run an order-event consume cycle for every active iFood connection

Fan the consume cycle out over active iFood connections.

Overview ​

PropertyValue
Workflow typeLinear
LibraryApp-ifood
Version1.0

Input Schema ​

FieldTypeRequiredDefaultDescription
organization_uuiduuidNo—Restrict the sweep to one organization. Filled from the authenticated context when the caller is organization-scoped; a platform caller may omit it to sweep every tenant.
limitintegerNo—Max connections this sweep (default 25)

Output Schema ​

FieldTypeRequiredDefaultDescription
organization_uuiduuidNo—Restrict the sweep to one organization. Filled from the authenticated context when the caller is organization-scoped; a platform caller may omit it to sweep every tenant.
limitintegerNo—Max connections this sweep (default 25)
connections_seenintegerYes——
cycles_startedlistYes—One {organization_uuid, connection_uuid, workflow_id} per started cycle
failureslistYes—Connections whose cycle could not be started, with the reason
swept_atstringYes——
failure_reasonstringNo——
failure_typestringNo——
failed_actionstringNo——
failed_stepjsonNo——
failed_layerintegerNo——
failed_at_statestringNo——
errorstringNo——
error_typestringNo——
failed_atstringNo——
provider_request_refstringNo——
retryablebooleanNo——

States ​

StateInitialTerminalSuccessAuto-advanceDescription
initiatedYesNo—execute—
executingNoNo—complete—
completedNoYesYes——
failedNoYesNo——

State Diagram ​

Transitions ​

FromActionToDescription
initiatedexecuteexecuting—
executingcompletecompleted—
* (any state)failfailed—

Outcomes ​

OutcomeTypeDescriptionState Data Keys
sweptSUCCESSA consume cycle was started per active connectionconnections_seen, cycles_started, failures
failedFAILUREThe sweep itself could not runfailure_reason, failure_type

API Usage ​

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

{
  "workflow_type": "ifood.events.sweep",
  "initial_data": {
    "organization_uuid": "value",
    "limit": 123
  }
}