Skip to main content
Projects live within organizations. The project service exposes endpoints for CRUD operations, analytics via the Langfuse-compatible metrics API, API key management, member management, and more. Base URL is set via REACT_APP_ORGANIZATIONS_API_BASE_URL. All requests require Api-Key and Authorization: Bearer <token> headers.

List Projects

GET /organizations/{organizationId}/projects
List projects within an organization with optional filtering and sorting.
organizationId
string
required
The organization’s unique ID.
user_role
string
Filter by the authenticated user’s role(s). Accepts comma-separated values: OWNER, ADMIN, MEMBER, VIEWER.
has_wallet
boolean
Filter to projects that have a wallet.
has_tools
boolean
Filter to projects that have tools.
has_notebooks
boolean
Filter to projects that have notebooks.
min_members
integer
Minimum member count.
max_members
integer
Maximum member count.
Filter by name substring (case-insensitive).
sort
string
Sort field. One of: name, created_at, updated_at, alphabetical, members_count, tools_count, notebooks_count, recent_activity.
created_after
string
ISO 8601 timestamp. Return only projects created after this date.
created_before
string
ISO 8601 timestamp. Return only projects created before this date.
curl "https://api.makakoo.com/ma-metrics-wsp-ms/v1/api/organizations/123/projects?sort=name&user_role=OWNER,ADMIN" \
  -H "Authorization: Bearer <token>" \
  -H "Api-Key: <your_api_key>"
Response: { "data": [ ...project objects ] } List results are cached for 5 minutes. Pass forceRefresh=true to bypass the cache.

Create Project

POST /organizations/{organizationId}/projects
Create a new project within an organization.
organizationId
string
required
The organization’s unique ID.
data.attributes.name
string
required
The name for the new project.
curl -X POST https://api.makakoo.com/ma-metrics-wsp-ms/v1/api/organizations/123/projects \
  -H "Authorization: Bearer <token>" \
  -H "Api-Key: <your_api_key>" \
  -H "Content-Type: application/json" \
  -d '{
    "data": {
      "attributes": { "name": "My New Project" }
    }
  }'

Get Project

GET /organizations/{organizationId}/projects/{projectId}
Fetch details for a specific project, including related users, API keys, LLM API keys, and Sentinel Passes.
organizationId
string
required
The organization’s unique ID.
projectId
string
required
The project’s unique ID.
secret
boolean
When true, includes encrypted secret keys in the response under meta.secrets.
include
string
Comma-separated related resources. Supported: users, apiKeys, llmApiKeys, sentinelPasses.
curl "https://api.makakoo.com/ma-metrics-wsp-ms/v1/api/organizations/123/projects/456?secret=true&include=users,apiKeys" \
  -H "Authorization: Bearer <token>" \
  -H "Api-Key: <your_api_key>"
data.id
string
The project ID.
data.attributes.name
string
The project name.
data.attributes.isDefault
boolean
Whether this is the organization’s default project.
meta.secrets.publicKey
string
The project’s public API key (only present when secret=true).
meta.secrets.secretKey
string
The project’s secret API key (only present when secret=true).
included
array
Related resources when include is specified. API key objects contain type: "apiKey", attributes.publicKey, and attributes.encryptedSecretKey.

Update Project Name

PATCH /organizations/{organizationId}/projects/{projectId}
organizationId
string
required
The organization’s unique ID.
projectId
string
required
The project’s unique ID.
data.id
string
required
Must match projectId.
data.type
string
required
Must be "project".
data.attributes.name
string
required
The new name for the project.

Delete Project

DELETE /organizations/{organizationId}/projects/{projectId}
Permanently delete a project. This also removes the project’s API keys from local storage.
organizationId
string
required
The organization’s unique ID.
projectId
string
required
The project’s unique ID.

API Key Management

Create API Key

POST /organizations/{organizationId}/projects/{projectId}/api_keys
organizationId
string
required
The organization’s unique ID.
projectId
string
required
The project’s unique ID.
data.attributes.note
string
required
A human-readable label for the API key.
data.attributes.expires_at
string
Optional ISO 8601 expiration datetime.

Update API Key

