REST API

Projects & API Keys

Projects scope your event data. Each project has one or more API keys used to authenticate ingest calls. Raw API key values are shown only once — at creation time.

GET/projects

List all projects belonging to the authenticated organization.

Auth:JWT Session (cookie)
Response
HTTP/1.1 200 OK

[
  {
    "id": "proj_01HX...",
    "name": "Production",
    "environment": "production",
    "organizationId": "org_01HX...",
    "createdAt": "2026-01-20T09:00:00.000Z"
  }
]
POST/projects

Create a new project. Automatically generates one API key. The raw key is returned once in the response — store it securely.

Auth:JWT Session (cookie)

The apiKey field is the raw (unhashed) key. It is never stored and cannot be retrieved again.

Request Body

NameTypeRequiredDescription
namestringrequiredDisplay name for the project.
environment"production" | "staging" | "development"optionalTarget environment. Defaults to production.
Request
POST /projects HTTP/1.1
Content-Type: application/json

{
  "name": "Production",
  "environment": "production"
}
Response
HTTP/1.1 201 Created

{
  "id": "proj_01HX...",
  "name": "Production",
  "environment": "production",
  "organizationId": "org_01HX...",
  "createdAt": "2026-01-20T09:00:00.000Z",
  "apiKey": "vig_live_abc123def456..."
}
GET/projects/:id

Retrieve a single project by its ID.

Auth:JWT Session (cookie)

Path Parameters

NameTypeRequiredDescription
idstringrequiredProject ID.
Response
HTTP/1.1 200 OK

{
  "id": "proj_01HX...",
  "name": "Production",
  "environment": "production",
  "organizationId": "org_01HX...",
  "createdAt": "2026-01-20T09:00:00.000Z"
}
PATCH/projects/:id

Update a project's name or environment.

Auth:JWT Session (cookie)

Path Parameters

NameTypeRequiredDescription
idstringrequiredProject ID.

Request Body

NameTypeRequiredDescription
namestringoptionalNew display name.
environment"production" | "staging" | "development"optionalNew environment.
Request
PATCH /projects/proj_01HX... HTTP/1.1
Content-Type: application/json

{
  "name": "Production v2"
}
Response
HTTP/1.1 200 OK

{
  "id": "proj_01HX...",
  "name": "Production v2",
  "environment": "production",
  "organizationId": "org_01HX...",
  "createdAt": "2026-01-20T09:00:00.000Z"
}
DELETE/projects/:id

Permanently delete a project and all its associated events, incidents, and API keys.

Auth:JWT Session (cookie)

Path Parameters

NameTypeRequiredDescription
idstringrequiredProject ID.
Response
HTTP/1.1 204 No Content
GET/projects/:projectId/api-keys

List all API keys for a project. Raw key values are never returned — only metadata.

Auth:JWT Session (cookie)

Path Parameters

NameTypeRequiredDescription
projectIdstringrequiredProject ID.
Response
HTTP/1.1 200 OK

[
  {
    "id": "key_01HX...",
    "name": "Default",
    "prefix": "vig_live_abc1",
    "projectId": "proj_01HX...",
    "createdAt": "2026-01-20T09:00:00.000Z",
    "lastUsedAt": "2026-03-12T18:45:00.000Z"
  }
]
POST/projects/:projectId/api-keys

Create an additional API key for a project. The raw key is returned once.

Auth:JWT Session (cookie)

Path Parameters

NameTypeRequiredDescription
projectIdstringrequiredProject ID.

Request Body

NameTypeRequiredDescription
namestringoptionalFriendly label for this key (e.g. "CI/CD").
Response
HTTP/1.1 201 Created

{
  "id": "key_02HX...",
  "name": "CI/CD",
  "prefix": "vig_live_xyz9",
  "projectId": "proj_01HX...",
  "createdAt": "2026-03-13T10:00:00.000Z",
  "rawKey": "vig_live_xyz9..."
}
DELETE/api-keys/:id

Revoke an API key. Any requests using this key will immediately return 401.

Auth:JWT Session (cookie)

Note: This endpoint is at /api-keys/:id (not under /projects). Use GET /projects/:projectId/api-keys to find the key ID.

Path Parameters

NameTypeRequiredDescription
idstringrequiredAPI key ID.
Response
HTTP/1.1 204 No Content