Error reference
invalid_api_key
The key is not valid
- HTTP status
- 401
- Error type
- authentication
What it means#
The key is unknown, malformed, or has been revoked.
What to do#
We authenticate fail-closed — an unrecognised key is refused rather than downgraded to a free tier, so this never silently becomes a quota problem later.
Check, in this order:
- Whitespace. A trailing newline from
$(cat keyfile)is the single most common cause. - Environment. A
gv_test_…key does not work against live data, and vice versa. - Revocation. If you rotated recently, the old key stops working the moment the new one is issued. See Authentication.
The error shape#
{
"error": {
"type": "authentication",
"code": "invalid_api_key",
"message": "\u2026",
"doc_url": "https://docs.grahvani.in/errors/invalid_api_key",
"request_id": "req_01JQ8ZK3M4N5P6Q7R8S9T"
}
}Full list: all error codes · error handling guide.
Grahvani API — a product of AstroCorp Techlab Pvt Ltd · GSTIN 36AAMCC3512G1ZU
Base URL
https://api.grahvani.in