Skip to main content
missing_credentials means the request reached a protected route without a usable Authorization: Bearer header. Read this page if your first call fails with a 401, or if a proxy or HTTP client drops headers.

What happened

Routes: every protected route under /v1/, including runs, keys, usage, quota and billing. The credential is the first thing OpenType checks, so this error comes before any body or scope check. One of these is true: The scheme name is not case-sensitive: bearer works too. There is no other authentication header and no cookie authentication. The response does not carry a WWW-Authenticate header.

How to fix

  1. Send Authorization: Bearer <credential> on every call. For your code, the credential is an API key: otsk_ followed by 64 lowercase hex characters.
  2. Check that OPENTYPE_API_KEY is set in the process that makes the call. An unset variable produces an empty token.
  3. If you call through a proxy, gateway or serverless platform, check that it forwards the Authorization header.
  4. Keep the key on your server. Do not send it from a browser or a mobile app.
If you have no key yet, create one on the API keys page.

Example

A request with the header set, failing early when the key is missing: