Skip to main content
Glama

get-audit-logs

Retrieve audit logs from the Miro MCP server within a specified date range, with pagination and sorting options. Ideal for monitoring enterprise activity over the last 90 days.

Instructions

Retrieves a page of audit events from the last 90 days (Enterprise only)

Input Schema

NameRequiredDescriptionDefault
createdAfterYesRetrieve audit logs created after this date (ISO 8601 format)
createdBeforeYesRetrieve audit logs created before this date (ISO 8601 format)
cursorNoCursor for pagination
limitNoMaximum number of results to return (default: 100)
sortingNoSort order for results (default: ASC)

Input Schema (JSON Schema)

{ "$schema": "http://json-schema.org/draft-07/schema#", "additionalProperties": false, "properties": { "createdAfter": { "description": "Retrieve audit logs created after this date (ISO 8601 format)", "type": "string" }, "createdBefore": { "description": "Retrieve audit logs created before this date (ISO 8601 format)", "type": "string" }, "cursor": { "description": "Cursor for pagination", "type": "string" }, "limit": { "description": "Maximum number of results to return (default: 100)", "type": "number" }, "sorting": { "description": "Sort order for results (default: ASC)", "enum": [ "ASC", "DESC" ], "type": "string" } }, "required": [ "createdAfter", "createdBefore" ], "type": "object" }

Implementation Reference

  • The core handler function implementing the logic for the 'get-audit-logs' tool. It builds a query from parameters and fetches audit logs via MiroClient API, handling errors appropriately.
    fn: async ({ createdAfter, createdBefore, cursor, limit, sorting }) => { try { const query: any = {}; if (cursor) query.cursor = cursor; if (limit) query.limit = limit; if (sorting) query.sorting = sorting; const response = await MiroClient.getApi().enterpriseGetAuditLogs( createdAfter, createdBefore, query ); return ServerResponse.text(JSON.stringify(response.body, null, 2)); } catch (error) { process.stderr.write(`Error retrieving audit logs: ${error}\n`); return ServerResponse.error(error); } } };
  • Input schema using Zod for validating parameters of the 'get-audit-logs' tool, including dates, pagination cursor, limit, and sorting.
    args: { createdAfter: z.string().describe("Retrieve audit logs created after this date (ISO 8601 format)"), createdBefore: z.string().describe("Retrieve audit logs created before this date (ISO 8601 format)"), cursor: z.string().optional().nullish().describe("Cursor for pagination"), limit: z.number().optional().nullish().describe("Maximum number of results to return (default: 100)"), sorting: z.enum(["ASC", "DESC"]).optional().nullish().describe("Sort order for results (default: ASC)") },
  • src/index.ts:195-195 (registration)
    Registration of the get-audit-logs tool via ToolBootstrapper.register, which internally calls server.tool with the tool's schema.
    .register(getAuditLogsTool)
  • src/index.ts:94-94 (registration)
    Import of the getAuditLogsTool module for registration.
    import getAuditLogsTool from './tools/getAuditLogs.js';

Other Tools

Related Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/k-jarzyna/mcp-miro'

If you have feedback or need assistance with the MCP directory API, please join our Discord server