GamebeastDocs
Dashboard
Server APICohorts

Execute a headless cohort

POST
/application/{applicationId}/analytics/v1/cohorts/execute

Authorization

personalAccessTokenAuth
AuthorizationBearer <token>

Personal access token (prefixed gb_pat_). Acts on behalf of its owner and can never exceed the owner's own permissions. Send it as Authorization: Bearer <token>.

In: header

Path Parameters

applicationId*number

Gamebeast project ID

Header Parameters

environment_id*number

Gamebeast environment ID

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

[index: integer]?array<>

Response Body

curl -X POST "https://example.com/application/0/analytics/v1/cohorts/execute" \  -H "environment_id: 0" \  -H "Content-Type: application/json" \  -d '[    [      {        "operator": "and",        "conditions": [          {            "positive": true,            "metric": {              "type": "cohort",              "name": "string",              "definition": null            }          }        ]      }    ]  ]'
Empty