Xeonr Developer Docs

Lookup Users By Connection

POST
/xeonr.auth.api.v1.UsersService/LookupUsersByConnection

Resolves external identity-provider ids (Discord snowflakes, GitHub user ids) to the Xeonr accounts that have linked them, within the organisation the request is addressed to. Up to 10 ids per call; ids that resolve to no account are absent from the response.

No authentication required. Rate limited per client IP.

AuthorizationBearer <token>

JWT access token obtained via OAuth2 flow or service account

In: header

Header Parameters

Connect-Protocol-Version?number

Define the version of the Connect protocol

Connect-Timeout-Ms?number

Define the timeout, in ms

Request Body

application/json

idpSlug?string

Slug of the identity provider the external ids belong to, for example "discord" or "github".

Length1 <= length <= 64
externalIds?external_ids

The ids that provider knows the users by — Discord snowflakes, GitHub numeric user ids. Capped at 10 per call.

Items1 <= items <= 10
[key: string]?never

Response Body

application/json

application/json

curl -X POST "https://auth.xeonr.io/xeonr.auth.api.v1.UsersService/LookupUsersByConnection" \  -H "Connect-Protocol-Version: 1" \  -H "Connect-Timeout-Ms: 1000" \  -H "Content-Type: application/json" \  -d '{}'
{
  "users": {
    "property1": {
      "userId": "urn:xeonr:auth:uid:user:123",
      "username": "johndoe",
      "avatarUrl": "https://cdn.example.com/avatars/abc123",
      "createdAt": "2023-01-15T01:30:15.01Z",
      "isAdmin": true
    },
    "property2": {
      "userId": "urn:xeonr:auth:uid:user:123",
      "username": "johndoe",
      "avatarUrl": "https://cdn.example.com/avatars/abc123",
      "createdAt": "2023-01-15T01:30:15.01Z",
      "isAdmin": true
    }
  }
}
{
  "code": "not_found",
  "message": "string",
  "details": [
    {
      "type": "string",
      "value": "string",
      "debug": {}
    }
  ]
}