Your identity

/self/me returns the identity record of whoever is making the call. It is the simplest authenticated endpoint on the API, so it is the best first call to make once you can build a token: if it returns your record, your authentication is working end to end.

Before you start

You need a valid access token. Build one with either sign-in path first:

The call

Send a GET to /self/me with your access token in the Authorization header. Pin api-version to protect your integration from future changes:

curl
curl -sS "https://api.cybersentriq.com/self/me?api-version=1.0" \
  -H "Authorization: Bearer <ACCESS_TOKEN>"
TypeScript / Node
const res = await fetch(
  "https://api.cybersentriq.com/self/me?api-version=1.0",
  { headers: { Authorization: `Bearer ${accessToken}` } },
);
const me = await res.json();
Python
import requests

res = requests.get(
    "https://api.cybersentriq.com/self/me",
    params={"api-version": "1.0"},
    headers={"Authorization": f"Bearer {access_token}"},
)
me = res.json()
C#
using System.Net.Http;

var http = new HttpClient();
var req = new HttpRequestMessage(HttpMethod.Get,
    "https://api.cybersentriq.com/self/me?api-version=1.0");
req.Headers.Add("Authorization", $"Bearer {accessToken}");

var res = await http.SendAsync(req);
var me = await res.Content.ReadAsStringAsync();
Go
req, _ := http.NewRequest("GET",
    "https://api.cybersentriq.com/self/me?api-version=1.0", nil)
req.Header.Set("Authorization", "Bearer "+accessToken)

res, err := http.DefaultClient.Do(req)
if err != nil {
    log.Fatal(err)
}
defer res.Body.Close()
// Decode res.Body into your model.

What you get back

A 200 with a JSON body describing the caller. It carries your sub, the scope your token was granted, your effective permissions, and a claims map of the namespaced identity claims you hold:

JSON
{
  "sub": "idp|abc123",
  "scope": "openid profile email",
  "permissions": ["self:profile:read"],
  "claims": {
    "https://titanhq.com/uid": "…",
    "https://titanhq.com/oid": "…"
  }
}

The claims map holds only the claims you actually carry, so a given caller may see one product's claims and not another's. Read permissions to decide what the caller may do, and treat the titanhq.com/* and redstor.com/* claims as transitional and subject to change. Additional fields may be present, and more are added as the identity surface grows.

Versioning

api-version is a query parameter in major.minor form. Omit it and you get the pinned default, 1.0. Send an unsupported version and the call returns 400 with an api-supported-versions response header listing the versions you can use. Every response carries that header, so you can always see what is available.

Pin api-version in production clients so a new default cannot change your integration's behavior underneath it.

When it fails

  • 400: the api-version you sent is not supported. Check the api-supported-versions response header.
  • 401: the access token is missing, invalid or expired. Build a fresh token (see the sign-in guides above) and try again. For how to keep a token alive, see Refreshing tokens.

Next