# Quickstart

> Coming soon

Make your first call in five minutes: create a key, set an environment variable, confirm the connection and verify a reference.

> **Note:** These steps describe the flow after launch. You can do step 1 now. Requests in the other steps return `503 coming_soon` for now.

1. **Join the waitlist**

   Join the Discord waitlist on the [API page](https://paperpurr.com/#api). If you’re logged in, you can also click Join the waitlist. We’ll announce the launch on Discord.

2. **Create a key**

   Create a key under API keys in your account and give it a name, such as the computer it’s for. If you last signed in more than 15 minutes ago, you’ll be asked to confirm it’s you first.

   > **Caution:** The full key is shown only once, when you create it. Save it to a password manager or a `.env` file right away. If it leaks, revoke it immediately.

3. **Set an environment variable**

   All examples read the key from `PAPERPURR_API_KEY`:

   macOS / Linux:

   ```bash
   export PAPERPURR_API_KEY="pp_live_..."
   ```

   Windows PowerShell:

   ```powershell
   $env:PAPERPURR_API_KEY = "pp_live_..."
   ```

4. **Confirm the connection**

   Check your usage. This endpoint is free, and a `200` means the key works:

   curl:

   ```bash
   curl "https://paperpurr.com/v1/usage" \
     -H "Authorization: Bearer $PAPERPURR_API_KEY"
   ```

   Python:

   ```python
   import os
   import requests

   r = requests.get(
       "https://paperpurr.com/v1/usage",
       headers={"Authorization": f"Bearer {os.environ['PAPERPURR_API_KEY']}"},
   )
   print(r.json())
   ```

   JS:

   ```javascript
   const r = await fetch("https://paperpurr.com/v1/usage", {
     headers: {
       Authorization: `Bearer ${process.env.PAPERPURR_API_KEY}`,
     },
   });
   console.log(await r.json());
   ```

   ```json
   {
     "plan": "std",
     "period": {
       "start": "2026-12-01T00:00:00.000Z",
       "end": "2027-01-01T00:00:00.000Z"
     },
     "trial": {
       "included": 500,
       "used": 0,
       "remaining": 500
     },
     "balance": {
       "units": 0
     },
     "rate_limit": {
       "requests": 60,
       "window_seconds": 60
     },
     "units": {
       "citations.lookup": "1 / 次",
       "citations.verify": "1 / 条（skipped、error 不计）"
     },
     "request_id": "req_8f2c1a9d4b7e03f1a6c5d290"
   }
   ```

   > **Note:** Numbers in examples are illustrative. Real allowances are announced at launch.

5. **Verify a reference**

   curl:

   ```bash
   curl -X POST "https://paperpurr.com/v1/citations/verify" \
     -H "Authorization: Bearer $PAPERPURR_API_KEY" \
     -H "Content-Type: application/json" \
     -d '{"references":["Smith, J. (2020). Title. Journal, 12(3), 45-67."]}'
   ```

   Python:

   ```python
   import os
   import requests

   r = requests.post(
       "https://paperpurr.com/v1/citations/verify",
       headers={"Authorization": f"Bearer {os.environ['PAPERPURR_API_KEY']}"},
       json={
           "references": [
               "Smith, J. (2020). Title. Journal, 12(3), 45-67."
           ]
       },
   )
   print(r.json())
   ```

   JS:

   ```javascript
   const r = await fetch("https://paperpurr.com/v1/citations/verify", {
     method: "POST",
     headers: {
       Authorization: `Bearer ${process.env.PAPERPURR_API_KEY}`,
       "Content-Type": "application/json",
     },
     body: JSON.stringify({
       "references": [
         "Smith, J. (2020). Title. Journal, 12(3), 45-67."
       ]
     }),
   });
   console.log(await r.json());
   ```

   If `results[0].status` is `matched`, you’re done. `usage.units` is what this call cost.

## If something goes wrong

| Status | code | Cause | What to do |
| --- | --- | --- | --- |
| `401` | `missing_api_key` | The environment variable isn’t set | Run `echo $PAPERPURR_API_KEY` in the same terminal |
| `401` | `invalid_api_key` | The key is malformed or doesn’t exist. | Make sure you copied the whole key with no extra spaces. |
| `503` | `coming_soon` | The API isn’t open yet. Every `/v1` and `/mcp` call returns this for now. | [Join the waitlist](https://paperpurr.com/#api). We’ll announce the launch on Discord. |

## Next steps

- [Reference verification](https://paperpurr.com/en/docs/verify)：Check each reference against Crossref and OpenAlex and flag whether it matches, differs or can’t be found.
- [MCP](https://paperpurr.com/en/docs/mcp)：Use PaperPurr from Claude Code, Cursor, VS Code, Codex and other AI clients: server address, per-client setup, tools and connection check.
- [Workflow examples](https://paperpurr.com/en/docs/workflows)：How to choose between the three ways to get results, plus two complete recipes: batch-verifying references after you finish a paper, and having an agent in Claude Code find and insert citations.

Next: [Authentication](https://paperpurr.com/en/docs/auth.md)
