Organizations, Usage & License
These endpoints provide access to organizational resources, usage metrics, and license information.
List Organizations
Section titled “List Organizations”GET /v1/organizationsReturns the organizations accessible to the authenticated identity.
- API key: Returns the single organization the key belongs to.
- JWT: Returns all organizations the user is a member of.
Scope required (API key): org:read
Response
Section titled “Response”{ "data": [ { "id": "org-uuid", "name": "Ananke Research", "slug": "ananke-research", "avatarUrl": "https://...", "role": "owner", "createdAt": "2025-01-10T08:00:00.000Z" } ]}Response Fields
Section titled “Response Fields”| Field | Type | Description |
|---|---|---|
id | uuid | Organization ID |
name | string | Display name |
slug | string | URL-friendly identifier |
avatarUrl | string | null | Avatar image URL |
role | string | Caller’s role: "owner", "member", or "api_key" |
createdAt | string | ISO 8601 timestamp |
Get Organization
Section titled “Get Organization”GET /v1/organizations/{id}Returns details for a single organization, including member count.
Scope required (API key): org:read
Path Parameters
Section titled “Path Parameters”| Parameter | Type | Description |
|---|---|---|
id | uuid | Organization ID |
Response
Section titled “Response”{ "id": "org-uuid", "name": "Ananke Research", "slug": "ananke-research", "avatarUrl": "https://...", "memberCount": 5, "createdAt": "2025-01-10T08:00:00.000Z"}Errors
Section titled “Errors”| Status | Code | When |
|---|---|---|
403 | FORBIDDEN | Caller is not a member of this organization |
404 | NOT_FOUND | Organization does not exist |
Usage Summary
Section titled “Usage Summary”GET /v1/organizations/{orgId}/usage/summaryReturns usage metrics for the current billing period.
Scope required (API key): usage:read
Path Parameters
Section titled “Path Parameters”| Parameter | Type | Description |
|---|---|---|
orgId | uuid | Organization ID |
Response
Section titled “Response”{ "simulationRuns": 142, "apiCalls": 1830, "tickCount": 284000, "limits": { "maxSimulationRuns": 1000, "maxTicksPerRun": 10000 }, "periodStart": "2025-06-01T00:00:00.000Z", "periodEnd": "2025-07-01T00:00:00.000Z"}Response Fields
Section titled “Response Fields”| Field | Type | Description |
|---|---|---|
simulationRuns | number | Simulations created this period |
apiCalls | number | Total API calls this period |
tickCount | number | Total ticks computed this period |
limits | object | Current plan limits |
periodStart | string | Billing period start (ISO 8601) |
periodEnd | string | Billing period end (ISO 8601) |
Usage History
Section titled “Usage History”GET /v1/organizations/{orgId}/usage/historyReturns usage metrics across recent billing periods.
Scope required (API key): usage:read
Path Parameters
Section titled “Path Parameters”| Parameter | Type | Description |
|---|---|---|
orgId | uuid | Organization ID |
Query Parameters
Section titled “Query Parameters”| Parameter | Type | Default | Description |
|---|---|---|---|
periods | integer | 6 | Number of billing periods to return (1–12) |
Response
Section titled “Response”{ "data": [ { "periodStart": "2025-06-01T00:00:00.000Z", "periodEnd": "2025-07-01T00:00:00.000Z", "simulationRuns": 142, "apiCalls": 1830, "tickCount": 284000 }, { "periodStart": "2025-05-01T00:00:00.000Z", "periodEnd": "2025-06-01T00:00:00.000Z", "simulationRuns": 98, "apiCalls": 1204, "tickCount": 196000 } ]}License Information
Section titled “License Information”GET /v1/organizations/{orgId}/licenseReturns the current license and subscription details for an organization.
Scope required (API key): org:read
Path Parameters
Section titled “Path Parameters”| Parameter | Type | Description |
|---|---|---|
orgId | uuid | Organization ID |
Response
Section titled “Response”{ "id": "lic-uuid", "tier": "professional", "status": "active", "limits": { "maxSimulationRuns": 1000, "maxTicksPerRun": 10000, "maxConcurrentSSE": 5 }, "currentPeriodStart": "2025-06-01T00:00:00.000Z", "currentPeriodEnd": "2025-07-01T00:00:00.000Z", "hasStripeSubscription": true}Response Fields
Section titled “Response Fields”| Field | Type | Description |
|---|---|---|
id | uuid | License ID |
tier | string | "community", "professional", "enterprise", or "strategic" |
status | string | License status |
limits | object | Tier-specific limits |
currentPeriodStart | string | null | Current billing period start |
currentPeriodEnd | string | null | Current billing period end |
hasStripeSubscription | boolean | Whether a Stripe subscription is attached |
Errors
Section titled “Errors”| Status | Code | When |
|---|---|---|
403 | FORBIDDEN | Caller does not have access to this organization |
404 | NOT_FOUND | No license found for this organization |