daemon

Submit Job Result

Submit the result for a claimed job.

Idempotent on (job_id, claim_token). A duplicate POST returns the same shape (200 + {"status":"already_recorded"}) so a daemon that retried after a network blip doesn't double-count.

Failure responses:

  • 401 — bearer token doesn't resolve to the job's agent, or claim_token doesn't match.
  • 404 — job_id doesn't exist or isn't this daemon's.
  • 409 — job already completed with a DIFFERENT claim_token (i.e. visibility-timeout re-claimed it; the original daemon must drop its result).
post/api/v1/daemon/jobs/{job_id}/result

Request

  • Base URL: https://api.badgeia.com
  • URL: https://api.badgeia.com/api/v1/daemon/jobs/{job_id}/result
  • Auth: none declared

Path parameters

job_idstring uuid required

Request body

claim_tokenstring required

The claim_token returned at claim time.

successboolean required
latency_msinteger nullable

Round-trip latency the daemon measured against the local agent. None for synchronous failure (e.g. agent refused).

input_tokensinteger
output_tokensinteger
total_cost_usdnumber
outputstring nullable
error_messagestring nullable
retry_countinteger
error_classstring nullable
response_statusinteger nullable
error_body_excerptstring nullable
response_payloadobject nullable

Response

Successful Response

object required

Changes

No recorded changes to this operation across all 1 revision of this API.