Build against an explicit contract
A utility operator must create, assign, execute, prove, review, and close work without losing responsibility during retries or offline periods.
Define the user and system contract
A utility operator must create, assign, execute, prove, review, and close work without losing responsibility during retries or offline periods. Record the region, data freshness, latency budget, privacy purpose, credential owner, and fallback before choosing an SDK or endpoint.
Model task and provider identities
Give the internal task, provider task, assignee, policy, and idempotency command independent durable IDs.
{
"externalId": "JOB-2026-004219",
"type": "equipment_inspection",
"assigneeId": "worker_1288",
"location": { "mapplsPin": "MMI000" },
"window": { "startsAt": "2026-08-17T04:30:00Z", "endsAt": "2026-08-17T06:30:00Z" },
"requiredProof": ["arrival_location", "checklist", "photo", "customer_signature"]
}Enforce explicit transitions
Validate actor, current version, prerequisites, and evidence for assign, accept, travel, arrive, submit proof, approve, rework, and close.
Reconcile asynchronous outcomes
Persist an outbox command before provider calls, ingest provider callbacks idempotently, and keep ambiguous results pending until queried or replayed.
Prove the production behavior
Automate the happy path and every named failure. The release is ready only when every transition names actor and evidence; offline replay cannot duplicate work; terminal closure retains proof and provider acknowledgement. Capture provider request identity without logging credentials or unnecessary precise location.
Failure modes you must exercise
Fail fast with a typed, user-safe outcome and preserve the original request identity.
Keep the last verified state, mark freshness honestly, and retry only within the documented idempotency boundary.
Reconcile durable local and provider evidence before declaring success or issuing a compensating command.
Timeout after a stateful command is an unknown outcome. Query by provider/idempotency identity or wait for authoritative events; do not blindly retry a new command.
Definition of done
REST production checks
Continue from source, contracts, and a full app
These links resolve to repository-derived evidence; unsupported package names and endpoints are not filled in from guesswork.
mapmyindia-intouch-android-sdkmapmyindia-workmate-apismappls-ai-apis14 verified testsRun it, break it, then observe it
Start with fixture credentials, execute the failure plan, and use request logs, usage, webhook evidence, and operational metrics before promoting traffic.