consumer_token_required
Publishable key sent no consumer token · HTTP 401
What causes this
A publishable key (cc_pub_…) acted for an end-customer without proving which one. Publishable keys ship in browser code and are public by design, so the end-customer identity cannot be taken from a request header — anyone reading your page source could then act as any of your customers.
How to fix it
Mint a consumer token server-side with POST /v1/portal/sessions and send it as X-Ngentix-Consumer-Token. Server-side calls are unaffected: keep using a secret key with X-Ngentix-Consumer.
What the response looks like
{
"error": {
"code": "consumer_token_required",
"status": 401,
"message": "…",
"hint": "…",
"request_id": "req_…",
"docs_url": "https://cloud.ngentix.ai/docs/errors/consumer_token_required"
}
}
Quote the request_id if you contact support — it identifies your exact request in our logs.