# Cursor → SQLGuard (copy-paste)

**Promise:** No production SQL mutation without a signed PASS.

## 1. Buy Session ($0.50 / 5 slots)

In Cursor Agent / chat, run (or ask the agent to run):

```bash
curl -sS -X POST https://sqlguard.io/v1/session \
  -H "Content-Type: application/json" \
  -H "X-SQLGuard-Agent: YOUR_0x_WALLET" \
  -d '{"agent_id":"YOUR_0x_WALLET"}'
```

Expect **HTTP 402** → settle Exact USDC on Base to  
`0xC8d524703f1751b565a220087D1d4c44a413C1D7` (**$0.50**) → retry → store `session_token`.

## 2. Burn a slot for your SQL

```bash
curl -sS -X POST https://sqlguard.io/v1/session/cert \
  -H "Content-Type: application/json" \
  -H "X-SQLGuard-Agent: YOUR_0x_WALLET" \
  -H "X-SQLGuard-Session: SESSION_TOKEN" \
  -d '{"schema_ddl":"CREATE TABLE …","sql":"YOUR_MUTATING_SQL","agent_id":"YOUR_0x_WALLET"}'
```

## 3. Verify before execute

```bash
curl -sS -X POST https://sqlguard.io/v1/verify \
  -H "Content-Type: application/json" \
  -d '{"certificate":{…},"signature":"…"}'
```

Only if `ok: true` → execute on production.

Human wallet path: https://sqlguard.io/buy#session  
Full paste: https://sqlguard.io/INTEGRATE.md
