The key works in Postman. From Node every call is a 401:
js
headers: { Authorization: `Bearer ${process.env.SUPERO_KEY}` }Authorization: BearerCommon question, written up by the Supero team.
401 UnauthorizedThe key works in Postman. From Node every call is a 401:
headers: { Authorization: `Bearer ${process.env.SUPERO_KEY}` }Send API keys in X-API-Key. Authorization: Bearer is for the JWT you get back from login; a key sent as Bearer gets 401. Send only one credential header. A default Authorization header added by a proxy or your HTTP client config is a common reason a correct key still fails.
headers: { 'X-API-Key': process.env.SUPERO_KEY }Know the answer? Sign in to post it. It takes an email address and a 6-digit code.
Sign in to answer