مواد پر جائیں
AtheronDEVELOPERS
← API reference

Developer API: your app

The application and environment your API key belongs to: its client ID, redirect addresses, scopes, approved scopes and counts.

مثالوں میں اپنی ٹیسٹ کلائنٹ آئی ڈی دیکھنے کے لیے سائن اِن کریں۔

GET https://developers.aton-network.org/api/v1/app

When to use it

In deploy checks: confirm the redirect addresses and scopes your code expects are the ones registered.

Authentication

Authorization: Bearer <API key> with the app:read right.

Parameters

NameInTypeRequiredLimitsWhat it is
AuthorizationheaderstringyesBearer ath_test_... or ath_live_...An API key from the app's API keys page.

Request

# Your app as registered, for the environment this API key belongs to. Needs app:read.
curl https://developers.aton-network.org/api/v1/app \
  -H "Authorization: Bearer $ATHERON_API_KEY"

In GraphQL

Query.app at POST https://developers.aton-network.org/api/graphql, with the app:read right, costing 1. Your application as registered, for the environment the key belongs to. The same fields as the REST call, in camelCase; ask only for the ones you need.

The answer:

Errors it can meet: invalid_key, missing_right, not_found, rate_limited, server_error. Try it in the GraphQL playground.

graphql
query App {
  app {
    name
    state
    env
    clientId
    redirectUris
    scopes
  }
}
json
{
  "data": {
    "app": {
      "name": "Acme Notes",
      "state": "development",
      "env": "TEST",
      "clientId": "test-3f9c2a",
      "redirectUris": [
        "https://app.example.com/callback"
      ],
      "scopes": [
        "openid",
        "profile",
        "email"
      ]
    }
  },
  "extensions": {
    "cost": 1
  }
}

Response

http
HTTP 200
content-type: application/json

{
  "name": "Price Check",
  "state": "live",
  "kind": "confidential",
  "quota": "free",
  "env": "live",
  "client_id": "live-1a2b3c4d5e6f7a8b",
  "redirect_uris": ["https://app.example.com/callback"],
  "scopes": ["openid", "profile", "email"],
  "approved_scopes": ["openid", "profile", "email"],
  "privacy_url": "https://app.example.com/privacy",
  "homepage_url": "https://app.example.com",
  "credentials": 2,
  "testers": 0,
  "webhooks": 1
}

Errors

HTTPerrorCauseFix
401invalid_keyNo API key was sent, or it is not one of ours, expired or revoked.Send Authorization: Bearer with a key from the app's API keys page.
403missing_rightThe key does not carry the right this call needs.Make a key with the right (app:read or usage:read).
429rate_limitedOver your quota for this bucket, this minute or this day.Wait the Retry-After seconds. Requests over the limit still count, so a retry loop keeps you over it.
404not_foundThe application this key belonged to has been removed.Use a key of an app that still exists.
500server_errorSomething went wrong at our end.Try again in a moment. If it keeps happening, check the status page and tell us in the chat.

Good to know

  • Counts the api bucket of your quota.

Security

  • Never put an API key in a URL or in code that ships to a browser.

⁨Atlas⁩ سے پوچھیں

AI اسسٹنٹ

Atheron کے ساتھ سائن ان، API یا پورٹل کے بارے میں کچھ بھی پوچھیں۔ جواب ہماری دستاویزات سے آتا ہے، استعمال شدہ صفحات کے لنک کے ساتھ۔