← Gilde

Automation API

The personal installation has three views of the same jobs: Chat, Board and this API. API jobs use the project's memory, budget, approval mode and quality checks. This is a project-scoped personal API; hosted customer tenancy is a separate product.

Authentication

Create a key in Settings → Automation API. Store it outside source control. Send Authorization: Bearer YOUR_KEY on every /v1 request. Keys are shown once and can be revoked in Settings. Each key can access only its chosen project.

Create a job

Use a unique Idempotency-Key for each intended job. A retry with the same key and body returns the original job ID.

curl -X POST "$GILDE_URL/v1/jobs" \
  -H "Authorization: Bearer $GILDE_TOKEN" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: campaign-2026-10-01" \
  -d '{"project_id":"PROJECT_ID","title":"October newsletter","brief":"Write one October newsletter: subject, preview and body."}'

Response: {"id":"JOB_ID","replayed":false}. The job is queued; the request does not wait for model production.

Read progress and delivery

GET /v1/projects
GET /v1/jobs
GET /v1/jobs/{job_id}
GET /v1/jobs/{job_id}/files/{file_id}

The job response includes status, steps, quality, invocations and any delivery. Poll the job; statuses include queued, running, input, review, blocked, done and cancelled. Files use the same bearer key. review means the owner needs to decide; it does not guarantee a quality pass. Check quality.state (passed, failed or pending), quality.approved, quality.artifact_sha256 and quality.notes before consuming a delivery automatically.

Answer or decide

POST /v1/jobs/{job_id}/actions
{"task_id":"STEP_ID","action":"answer","answer":"The audience is local subscribers."}
{"task_id":"STEP_ID","action":"approve"}
{"task_id":"STEP_ID","action":"revise","feedback":"Shorten the opening."}

The step ID comes from GET /v1/jobs/{job_id}. Supported actions are answer, approve, revise, reopen and retry, subject to the step's status. A failed final quality check requires a nonempty feedback reason when approving; the quality state remains failed. Approving a delivery is internal only; Gilde does not publish or send it.