GET
/
v1
/
environments
curl https://api.zquenceeee.com/v1/environments \
  -H "x-api-key: $ZQUENCE_PUBLIC_KEY" \
  -H "x-api-secret: $ZQUENCE_SECRET_KEY"
[
  {
    "id": "69f9b5fa0600ccbf9c677001",
    "tenantId": "bc41c6ab-7206-4033-b632-4d1cfa86d840",
    "name": "Live",
    "type": "live",
    "status": "active",
    "apiVersion": "v1",
    "webhookRetries": 3,
    "debugLogging": false,
    "rateLimitPerMinute": null,
    "createdAt": "2026-01-10T08:00:00.000Z",
    "updatedAt": "2026-05-15T14:22:10.000Z"
  },
  {
    "id": "69f9b5fa0600ccbf9c677005",
    "tenantId": "bc41c6ab-7206-4033-b632-4d1cfa86d840",
    "name": "Staging Sandbox",
    "type": "sandbox",
    "status": "active",
    "apiVersion": "v1",
    "webhookRetries": 3,
    "debugLogging": true,
    "rateLimitPerMinute": 120,
    "createdAt": "2026-02-04T11:30:00.000Z",
    "updatedAt": "2026-06-01T09:45:00.000Z"
  }
]
Every tenant has exactly one permanent live environment and zero or more sandbox environments. Results are sorted by type then name alphabetically (live first). Access scoping rules:
  • API key callers receive only the environments their key is scoped to.
  • Admin users receive all active environments by default. With includeAll=true they also receive disabled environments.
  • Non-admin users receive only the environments they are a member of.

Query parameters

includeAll
boolean
default:"false"
When true, each environment object includes a hasAccess boolean indicating whether the caller is a member.
Admin callers will also receive disabled environments in the response.
Non-admin callers always return only their accessible environments regardless of this flag.

Returns

An array of environment objects. When includeAll=true, each object also includes hasAccess.
id
string
Environment ID (MongoDB ObjectId).
tenantId
string
Owning tenant identifier.
name
string
Human-readable display name (e.g. "Live", "Staging Sandbox").
type
string
Environment type — "live" or "sandbox". Each tenant has exactly one "live" environment.
status
string
"active" or "disabled". Disabled environments reject all incoming API requests.
apiVersion
string
API version configured for this environment. Currently always "v1".
webhookRetries
number
Number of webhook delivery retry attempts for this environment. Default 3. Maximum effective value is 10.
debugLogging
boolean
When true, extended request and event logs are captured for this environment. Default false.
rateLimitPerMinute
number | null
Per-minute API rate-limit override for this environment. null or absent means the tenant-level default applies.
hasAccess
boolean
Only present when includeAll=true is passed. true if the calling user is a member of this environment, false otherwise.
createdAt
string
ISO 8601 UTC creation timestamp.
updatedAt
string
ISO 8601 UTC last-modified timestamp.

Error codes

StatusMeaning
400tenantId could not be resolved from the authenticated credential.
401Missing or invalid API key pair.
curl https://api.zquenceeee.com/v1/environments \
  -H "x-api-key: $ZQUENCE_PUBLIC_KEY" \
  -H "x-api-secret: $ZQUENCE_SECRET_KEY"
[
  {
    "id": "69f9b5fa0600ccbf9c677001",
    "tenantId": "bc41c6ab-7206-4033-b632-4d1cfa86d840",
    "name": "Live",
    "type": "live",
    "status": "active",
    "apiVersion": "v1",
    "webhookRetries": 3,
    "debugLogging": false,
    "rateLimitPerMinute": null,
    "createdAt": "2026-01-10T08:00:00.000Z",
    "updatedAt": "2026-05-15T14:22:10.000Z"
  },
  {
    "id": "69f9b5fa0600ccbf9c677005",
    "tenantId": "bc41c6ab-7206-4033-b632-4d1cfa86d840",
    "name": "Staging Sandbox",
    "type": "sandbox",
    "status": "active",
    "apiVersion": "v1",
    "webhookRetries": 3,
    "debugLogging": true,
    "rateLimitPerMinute": 120,
    "createdAt": "2026-02-04T11:30:00.000Z",
    "updatedAt": "2026-06-01T09:45:00.000Z"
  }
]