Kognyt — Salesforce Org Context for VS Code
Kognyt is a VS Code extension that gives your AI Salesforce Org Context inside VS Code, Cursor, and other VS Marketplace IDEs.
Your AI assistant knows Apex syntax. It does not know your org. It does not know about your existing triggers, your custom fields, your active flows, or the governor limit budget left in your transaction context. Kognyt fixes that.
Install once. Connect your org. Kognyt can then supply the context of your actual Salesforce environment to supported AI workflows. The built-in MCP server is the supporting path for compatible assistants you already use.
What You Get
- GitHub Copilot — Kognyt registers as Language Model Tools. Copilot automatically calls them when you ask Salesforce questions.
- Cursor — Kognyt runs as an MCP server. Cursor is auto-configured on install.
- Claude Code, Codex, Cline, Kilo Code — Auto-configured. No manual setup required.
- Any MCP-compatible assistant — Connect via the built-in MCP server.
Zero config after install
Install the extension, sign in, connect your org. Kognyt auto-detects Cursor, Cline, Kilo Code, Claude Code, and Codex and configures the MCP server for each of them automatically.
1 knowledge tool — available immediately, no org required:
| Tool |
What it does |
| Salesforce Knowledge |
General Salesforce docs, rules, patterns, trade-offs, release guidance, and governed warnings |
6 org and workspace tools — require a connected Salesforce org:
| Tool |
What it does |
| Salesforce Org Context |
Existing triggers, active flows, schema context, tribal knowledge, and likely conflicts for your intent |
| Salesforce Object Schema |
Full field list, types, relationships, validation rules, and record types for any object |
| Salesforce Impact Analysis |
What depends on an Apex class, interface, enum, or trigger before you change it |
| Salesforce Metadata Retrieve |
Pull Salesforce metadata from the active org into your local workspace |
| Salesforce Metadata Deploy |
Validate or deploy local workspace metadata to the active org |
| Salesforce Metadata Drift |
Compare local metadata with the active org and classify it as local-only, org-only, in-sync, or diverged |
Local workspace intelligence
Kognyt uses tree-sitter parsing and PageRank-based ranking to scope context precisely to what you are working on. This scoping runs locally on your machine.
Kognyt: Retrieve Metadata
Kognyt: Deploy Metadata
Kognyt: Validate Metadata Deployment
Kognyt: Inspect Metadata Drift
- Default:
kognyt.metadataExecutionBackend = cloud
- Optional fallback:
kognyt.metadataExecutionBackend = localSfCli
The Kognyt backend remains the primary retrieve/deploy path. It keeps Kognyt's workspace sync state, org-aware tooling, and deployment diagnostics aligned with the active Salesforce org.
If you explicitly opt into localSfCli, set kognyt.sfCliTargetOrg to the Salesforce CLI alias or username you want Kognyt to use. Before every retrieve or deploy, Kognyt runs sf org display --target-org <value> --json and refuses local execution unless the CLI target's Salesforce org ID and instance URL both match the active Salesforce org.
Current limits of the local CLI fallback:
- It is opt-in and off by default.
- It applies to extension-side retrieve/deploy commands and VS Code LM tools, not the standalone MCP server.
- Retrieve does not support
single_package on the local backend.
- Deploy does not support
single_package, allow_missing_files, or auto_update_package on the local backend.
run_tests is only supported when test_level is RunSpecifiedTests.
Getting Started
1. Install
Install Kognyt from Open VSX or your VS Code-compatible extension registry.
2. Sign In
- Open the Kognyt sidebar in the Explorer panel.
- Under Account, click Sign In.
- Complete the browser sign-in flow with your Kognyt account.
- Return to VS Code after the sign-in succeeds.
You can also open the Command Palette (Ctrl+Shift+P / Cmd+Shift+P) and run Kognyt: Log In.
3. Connect Your Org
- In the Kognyt sidebar, open Salesforce Orgs.
- Click Connect Salesforce Org or run
Kognyt: Connect Salesforce Org from the Command Palette.
- Choose your Salesforce environment and complete the OAuth flow.
- Back in VS Code, select the org you want Kognyt to use.
Kognyt will sync the org metadata it needs for context, schema lookup, and impact analysis.
4. Done
Your AI assistant now has org intelligence. Open Copilot Chat, Cursor, or your preferred AI tool and ask a Salesforce question. Kognyt handles the rest.
Salesforce project detected? Kognyt activates automatically when it finds sfdx-project.json or sf-project.json in your workspace.
| Tool |
Requires Org |
Tier |
| Salesforce Knowledge |
No |
Free |
| Salesforce Org Context |
Yes |
Free |
| Salesforce Object Schema |
Yes |
Free |
| Salesforce Impact Analysis |
Yes |
Free |
| Salesforce Metadata Retrieve |
Yes |
Free |
| Salesforce Metadata Deploy |
Yes |
Free |
| Salesforce Metadata Drift |
Yes |
Free |
Requirements
- VS Code 1.99 or later
- A Kognyt account — free at kognyt.dev
- A Salesforce org (Production or Sandbox) — required for org tools only
Pricing
Free during beta. Kognyt's current 7-tool surface is available during beta. Processing limits apply.
Security & data handling
Kognyt is a connected service. To make your AI assistant genuinely org-aware, Kognyt processes your Salesforce org's code and metadata — that processing is what makes the results fit your org instead of generic Salesforce. Here is how that data is handled and protected.
How your Salesforce org is connected
- You connect through Salesforce OAuth — Kognyt never sees or stores your Salesforce password.
- Kognyt completes the authorization and stores your Salesforce refresh token encrypted at rest (AES-256-GCM). Short-lived access tokens are generated on demand and are not stored.
What Kognyt processes and stores
To power org context, impact analysis, and metadata workflows, Kognyt syncs and stores:
- Object schema — objects, fields, relationships, and record types.
- Declarative automation — flows and validation rules.
- Programmatic automation — Apex classes and triggers, including source.
- UI components — Lightning Web Components (LWC) and Aura components: their markup, JavaScript, and styles.
- Security and access metadata — profiles, permission sets, and field permissions.
- Plus the derived graph and embeddings used to reason about your org.
From your editor, the Kognyt extension also sends the active file — its path and contents — along with your current selection, the Salesforce entities it detects, and your prompt, so results are grounded in what you're working on. For a metadata deploy, the metadata being deployed is uploaded. (Retrieve and deploy can instead run through your local Salesforce CLI with kognyt.metadataExecutionBackend = localSfCli.)
Deletion & revocation
- Disconnect an org and Kognyt revokes its Salesforce refresh token and deletes that org's synced metadata and source.
- Remove a workspace and Kognyt removes its connected orgs and their data.
In transit
- The Kognyt extension communicates with Kognyt only over HTTPS; the service endpoint is restricted to
*.kognyt.dev.
Local session & recommendations
- Kognyt stores a local session token so your AI tools can use its features. Run
Kognyt: Log Out to clear it.
- Do not use Kognyt on shared or untrusted machines.
Links