Learn how to query activity logs from a monday board using the platform API
Activity logs are records of all activities performed on a board. You can use them to see which actions were performed on your boards, when, and by whom.
Queries
You can use the activity_logs query to retrieve activity log data via the API.
- Limit: up to 10,000 logs
- Returns an array containing metadata about a collection of activity logs from a specific board
- Can only be nested within a
boardsquery
query {
boards(
ids: [1234567890]
) {
activity_logs(
from: "2021-07-23T00:00:00Z"
to: "2021-07-26T00:00:00Z"
) {
id
event
data
}
}
}import { ApiClient } from "@mondaydotcomorg/api";
const mondayApiClient = new ApiClient({ token: myToken });
const query = `query ($board_id: [ID!], $from: ISO8601DateTime!, $to: ISO8601DateTime!) { boards (ids: $board_id) { activity_logs (from: $from, to: $to) { id event data }}}`;
const variables = {
board_id: 1234567890,
from: "2024-07-23T00:00:00Z",
to: "2024-07-26T00:00:00Z",
};
const response = await mondayApiClient.request(query, variables);Arguments
You can use the following arguments to reduce the number of results returned in your activity_logs query. Results are returned in reverse chronological order.
| Argument | Description |
|---|---|
column_ids [String] | The specific columns to return events for. |
from ISO8601DateTime | From timestamp (ISO8601). |
group_ids [String] | The specific groups to return events for. |
item_ids [ID!] | The specific items to return events for. |
limit Int | The number of activity log events to return. The default is 25. |
page Int | The page number to return. Starts at 1. |
to ISO8601DateTime | To timestamp (ISO8601). |
user_ids [ID!] | The specific users to return events for. |
Fields
You can use the following fields to specify what information your activity_logs query will return.
Field | Description | Enum Values |
|---|---|---|
account_id | The unique identifier of the account that initiated the event. | |
data | The item's column values. | |
entity | The entity of the event that was changed. |
|
event | The action that took place. | |
id | The unique identifier of the activity log event. | |
user_id | The unique identifier of the user who initiated the event. | |
created_at | The time of the event in 17-digit Unix time. To convert the timestamp to UNIX time in milliseconds, divide the 17-digit value by 10,000 and round to the nearest integer. For UNIX time in seconds, divide the value by 10,000,000. |
