Skip to main content

MCP server for Salesforce debug log analysis — connect, capture, scan, and search Apex logs from any AI-powered editor.

Project description

sf-log-analyzer

MCP server for Salesforce debug log analysis. Connect to any Salesforce org, set up log capture, scan logs for errors, and search log content — all from your AI-powered editor (Cursor, VS Code, etc.).

Quick Start

Add to your .cursor/mcp.json or .vscode/mcp.json:

{
  "mcpServers": {
    "sf-log-analyzer": {
      "command": "uvx",
      "args": ["sf-log-analyzer"]
    }
  }
}

Requires uv installed. No other setup needed.

Tools (16 total)

Connection

  • sf_list_orgs — List Salesforce CLI-authorized orgs
  • sf_connect_org — Connect via CLI alias
  • sf_connect — Connect via raw session ID (for subscriber/ISV orgs)
  • sf_disconnect — Disconnect and clear cache

Log Capture Setup

  • sf_list_users — List active users
  • sf_list_debug_levels — List existing debug levels
  • sf_create_debug_level — Create a new debug level
  • sf_setup_logging — One-step: create debug level + trace flag
  • sf_list_trace_flags — List active trace flags
  • sf_create_trace_flag — Create a trace flag
  • sf_delete_trace_flag — Delete a trace flag

Debug Log Analysis

  • sf_list_logs — List debug logs (with filters)
  • sf_get_log — Fetch full log body
  • sf_scan_log — Scan a log for errors, exceptions, governor limits
  • sf_scan_all_logs — Batch scan with summary
  • sf_search_log — Full-text search within a log

Requirements

  • Python 3.10+
  • Salesforce CLI (sf) for CLI-based connections (optional)

License

MIT

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

sf_log_analyzer-0.1.1.tar.gz (12.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

sf_log_analyzer-0.1.1-py3-none-any.whl (14.5 kB view details)

Uploaded Python 3

File details

Details for the file sf_log_analyzer-0.1.1.tar.gz.

File metadata

  • Download URL: sf_log_analyzer-0.1.1.tar.gz
  • Upload date:
  • Size: 12.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.10.3 {"installer":{"name":"uv","version":"0.10.3","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":null,"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for sf_log_analyzer-0.1.1.tar.gz
Algorithm Hash digest
SHA256 033e9557bd1b340b802be42bde6868705cd3503f9fff0475e96e040127e37f04
MD5 a68efd6eb55e4085711548add43aa7cf
BLAKE2b-256 b355111712f27f3752e0ccf8e6c303fea13bbb558eb4843e3e4ce179b2c82e12

See more details on using hashes here.

File details

Details for the file sf_log_analyzer-0.1.1-py3-none-any.whl.

File metadata

  • Download URL: sf_log_analyzer-0.1.1-py3-none-any.whl
  • Upload date:
  • Size: 14.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.10.3 {"installer":{"name":"uv","version":"0.10.3","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":null,"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for sf_log_analyzer-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 b3efc6d2c0c14d355291fec987ace5ea7e59670a9818a8be400af9e3fc5c7407
MD5 c6fd83d2402be98a8382cefc217bd865
BLAKE2b-256 1e859a530dea313bff53fe68db84a4ae38d895aaac0b9840d016ed395ff7b7ee

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page