PATCH /organizations/{organizationId}/projects/{projectId}/api_keys/{apiKeyId}
data.attributes.note
string
required
The new label for the API key.

Delete API Key

DELETE /organizations/{organizationId}/projects/{projectId}/api_keys/{apiKeyId}

LLM API Key Management

Create LLM API Key

POST /organizations/{organizationId}/projects/{projectId}/llm_api_keys
data.type
string
required
Must be "llm_api_keys".
data.attributes.provider
string
required
The LLM provider (e.g., "openai", "anthropic").
data.attributes.secretKey
string
required
The API key from the LLM provider.
data.attributes.customModels
array
Optional list of custom model identifiers to associate with this key.
data.attributes.withDefaultModels
boolean
Whether to include the provider’s default models. Defaults to true.

Delete LLM API Key

DELETE /organizations/{organizationId}/projects/{projectId}/llm_api_keys/{apiKeyId}

Member Management

List Project Users

GET /organizations/{organizationId}/projects/{projectId}/users

Add User to Project

POST /organizations/{organizationId}/projects/{projectId}/add_user
Add an existing user to a project. Automatically falls back to sending a project invitation if the user is not found.
data.type
string
required
Must be "users".
data.attributes.email
string
required
The email address of the user to add.
data.attributes.role
string
required
The project role. One of: OWNER, ADMIN, MEMBER, VIEWER.
data.attributes.organization_role
string
The organization role to assign. Must be equal to or higher than the project role. Required when project_only is false.
data.attributes.project_only
boolean
When true, adds the user to the project without affecting their organization membership.

Update Member Role

PATCH /organizations/{organizationId}/projects/{projectId}/members/{userId}/role
role
string
required
The new role. One of: OWNER, ADMIN, MEMBER, VIEWER.

Remove Member from Project

DELETE /organizations/{organizationId}/projects/{projectId}/remove_user/{userId}

Deny Project Access

POST /organizations/{organizationId}/projects/{projectId}/deny_access/{userId}
Revoke a user’s access to a project without removing them from the organization.

Restore Project Access

POST /organizations/{organizationId}/projects/{projectId}/restore_access/{userId}
role
string
Optional. The role to restore. Uses the user’s previous role if omitted.

Project Invitations

Send Project Invitation

POST /organizations/{organizationId}/projects/{projectId}/invitations
data.type
string
required
Must be "membershipInvitation".
data.attributes.email
string
required
The email address to invite.
data.attributes.projectRole
string
The project role on acceptance. Defaults to "member".
data.attributes.orgRole
string
The organization role on acceptance.
data.attributes.projectOnly
boolean
When true, the invitation grants project access only.

List Project Invitations

GET /organizations/{organizationId}/projects/{projectId}/invitations

Resend Project Invitation

POST /organizations/{organizationId}/projects/{projectId}/invitations/{invitationId}/resend

Cancel Project Invitation

DELETE /organizations/{organizationId}/projects/{projectId}/invitations/{invitationId}

Analytics

Project analytics use project-specific public/secret key pairs (retrieved from the project details endpoint with secret=true) and are served by the analytics microservice at REACT_APP_LANGFUSE_API_URL.

Get Daily Metrics

GET /api/public/metrics/daily
Authenticate with HTTP Basic Auth using the project’s publicKey as the username and secretKey as the password.
fromTimestamp
string
required
ISO 8601 start timestamp.
toTimestamp
string
required
ISO 8601 end timestamp.
tags
string
Optional comma-separated tags to filter metrics.
data
array
Array of daily metric data points.

List Traces

GET /api/public/traces
Authenticate with HTTP Basic Auth.
page
integer
Page number (1-indexed).
limit
integer
Items per page.
name
string
Filter by trace name.
userId
string
Filter by user ID.
sessionId
string
Filter by session ID.
fromTimestamp
string
ISO 8601 start timestamp.
toTimestamp
string
ISO 8601 end timestamp.
orderBy
string
Sort field.
tags
string
Filter by tags.
data
array
Array of trace objects.
meta
object
Pagination metadata.

Get Trace by ID

GET /api/public/traces/{traceId}
Authenticate with HTTP Basic Auth. Returns the full trace detail object.

Build docs developers (and LLMs) love