3 Build and run your first complete service
The client sends JSON containing one text field and an Idempotency-Key header. A configured bearer token identifies its tenant. The API validates the input, inserts a job in a transaction, and returns HTTP 202 with an ID. A worker processes the job.
- Start with the contract
- Understand the files
- Install and initialize
- Explain the implementation
- Run the tests
- Failure exercises
- Exit and cleanup
Outcome: submit a durable job and retrieve its result. Prerequisites: Python basics and terminal navigation. Environment: your laptop, Python 3.12 and uv, from the included examples/automation-service directory. Cost: no paid API calls. Proof: API and worker tests are recorded in the companion verification report. The client sends JSON containing one text field and an Idempotency-Key header. A configured bearer token identifies its tenant. The API validates the input, inserts a job in a transaction, and returns HTTP 202 with an ID. A worker processes the job. The client polls GET /jobs/{id} until it succeeds or fails. The same tenant and idempotency key identify the same request. Reusing the key with identical input returns the existing job. Reusing it with different input returns 409. Another tenant cannot read the first tenant's job, even with its UUID.