Workers & Tasks
Workers are people who fulfill orders. Tasks are the discrete jobs assigned to them.
Workers
A worker belongs to a merchant and has:
- Role —
DELIVERY,PICKUP,SERVICE,INVENTORY,CLEANUP - Status —
ACTIVE,INACTIVE,SUSPENDED - Schedule — weekly availability
- Earnings — tracked per task and aggregated
query {
listProviderWorkers(providerId: "mer_42") {
id
name
role
status
earnings
}
}
Tasks
A task is a fulfillment job tied to an order and a worker:
ASSIGNED → IN_PROGRESS → COMPLETED
→ BLOCKED
→ CANCELLED
| Field | Meaning |
|---|---|
type | DELIVERY, PICKUP, SERVICE, INVENTORY, CLEANUP |
status | ASSIGNED, IN_PROGRESS, BLOCKED, COMPLETED, CANCELLED |
priority | LOW, MEDIUM, HIGH, URGENT |
dueAt | Expected completion time |
completedAt | Actual completion time |
query {
listWorkerTasks(providerId: "mer_42") {
id
type
status
priority
orderId
workerId
dueAt
}
}