REST API endpoint

GET /api/me

API-key account context: current tracker and all trackers the token can access.

Request

GET https://api.nowmetrix.com/api/me

Use this endpoint to discover which trackers are available to an API key before calling tracker-specific endpoints.

Authentication

Requires an API key in the Authorization header: Authorization: Bearer nm_YOUR_KEY.

Query parameters

This endpoint does not accept query parameters.

cURL example

curl -H "Authorization: Bearer nm_YOUR_KEY" \
  "https://api.nowmetrix.com/api/me"

Example response

{
  "authenticated": true,
  "current_tracker": "TRACKER_ID",
  "trackers": [
    {
      "tracker": "TRACKER_ID",
      "host": "example-media.test"
    },
    {
      "tracker": "SECOND_TRACKER_ID",
      "host": "example-studio.test"
    }
  ]
}

Response fields

Field Type Description
authenticated boolean Whether the Bearer token is valid.
current_tracker string First tracker available to the API key. Use tracker IDs from the trackers array for tracker-specific requests.
trackers[] array<object> Trackers available to the current user.
trackers[].tracker string Tracker ID.
trackers[].host string Normalized hostname for the tracker.

Freshness and caching

Responses are not cached. The endpoint sends Cache-Control: no-store, no-cache, must-revalidate, max-age=0.

Errors

HTTP Code Description
401 missing_token The Authorization header is missing.
401 invalid_token The token is invalid or revoked.
{
  "error": {
    "code": "invalid_token",
    "message": "Bearer token is invalid or revoked."
  }
}