Promptic

API keys

API keys authenticate services, SDK clients, and CLI workflows to one AI Application. They are different from model-provider credentials.

Create a key

  1. Open the target AI Application.
  2. Go to Settings → API Keys.
  3. Create a key with a name that identifies its consumer, such as production-api or github-actions.
  4. Copy the value immediately and store it in a secrets manager.

The key is shown only when created. Promptic stores a protected representation rather than displaying the original value later.

Use a key

Set the SDK environment variable:

Terminal
export PROMPTIC_API_KEY="ptc_..."

Or send it to the REST API:

Terminal
curl https://promptic.eu/api/v1/ai-application \
  -H "Authorization: Bearer $PROMPTIC_API_KEY"

Some endpoints also require an explicit AI Application context through X-AI-Application-Id or aiApplicationId. The endpoint reference identifies when it is required.

Key hygiene

  • Create separate keys for development, CI, and production.
  • Do not put keys in source code, screenshots, traces, support messages, or committed .env files.
  • Restrict secret access to the workload that uses the key.
  • Rotate a key after suspected exposure or when ownership changes.
  • Delete old keys after confirming the replacement is active.
  • Prefer short-lived CI secret access over copying a developer’s key.

API key versus provider key

CredentialWhat it authorizes
Promptic API keyAccess to one Promptic AI Application
OpenAI/OpenRouter/Google/custom-provider credentialModel calls made for optimization or evaluation

Never place a provider key in PROMPTIC_API_KEY, or a Promptic key in a model-provider form.

For authentication details and error responses, see Authentication.