Skip to content
Proud to collaborate with Microsoft for Startups

ifood.sync-settlements ​

Fetch settlements for a window, persist entities, and upsert a checkpoint

Persist a Settlements window into commerce.

Overview ​

PropertyValue
Workflow typeDag
LibraryApp-ifood
Version1.0

Input Schema ​

FieldTypeRequiredDefaultDescription
organization_uuiduuidYes—Authenticated organization UUID injected by the workflow boundary
connection_uuiduuidYes—Organization-scoped iFood CloudConnection UUID
workflow_run_idstringNo—Engine-stamped parent DAG run id
data_environmentstringNoproductionWhich iFood data set to read: 'production' (default) or 'homologation' for official iFood test records. Homologation maps to a provider-owned request header; callers never supply HTTP headers. Persisted evidence must be partitioned by this value so test and production records can never be reconciled together.
merchant_refstringYes——
start_datestringYes——
end_datestringYes——
window_keystringNo——
forcebooleanNo——
page_sizeintegerNo——

Output Schema ​

FieldTypeRequiredDefaultDescription
organization_uuiduuidYes—Authenticated organization UUID injected by the workflow boundary
connection_uuiduuidYes—Organization-scoped iFood CloudConnection UUID
workflow_run_idstringNo—Engine-stamped parent DAG run id
data_environmentstringNoproductionWhich iFood data set to read: 'production' (default) or 'homologation' for official iFood test records. Homologation maps to a provider-owned request header; callers never supply HTTP headers. Persisted evidence must be partitioned by this value so test and production records can never be reconciled together.
merchant_refstringYes——
start_datestringYes——
end_datestringYes——
window_keystringNo——
forcebooleanNo——
page_sizeintegerNo——
fetch_settlementsjsonNo——
persist_settlementsjsonNo——
upsert_checkpointjsonNo——
processed_countintegerNo——
persisted_countintegerNo——
window_countintegerNo——
last_pageintegerNo——
checkpoint_uuiduuidNo——
completed_atstringNo——
failure_reasonstringNo——
failure_typestringNo——
failed_actionstringNo——
failed_stepjsonNo——
failed_layerintegerNo——
failed_at_statestringNo——
errorstringNo——
error_typestringNo——
failed_atstringNo——
provider_request_refstringNo——
retryablebooleanNo——

DAG Layers ​

#LayerStepsCompensation
1fetchifood.fetch-settlements—
2persistdata.commerce.entity.persist-batch—
3checkpointdata.commerce.sync-checkpoint.upsert—

Execution Flow ​

Sub-workflows ​

Sub-workflowStep name
ifood.fetch-settlementsfetch_settlements
data.commerce.entity.persist-batchpersist_settlements
data.commerce.sync-checkpoint.upsertupsert_checkpoint

API Usage ​

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

{
  "workflow_type": "ifood.sync-settlements",
  "initial_data": {
    "organization_uuid": "value",
    "connection_uuid": "value",
    "merchant_ref": "value",
    "start_date": "value"
  }
}