Skip to main content
Glama
Apex Log MCP Server

Apex Log MCP Server

Official
by certinia

List Org Debug Logs

apexlog_list_org_logs
Read-only

Lists Salesforce org debug logs with filters for user, request, operation, success status, and time range, returning matching counts and log IDs for download.

Instructions

List the debug logs stored in a Salesforce org, with how many match. Pass ids to apexlog_get_org_logs to download them.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "apexlog_list_org_logs"
  }
}

Input Schema

NameRequiredDescriptionDefault
userNoUsername whose activity was logged
limitNoPage size (default: 20)
cursorNonextCursor from the previous page
sortByNoDescending (default: startTime)
requestNoe.g. "Api" or "Application"
operationNoPart of the operation, any case, e.g. "aura" for /aura
succeededNotrue: succeeded logs only; false: failed logs only
targetOrgNoAlias or username of the target Salesforce org. Uses the project default if not specified.
startTimeToNo
startTimeFromNoISO 8601 with a zone, e.g. 2026-10-09T09:00:00Z
minFileSizeBytesNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv2.1.0
    • changedInput schema / properties / succeeded / description
      Previous value: -"false for failed logs only"New value: +"true: succeeded logs only; false: failed logs only"
  2. Addedv2.0.2

TDQS

A3.7/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

readOnlyHint=true already establishes the safety profile, so the description only needs to add operational context. It adds the total-match count behavior and the handoff to the download tool, which is useful, but says nothing about pagination via cursor, the sort default, or whether results are capped at the limit. With annotations covering safety, a 3 is appropriate.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Two sentences, both front-loaded: the capability first, then the follow-up action. There is no redundant restatement of the tool name and no filler.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For an 11-parameter, paginated list tool with no output schema, the description omits pagination behavior (cursor/nextCursor), the default page size, the descending sort default, and roughly what fields the listed entries carry. The annotated read-only status and rich schema compensate somewhat, but an agent still cannot infer how to page through results from the description alone.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 82%, so the schema already documents nearly every parameter including cursor, sortBy, and the filter fields. The description adds no parameter meaning beyond the phrase "Pass ids", leaving it at the baseline for high schema coverage.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description states a specific verb and resource ("List the debug logs stored in a Salesforce org") and adds that the result includes a match count, which distinguishes a metadata/listing operation from a download. It also names the sibling apexlog_get_org_logs and its role, so an agent can tell the two apart without opening the schemas. It stops short of explicitly saying the returned items are metadata rather than log bodies.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The second sentence gives a concrete next-step rule: take the ids from this tool and pass them to apexlog_get_org_logs to download. That covers the primary use decision (discover then fetch) with a named alternative. It gives no guidance on when not to use this tool, or on choosing among the other siblings like apexlog_get_summary or apexlog_list_slow_operations.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.