API Key Introspection
GET
/auth/keys/me
curl -X GET https://api.astroway.info/v1/auth/keys/me \ -H "X-Api-Key: aw_live_..." \ -H "Content-Type: application/json"const res = await fetch('https://api.astroway.info/v1/auth/keys/me', { method: 'GET', headers: { 'X-Api-Key': process.env.ASTROWAY_API_KEY, 'Content-Type': 'application/json', },});const { ok, data, error } = await res.json();if (!ok) throw new Error(error.message);console.log(data);import os, requests
r = requests.get( 'https://api.astroway.info/v1/auth/keys/me', headers={'X-Api-Key': os.environ['ASTROWAY_API_KEY'], 'Content-Type': 'application/json'},)result = r.json()if not result['ok']: raise RuntimeError(result['error']['message'])print(result['data'])<?phpuse GuzzleHttp\Client;
$client = new Client(['base_uri' => 'https://api.astroway.info/v1/']);$r = $client->get('auth/keys/me', [ 'headers' => ['X-Api-Key' => getenv('ASTROWAY_API_KEY')],]);$result = json_decode($r->getBody(), true);if (!$result['ok']) throw new \RuntimeException($result['error']['message']);print_r($result['data']);Return metadata about the calling API key: plan, remaining credits, period end, bound domain, status. Useful for any SDK consumer that wants to surface plan and balance in its own UI.
Authorizations
Section titled “Authorizations ”Responses
Section titled “ Responses ”Successful calculation
Media type application/json
object
ok
boolean
data
object
key_prefix
string
plan
string
credits_remaining
number
credits_total_this_period
number
period_end
string
status
string
domain
string
domain_bound_at
string
created_at
string
referrer_source
string
Example
{ "ok": true, "data": { "key_prefix": "aw_live_a3f...", "plan": "indie", "credits_remaining": 18432, "credits_total_this_period": 50000, "period_end": "2026-06-01T00:00:00.000Z", "status": "active", "domain": "example.com", "domain_bound_at": "2026-05-14T18:22:00.000Z", "created_at": "2026-05-12T08:00:00.000Z", "referrer_source": "wp_plugin" }}Validation error
Media type application/json
Example
{ "ok": false, "error": { "code": "INVALID_INPUT", "message": "Validation failed: date: Date must be YYYY-MM-DD", "details": [ { "path": "date", "message": "Date must be YYYY-MM-DD" } ] }}Missing or invalid API key
Media type application/json
Example
{ "ok": false, "error": { "code": "INVALID_API_KEY", "message": "Invalid API key" }} Корисно?
Дякуємо за фідбек.