Skip to main content
GET
/
api
/
v1-beta
/
customers
/
{id}
/
entities
/
{entityId}
JavaScript
import Stigg from '@stigg/typescript';

const client = new Stigg({
  apiKey: process.env['STIGG_API_KEY'], // This is the default and can be omitted
});

const entity = await client.v1Beta.customers.entities.retrieve('x', { id: 'id' });

console.log(entity.data);
{
  "data": {
    "id": "user-7f3a0c1d",
    "typeId": "user",
    "metadata": {
      "email": "jane@acme.com",
      "role": "admin"
    },
    "createdAt": "2026-05-18T00:00:00.000Z",
    "updatedAt": "2026-05-18T00:00:00.000Z",
    "archivedAt": null
  }
}

Authorizations

X-API-KEY
string
header
required

Server API Key

Headers

X-ACCOUNT-ID
string

Account ID — optional when authenticating with a user JWT (Bearer token); falls back to the user's first membership. Ignored for API-key auth.

X-ENVIRONMENT-ID
string

Environment ID — required when authenticating with a user JWT (Bearer token) on environment-scoped endpoints. Ignored for API-key auth (env is intrinsic to the key).

Path Parameters

id
string
required

The customer identifier (owner) the entity belongs to

Required string length: 1 - 255
Pattern: ^[a-zA-Z0-9][a-zA-Z0-9_|.@-]*$
entityId
string
required

The entity identifier (refId)

Required string length: 1 - 255

Response

The requested entity object.

Response object

data
Entity · object
required

A stored entity instance tracked by the governance service for a given customer