# Fix file: AgentDrives (agentdrives.com)

Give this file to your coding agent with your repository. Each task says what is wrong and where, the change to make and how to check it.

## Goal

An AI agent can find AgentDrives, get in, use it, pay and leave with no person in the way. Each task below removes one thing that stopped our agent or slowed it down.

## Context

- Product: AgentDrives, https://agentdrives.com
- Driven: 23 Oct 2026 by the AgentDrives agent
- Level: L5
- Checkpoints passed: 7 of 9 (2 not needed). Attempts logged: 134
- Tasks: 7, in the order an agent meets them: Find, Get in, Use, Pay, Leave

### What the drive found at each checkpoint

| Checkpoint | Result | Note |
| --- | --- | --- |
| Docs | On its own | llms.txt, getting-started.md (text/markdown) and openapi.json (3.1.0, 89 operations), all fetched without a browser. |
| Sign up | On its own | POST /api/agents/signup {agent} returned a key at once, with no email, browser or CAPTCHA (201). |
| Verify | Not needed | Not needed: a documented route works without an account. |
| Key | On its own | The key comes in the sign-up answer. On the email-code account a key was created, used and revoked over the API (revoked key 401). |
| First call | On its own | GET /api/me with x-api-key: 200. |
| First action | On its own | POST /api/orders {product:free,url:https://postman-echo.com}: 201, order queued. |
| Pay | On its own | Every paid order (Audit $499, Builder $49/month, Tool comparison $490, credit $5, find-tools $0.01) answers 402 on its own order URL, with PAYMENT-REQUIRED x402 v2 and WWW-Authenticate Payment (MPP … |
| Cancel | Not needed | Nothing to cancel: our agent used it pay-per-call. |
| Delete | On its own | POST /api/auth/delete-user twice (202 confirm token, then 200 deleted). The key then got 401; all five accounts were deleted, and passwords and sessions refused. |

## How to work

1. Do the tasks in order. A later task may need an earlier one.
2. Change only what a task names. If a task doesn't fit this codebase, say so and skip it.
3. After each task, run its check. Tick the box only when the check passes.
4. Never weaken a security control, a rate limit or a terms rule to make a check pass.

## Tasks

### 1. [ ] Document error responses on every operation

Step: Find · Effort: M · Owner: Docs

**Where:** `openapi.json`

**Why it stops an agent:** Agents can plan recovery from the spec alone.

**Change:** Add 400/401/403/404/409/429 responses with problem+json examples to the operations that lack them in openapi.json.

**Check:**

- Run and read the answer:

  ```sh
  curl -sS -i 'https://agentdrives.com/openapi.json'
  ```

### 2. [ ] Accept the Bearer session on every session route

Step: Get in · Effort: S · Owner: Engineering

**Where:** `POST /api/me/password`

**Why it stops an agent:** getting-started treats the code sign-in's Bearer token as a session; one route refuses it with no fix.

**Change:** Accept Authorization: Bearer on POST /api/me/password, or document the cookie requirement and give the 403 a detail and fix.

**Check:**

- Run and read the answer:

  ```sh
  curl -sS -i -X POST \
    -H "Authorization: Bearer $API_KEY" \
    -H 'content-type: application/json' \
    -d '{}' \
    'https://agentdrives.com/api/me/password'
  ```

### 3. [ ] Let register-record owners read their drive detail

Step: Get in · Effort: S · Owner: Engineering

**Where:** `GET /api/detail/{slug}`

**What our agent saw:**

- GET /api/export; GET /api/detail/stripe: plan gated. GET /api/export 403 problem+json plan: "The bulk export comes with Team ($290 a month). Order it: POST /api/orders {product:team}..."; GET /api/detail/stripe 403 owner_only.

**Why it stops an agent:** A verified owner whose product is not in the directory gets unknown_tool from drive_detail.

**Change:** Resolve the owner's claim (domain or register slug) in GET /api/detail/{slug} and MCP drive_detail, as /api/me/reports/{slug} already does.

**Check:**

- Run and read the answer:

  ```sh
  curl -sS -i 'https://agentdrives.com/api/detail/{slug}'
  ```

### 4. [ ] Make the free check finish or explain delays

Step: Use · Effort: S · Owner: Engineering

**Where:** `GET /api/orders/{id}/report`, `GET /api/orders`

**What our agent saw:**

- POST /api/orders {product:free,url:https://agentdrives.com}: failed. 200 {"order":null,"queued":false,"check":{"domain":"agentdrives.com","checked_at":"2026-10-11...","yours":false},"next_free_at":"2027-01-09..."}: one free check per domain every 90 days, already used.
- GET /api/orders/{id}/report, polled 05:42-06:54: failed. Every poll 200 {"ready":false,"state":"running","mode":"scan","report":null}; GET /api/orders check_state "late" from about 20 min on; no result after 79 minutes.

**Why it stops an agent:** An agent that orders a check gets no result and no reason, so it cannot finish the core task.

**Change:** Run free checks within the documented 1-5 minutes, or have GET /api/orders/{id}/report return check_state late with a reason and an estimated time (and the same state as GET /api/orders).

**Check:**

- Run and read the answer:

  ```sh
  curl -sS -i \
    -H "Authorization: Bearer $API_KEY" \
    'https://agentdrives.com/api/orders/{id}/report'
  curl -sS -i \
    -H "Authorization: Bearer $API_KEY" \
    'https://agentdrives.com/api/orders'
  ```

### 5. [ ] Open a support case on low-match questions

Step: Use · Effort: S · Owner: Product

**Where:** `POST /api/support/ask`

**What our agent saw:**

- POST /api/support/ask {question:"Why is Stripe at level 3, and where did the agent stop on its drive?"}: partial. 200 answered:true match 0.69 but the answer lists the 33 MCP tools (source tools.mcp, /data#mcp): it does not answer the question about Stripe's drive, and no case …
- POST /api/support/ask {question:"How often is a product in the directory driven again?"}: partial. 200 answered:true match 0.54, answer quotes listing.listed.2 ("Our directory lists every product our agent has driven, by level...") which does not say how often; no case opened.

**Why it stops an agent:** Agents get confident but unrelated answers to drive questions and stop asking.

**Change:** In POST /api/support/ask, answer only above a match threshold (e.g. 0.8) and open a case below it; make the ask answer and case_status report the same state.

**Check:**

- Run and read the answer:

  ```sh
  curl -sS -i -X POST \
    -H 'content-type: application/json' \
    -d '{}' \
    'https://agentdrives.com/api/support/ask'
  ```

### 6. [ ] Send RateLimit headers on keyed calls

Step: Use · Effort: S · Owner: Engineering

**Where:** https://agentdrives.com

**Why it stops an agent:** An agent could pace itself instead of hitting an hour-long 429 after 100 calls.

**Change:** Add RateLimit and RateLimit-Policy (draft -11) to every keyed response, and count Retry-After from the window's start rather than from the refused call.

**Check:**

- Make the call the task names the way an agent would (no browser, no person) and confirm the change is there.

### 7. [ ] Show one price on the 402 and card checkout

Step: Pay · Effort: S · Owner: Billing

**Where:** https://agentdrives.com

**Why it stops an agent:** The docs promise the same price including VAT, while Stripe Checkout adds 21% on top.

**Change:** Use VAT-inclusive Stripe prices, or state in getting-started that card checkout adds VAT.

**Check:**

- Make the call the task names the way an agent would (no browser, no person) and confirm the change is there.

## Security

The drive's security findings go to the owner privately and are not in this file.

## When every task is done

Run the free check on agentdrives.com again: https://agentdrives.com/scan
