Skip to content

MCP tools

AI agents drive Polygraph through MCP tools. Each tool maps to one operation in the session lifecycle - discover workspaces, delegate work, push branches, monitor progress.

  • list_accounts - List organizations the current user belongs to.
  • list_repos - Find candidate repositories for a Polygraph session.
  • list_sessions - List Polygraph sessions.
  • search_sessions - Search Polygraph sessions by free-text query, or resolve a commit sha (full or partial) to the session(s) linked to that commit.
  • whoami - Show the current Polygraph authentication and selected organization state.
  • add_repo - Directly add specific repositories to a running Polygraph session by slug, name, owner/repo full name, or repository id.
  • allow_agent - Grant a child agent's pending permission-required request.
  • deny_agent - Deny a child agent's pending permission-required request.
  • git_fetch - Deepen a Polygraph session repository's git history.
  • pack_and_copy - Pack publisher packages and install the tarballs into consumer repos.
  • session_intro - Render the Polygraph session welcome card (markdown) for a session.
  • show_agent - Get the status and recent output of the specified repo's child agent in a Polygraph session from the configured Polygraph URL.
  • spawn_agent - Delegate a task to a child AI agent in a dependent repository.
  • start_session - Initialize Polygraph for the selected repos.
  • stop_agent - Stop an in-progress child agent in a Polygraph session.
  • associate_pr - Associate an existing pull request with a Polygraph session.
  • create_pr - Create draft pull requests for one or more repositories in a Polygraph session.
  • delete_artifact - Permanently delete an artifact from a Polygraph session by name.
  • link_reference - Link an external reference to a session.
  • mark_pr_ready - Mark specified draft pull requests in a Polygraph session as ready for review.
  • push_branch - Push a local git branch to the remote repository.
  • update_session - Update a Polygraph session title and/or user-facing description timeline.
  • upload_artifact - Attach an artifact (plan document, image, or file) to a Polygraph session.
  • get_ci_logs - Retrieves the plain-text log for a specific CI job and saves it to a local file.
  • get_session_logs - Retrieve the parent agent transcript for a Polygraph session as JSON.
  • list_artifacts - List the artifacts attached to a Polygraph session, including their names, kinds, and versions.
  • show_session - Get the specified Polygraph session.
  • archive_session - Archive a Polygraph session.
  • login - Authenticate Polygraph by running the CLI login flow, which opens a browser.
  • logout - Remove stored Polygraph credentials from local config.
  • select_account - Select an organization to operate on.

Besides tools, the MCP server exposes resources that agents can attach as context:

  • polygraph://repos/<repoId> - one resource per organization repo (JSON).
  • polygraph://sessions/<sessionId> - sessions from the last 30 days (JSON), so a prior session can be attached as context for new work.