legacy_key_retired is returned with HTTP 401 Unauthorized when the key is a retired legacy key. Create a new key in the Developer Portal and replace it in your integration.
Definition
This error means the key once worked as a legacy credential and has been retired. It is not a routing failure, and it is not the same as a typo in a current key.
How it works
Read the JSON
errorfield. For this case it islegacy_key_retired.Open the
portalUrlfrom the response, or go to the Developer Portal, and create a new key.Replace the retired key in your environment and verify the new key with
GET /api/v1/account/accountId.Do not keep retrying the retired key.
How Enso does this
Authentication documents this 401 separately from invalid_api_key. Both responses can include portalUrl. A blocked account is a 403 with account_blocked, not a 401.
This is an authentication failure only. The request never reached routing, and it is not a sign that a previously submitted transaction failed on-chain.
FAQ
Can I reactivate the retired key?
The documented fix is to create a new key in the Developer Portal. Do not keep sending the retired key.
Is this a rate-limit error?
No. Rate-limit and credit-quota issues return 429.
Related articles
What does invalid_api_key mean?
Why did the Enso API return 401?
Why is there a portalUrl in an Enso error?
How do I get an Enso API key?
How do I authenticate Enso API requests?
