| title | API keys |
|---|---|
| description | Create, name, copy, and delete API keys from your ModelRunner profile |
| icon | key |
Use API keys to authenticate requests to ModelRunner. Follow these steps to create a key, give it a clear name, copy it securely, and delete it when no longer needed.
Go to your account menu and select Profile, then open API Keys. Click Create API key.<Tip>
Prefer one key per environment or integration (for example: "staging-web", "prod-data-pipeline").
</Tip>
Authorization header.
<CodeGroup>
```bash cURL
curl -X GET "https://queue.modelrunner.run/{owner}/{model}/requests/{request_id}/status" \
-H "Authorization: Key YOUR_API_KEY"
```
```javascript Node.js
const res = await fetch(
`https://queue.modelrunner.run/${owner}/${model}/requests/${requestId}/status`,
{ headers: { Authorization: `Key ${process.env.MODELRUNNER_API_KEY}` } }
);
const data = await res.json();
```
</CodeGroup>
<Warning>
You can only view the full API key once at creation time. If lost, delete it and create a new one. Never share keys publicly or embed them in client-side code.
</Warning>
If an API key is no longer needed or has been exposed, you should delete it immediately to prevent unauthorized access.
To delete an API key:
- Go to the API Keys section in your profile.
- Find the key you want to remove.
- Click Delete and confirm your choice.
After deletion, any requests using that key will fail with a 401 Unauthorized error.
Regularly review and remove unused or compromised API keys to keep your account secure.