Skip to content
Pile
Esc
navigateopen⌘Jpreview
On this page

Agent setup

Connect coding agents to Pile through MCP, the CLI, and the TypeScript SDK.

Agent setup

Pile is backend-first. The surfaces for humans and agents are the HTTP API, the MCP server, the CLI, and the TypeScript SDK.

MCP

The Pile MCP server exposes every OpenAPI operation as a typed MCP tool. Point your MCP client at https://<your-worker>/mcp and include a workspace-scoped API token in the Authorization header.

Cursor example

{
  "mcpServers": {
    "pile": {
      "url": "https://<your-worker>/mcp",
      "headers": {
        "Authorization": "Bearer <your-api-token>"
      }
    }
  }
}

Common tools

  • postWorkspaces — create a workspace
  • postWorkspacesOrganizationIdTeams — create a team
  • postWorkspacesOrganizationIdIssues — create an issue
  • getWorkspacesOrganizationIdIssues — list issues
  • postWorkspacesOrganizationIdSupportTickets — create a support ticket

CLI

Install the pile-cli package and authenticate with an API key. The CLI defaults to http://127.0.0.1:8787 (local wrangler dev); point it at your deployment with PILE_BASE_URL or pile config set --base-url.

export PILE_BASE_URL=https://<your-worker>
pile config set --api-key <key>
pile issues list --workspace org_vortex_main
pile support tickets list --workspace org_vortex_main

SDK

The pile-client package is an openapi-fetch client typed against the Pile OpenAPI spec.

import { createPileClient } from "pile-client";

const client = createPileClient({
  baseUrl: process.env.PILE_BASE_URL!, // e.g. https://<your-worker>
  apiKey: process.env.PILE_API_KEY!,
});

const { data } = await client.GET("/workspaces", {});

Skills

The local agent skills are in .devin/skills:

  • pile-mcp — MCP usage
  • pile-cli — CLI usage
  • pile-sdk — TypeScript SDK usage

These skills are also published in llms.txt for agents that read the docs site.

Was this page helpful?