Skip to main content
Use the Auto Improve API to investigate a production problem and, when Agnost AI finds a safe code-level fix, open a pull request in your GitHub repository.

Before you start

You need:
  • An organization API key from Settings → API Keys.
  • The Agnost AI GitHub App connected to the organization.
  • Auto Improve enabled with a target repository.
Send the key in the x-api-key header. Do not send an organization ID: Agnost AI derives the organization from the key.

Start a run

Choose exactly one input:
  • alert_id runs an existing alert again. The alert must belong to the API key’s organization.
  • title and description describe an ad-hoc problem. title supports up to 200 characters and description up to 4,000.
For an ad-hoc problem, conversation_ids is optional. You can include up to 20 conversations from the same organization as supporting evidence. repo is also optional and must be accessible to the organization’s GitHub App installation; otherwise Auto Improve uses the repository selected in Settings. A successful request returns 202 Accepted:

Check progress

Poll the returned run ID:

Limits and errors

Each organization can start up to 5 runs per hour and 20 runs per day. When a limit is reached, the API returns 429 and a Retry-After header containing the number of seconds to wait.
An accepted run can still be skipped by Auto Improve’s repository safeguards, duplicate-PR protection, configured daily limit, or per-alert cooldown.
For the full workflow and pull request review guidance, see Improvements.