---
title: "Get project log activity"
method: POST
path: "/projects/{id}/logs/activity"
tags: ["Logs"]
---

# Get project log activity

`POST /projects/{id}/logs/activity`

## Request

- Base URL: `https://api.volcano.dev`
- URL: `https://api.volcano.dev/projects/{id}/logs/activity`
- Auth: one of:
  - HTTP bearer
  - HTTP bearer

Retrieve bucketed log counts for one resource type in the project. Set
`resource.type` to `function`, `frontend`, or `database`. Add
`resource.ids` to filter to one or more resources, and add
`resource.deployments.ids` to count deployment logs instead of runtime
logs for functions and frontends. Deployment logs are not supported for
databases. Database logs are a SUPERAGENT feature; `resource.type=database`
from a HOBBY project owner returns 403. The activity window is limited
to the plan's retention window (HOBBY: 1 day, SUPERAGENT: 30 days); older start
times are clamped to that window. Buckets are aligned to UTC clock
intervals and count events in the half-open window
`[start_time, end_time)`.

## Path parameters

- `id` string, uuid, required

## Request body

- LogActivityRequest: Activity request for bucketed log counts.
  - `resource` union, required: Resource selectors for project log reads.
    - LogFunctionRequestResource: Edge Function log resource selector.
      - `type` 'function', required: Resource type to read logs for.
      - `ids` string[]: Optional function identifiers. Omit or send an empty array to include every function in the project.
      - `kind` 'standard' | 'durable': Read only functions of this kind. Omit to include standard and durable functions. With `ids`, the listed functions of other kinds are left out, so an ID of the other kind returns no logs. Search, stream, and activity cursors are bound to the kind.
      - `deployments` LogDeploymentRequestSelector: Deployment log selector for deployable resources.
        - `ids` string[]: Optional deployment identifiers. Omit or send an empty array to include every deployment for the selected resources.
    - LogFrontendRequestResource: Frontend log resource selector.
      - `type` 'frontend', required: Resource type to read logs for.
      - `ids` string[]: Optional frontend identifiers. Omit or send an empty array to include every frontend in the project.
      - `deployments` LogDeploymentRequestSelector: Deployment log selector for deployable resources.
        - `ids` string[]: Optional deployment identifiers. Omit or send an empty array to include every deployment for the selected resources.
    - LogDatabaseRequestResource: Database runtime log resource selector. Deployment logs are not supported for databases.
      - `type` 'database', required: Resource type to read logs for.
      - `ids` string[]: Optional database identifiers. Omit or send an empty array to include every database in the project.
  - `q` string: Optional activity query. Supports quoted text, implicit AND, AND/OR/NOT, parentheses, and fields such as `level`, `region`, `invocation.id`, `resource.id`, `resource.name`, `function`, `frontend`, `database`, and `body`.
  - `start_time` string, date-time: Start of the window, inclusive. Defaults to 24 hours before `end_time`.
  - `end_time` string, date-time: End of the window, exclusive. Defaults to now.
  - `bucket_count` integer: Maximum number of buckets. Defaults to 24. Volcano picks the smallest bucket width from 1s, 2s, 5s, 10s, 15s, 30s, 1m, 2m, 5m, 10m, 15m, 30m, 1h, 2h, 3h, 6h, 12h, 1d, or a whole number of days that covers the window in at most this many buckets. Bucket edges fall on UTC multiples of the width, so they stay fixed as the window moves, and the response can contain fewer buckets. `1` returns one bucket that spans exactly the window.

## Response `200`

Successful response

- LogActivityResponse: Bucketed runtime log activity.
  - `data` LogActivityBucket[], required
    - `start_time` string, date-time, required: Bucket start time, inclusive.
    - `end_time` string, date-time, required: Bucket end time, exclusive.
    - `counts` object, required: Counts grouped by activity dimension.
      - `levels` object, required: Counts by normalized log level.
      - `regions` object, required: Counts by event region.
      - `resource_ids` object, required: Counts by resource ID.
    - `total` integer, required: Total events in this bucket.
  - `total` integer, required: Total events counted across all buckets.

## Other responses

- `400`: Bad request - invalid query parameter
- `401`: Unauthorized - invalid or missing token
- `403`: Forbidden - project ownership required
- `404`: Project or resource not found

## Changes

- **2026-10-07** `23e7875e7c4c`: 2 info
  - the endpoint scheme security `ProjectAccessToken` was added to the API
  - added the new optional request property `resource/oneOf[#/components/schemas/LogFunctionRequestResource]/kind`
- **2026-09-19** `3a6f365f3f35`: 8 breaking, 14 info
  - added the new path request parameter `id`
  - added the new required request property `resource`
  - the request's body type changed from no type to `object`
  - the response's body type changed from no type to `object` for status `200`
  - …18 more
- **2026-08-27** `bb44e98aba2e`: 12 breaking, 10 warning
  - the request's body type changed from `object` to no type
  - the response's body type changed from `object` to no type for status `200`
  - the response's body type changed from `object` to no type for status `400`
  - the response's body type changed from `object` to no type for status `401`
  - …18 more
- **2026-07-27** `bb52784e098a`: 3 warning, 4 info
  - the `q` request property's maxLength was set to `512`
  - removed the request property `levels`
  - removed the request property `regions`
  - added the optional property `code` to the response with the `400` status
  - …3 more

[Operation history](https://skmtc.dev/kong/apis/volcano-api/changes/projects/:id/logs/activity/post.md)

---

[API](https://skmtc.dev/kong/apis/volcano-api.md) - [All operations](https://skmtc.dev/kong/apis/volcano-api/llms.txt) - [OpenAPI document](https://skmtc.dev/kong/apis/volcano-api/revisions/84c4488f91e9?raw)
