Skip to main content

Claude Code (CLI) — Connect to aprity

You add aprity to Claude Code as a remote HTTP MCP server and sign in with your Salesforce login. Claude Code can then look up your org's objects, rules and automations while it works in your terminal. See Remote MCP Server for what the connection gives you, plan availability and quotas.

Prerequisites​

  • Your aprity organization is on the Intelligence or Trial plan.

  • Your administrator has completed the administrator setup and given you your organization's MCP address (from Connectors in the aprity web portal). It looks like:

    https://mcp.aprity.ai/v1/mcp/t/<your-slug>
  • A Salesforce login on the org that aprity documents, with a profile authorized on the aprity Connected App.

  • A version of Claude Code that supports remote MCP servers over HTTP with OAuth.

  • A browser on the same machine, for the sign-in.

Step 1 — Add the aprity server​

Run:

claude mcp add --transport http aprity https://mcp.aprity.ai/v1/mcp/t/<your-slug>

To share the server with your team through a repository, you can instead declare it in a .mcp.json file at the root of the project:

{
"mcpServers": {
"aprity": {
"type": "http",
"url": "https://mcp.aprity.ai/v1/mcp/t/<your-slug>"
}
}
}

The file contains no secret, so it can be committed: each developer signs in with their own Salesforce login.

Step 2 — Sign in​

Start a Claude Code session and open the MCP server list with /mcp. Select aprity and authenticate: your browser opens on your Salesforce login page. Sign in with your usual Salesforce credentials and approve the access. Claude Code stores its access and renews it on its own.

Check the connection​

Ask Claude Code "Which aprity tools are available?", then a question such as "What does aprity know about our Account object?". The answer should cite automations, validations or fields from your scan.

Disconnect​

Remove the server with claude mcp remove aprity (or remove the entry from .mcp.json).

Troubleshooting​

SymptomWhere to start
The aprity server is not listedCheck the claude mcp add command or the JSON syntax of .mcp.json, then start a new session.
The browser sign-in cannot openThe sign-in needs a browser on the same machine; headless environments (CI, remote shells without a browser) are not supported.
Salesforce shows redirect_uri_mismatchAsk your administrator to add the MCP callback URL to the Connected App (administrator setup).
The sign-in fails or loopsMCP authentication failed.
401 Unauthorized on every tool callAuthenticate again from /mcp.
Tools are refusedCheck that your plan includes the Remote MCP Server and that the tool-call quota is not used up.

For anything else, contact contact@aprity.ai.