Skip to main content

GitHub Copilot — Connect to aprity

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

Supported Copilot surfaces​

SurfaceSupported
Copilot in VS Code (and other editors with Copilot MCP support)Yes
The GitHub Copilot desktop appYes
The Copilot CLIYes
The Copilot cloud agent on github.comNo

The cloud agent runs without a browser, so it cannot complete the Salesforce sign-in. The GitHub Desktop git client has no place to plug in an MCP server.

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.

Copilot in VS Code​

  1. Create .vscode/mcp.json in your workspace, or run MCP: Add Server from the command palette for a user-level entry.

  2. Add the aprity server:

    {
    "servers": {
    "aprity": {
    "type": "http",
    "url": "https://mcp.aprity.ai/v1/mcp/t/<your-slug>"
    }
    }
    }
  3. Open Copilot Chat in Agent mode and select the aprity tools in the tools picker. On first use, your browser opens on your Salesforce login page: sign in and approve the access.

The GitHub Copilot desktop app​

  1. Open Customize in the left rail, then the MCP tab.
  2. Click Add and choose an HTTP server.
  3. Name it aprity, paste your MCP address and save. Leave the headers empty: the Salesforce sign-in opens on first use.

The Copilot CLI​

Run /mcp add in an interactive session and choose HTTP, or edit ~/.copilot/mcp-config.json:

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

The CLI opens your browser for the Salesforce sign-in the first time an aprity tool runs.

Make Copilot use aprity without being asked​

Users do not have to name aprity. The server tells the model that it is the source of truth for your org and must be consulted before answering from general Salesforce knowledge. In practice:

  • "What happens when an Opportunity is updated?" or "Which validation rules block closing a Case?" reach aprity on their own.
  • "How does a before-update trigger work?" is a generic Salesforce question, answered from the model's own knowledge.
  • A question with no hint that it is about your org, such as "what is the Status field?", can go either way.

To remove that ambiguity, add a repository instruction file. Copilot reads .github/copilot-instructions.md at the start of every conversation in that repository:

# Salesforce

Any question about our Salesforce org — its objects, fields, record types, validation
rules, flows, triggers, Apex, integrations, permissions or business processes — must be
answered with the `aprity` MCP tools (start with `ask_help_agent`,
`get_execution_order`, or `analyze_change_request` for a change request) before relying on
general Salesforce knowledge. Cite what the tools return; do not guess behaviour the tools
did not confirm.

Keep the aprity server enabled in the chat's tool picker: a server that is switched off is never consulted, whatever the instructions say.

Check the connection​

Ask Copilot "What does aprity know about our Opportunity object?". The answer should cite automations, validations or fields from your scan.

Disconnect​

Remove the server entry from the configuration. The access Copilot holds expires on its own (after 30 days at most).

If your organization still uses a legacy access token for Copilot, remove the configuration and ask an administrator to revoke the token in Connectors > AI assistants · MCP > Legacy access tokens -- removing the configuration alone leaves the token valid.

Troubleshooting​

SymptomWhere to start
VS Code asks for a client ID instead of opening the browserThe aprity server refused the client registration. Contact contact@aprity.ai with the time of the attempt.
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 callRemove the server and add it again to sign in afresh.
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.