Get database activity
GEThttps://api.instacloud.com/projects/{projectId}/database/activity
Token scope: account · org · project — read-only tokens allowed.
Currently running queries (pg_stat_activity/provider API, ≤100). Provider-specific; may wake a suspended database.
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
branch | query | string | no | branch name (default branch if omitted) |
group | query | string | no | postgres service name (default: the sole postgres service) |
projectId | path | string | yes |
Responses
200
Default Response
| Field | Type | Required | Description |
|---|---|---|---|
queries | object[] | no | |
queries.pid | integer | no | |
queries.state | string | no | |
queries.waitEvent | string | no | |
queries.durationMs | number | no | |
queries.query | string | no | |
queries.application | string | no | |
queries.client | string | no | |
queries.queryStart | string | no |
400
Default Response
| Field | Type | Required | Description |
|---|---|---|---|
error | string | yes |
403
Default Response
| Field | Type | Required | Description |
|---|---|---|---|
error | string | yes |
404
Default Response
| Field | Type | Required | Description |
|---|---|---|---|
error | string | yes |
409
Default Response
| Field | Type | Required | Description |
|---|---|---|---|
error | string | yes |
502
Default Response
| Field | Type | Required | Description |
|---|---|---|---|
error | string | yes |