FARPY agent quickstart

Use the live OpenAPI document as the canonical route and schema reference.

1. Discover

curl -fsS https://farpy.com/.well-known/farpy.json | jq .
curl -fsS https://farpy.com/openapi.json | jq .
curl -fsS https://api.farpy.com/v1/capabilities | jq .

2. Authenticate

export FARPY_API_KEY="REDACTED"
curl -fsS \
  -H "Authorization: Bearer $FARPY_API_KEY" \
  https://api.farpy.com/v1/auth/me | jq .

3. Preflight the intended render

curl -fsS https://api.farpy.com/v1/renders/preflight \
  -H "Content-Type: application/json" \
  -d '{
    "engine":"CYCLES",
    "frame_start":1,
    "frame_end":1,
    "frame_count":1
  }' | jq .

4. Create the render idempotently

KEY="agent-render-$(date -u +%Y%m%dT%H%M%SZ)"

curl -fsS https://api.farpy.com/v1/renders \
  -H "Authorization: Bearer $FARPY_API_KEY" \
  -H "Idempotency-Key: $KEY" \
  -F "file=@scene.blend" \
  -F "frame_start=1" \
  -F "frame_end=1" \
  -F "frame_count=1" | tee render.json

JOB_ID=$(jq -r .job_id render.json)

5. Submit and monitor

curl -fsS -X POST \
  -H "Authorization: Bearer $FARPY_API_KEY" \
  -H "Idempotency-Key: submit-$JOB_ID" \
  "https://api.farpy.com/v1/renders/$JOB_ID/submit" | jq .

curl -fsS \
  -H "Authorization: Bearer $FARPY_API_KEY" \
  "https://api.farpy.com/v1/renders/$JOB_ID" | jq .

6. Retrieve proof and output

curl -fsS \
  -H "Authorization: Bearer $FARPY_API_KEY" \
  "https://api.farpy.com/v1/renders/$JOB_ID/download" | jq .

curl -fsS \
  -H "Authorization: Bearer $FARPY_API_KEY" \
  "https://api.farpy.com/v1/renders/$JOB_ID/receipt" | jq .

curl -fsS \
  -H "Authorization: Bearer $FARPY_API_KEY" \
  "https://api.farpy.com/v1/renders/$JOB_ID/proof" | jq .
Agents should read live capabilities before every new workload class, use a unique idempotency key per logical action, reject costs outside their delegated budget, and verify the receipt and artifact hash before continuing.

Machine contracts