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
- Returns an array containing metadata about a collection of activity logs from a specific board
- Can only be nested within a
boards
query - Limit: up to 10,000 logs total
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 argument(s) 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 field(s) to specify what information your activity_logs
query will return.
Field | Description | Enum values |
---|---|---|
account_id String! | The unique identifier of the account that initiated the event. | |
data String! | The item's column values. | |
entity String! | The entity of the event that was changed. | board pulse |
event String! | The action that took place. | |
id String! | The unique identifier of the activity log event. | |
user_id String! | The unique identifier of the user who initiated the event. | |
created_at String! | The time of the event in 17-digit Unix time. |
Created_at
field
Created_at
fieldThe timestamps returned by this field are formatted as UNIX time with 17 digits.
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.
myDate = new Date(15880281464518396 / 10000)
import pandas as pd
pd.to_datetime(16155031105053254 / 10000000, unit='s')
<?php
$timestamp=16155031105053254/10000000;
echo gmdate("Y-m-d\TH:i:s\Z", $timestamp);
?>