cURL
curl --request POST \ --url https://api.promptguard.dev/api/v1/api-keys \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data ' { "name": "<string>", "project_id": "<string>", "permissions": [ "read" ] } '
{ "key": "<string>", "id": "<string>", "name": "<string>", "prefix": "<string>" }
Create a new API key
API Key Limits:
API Key authentication for developer endpoints (/api/v1/*). Use format: 'Bearer pg_api_your_key_here'
Successful Response