|
| 1 | +# LeadMagic Cursor Plugin |
| 2 | + |
| 3 | +Official LeadMagic plugin for Cursor. It connects Cursor to LeadMagic's hosted MCP server so agents can run credit-aware enrichment—work emails, mobile, B2B profile-to-email, job-change signals, account research, competitors, technographics, people-by-role, and credits—without leaving the editor. |
| 4 | + |
| 5 | +## Overview |
| 6 | + |
| 7 | +This repository packages LeadMagic's hosted MCP integration in a Cursor-native format for marketplace distribution, local installation, and team use. The goal is straightforward: make LeadMagic's enrichment and research workflows available to Cursor agents with minimal setup and clear operational guidance. |
| 8 | + |
| 9 | +The package includes: |
| 10 | + |
| 11 | +- Hosted LeadMagic MCP connectivity for Cursor |
| 12 | +- The current LeadMagic MCP surface: |
| 13 | + - 10 tools: credits, work email validate/find, mobile, LinkedIn-to-email, job-change detection, account research, competitors, technographics, people-by-role |
| 14 | + - 1 shared docs resource: `leadmagic://docs` |
| 15 | + - 2 built-in prompts: `account_research` and `contact_lookup` |
| 16 | +- Four focused Cursor skills aligned to the current hosted MCP surface: |
| 17 | + - contact enrichment |
| 18 | + - account intelligence |
| 19 | + - prospect list QA |
| 20 | + - signal research |
| 21 | +- One default rule that nudges Cursor toward efficient, low-duplication LeadMagic usage |
| 22 | + |
| 23 | +## Why Use It |
| 24 | + |
| 25 | +Use this plugin when you want Cursor to help with: |
| 26 | + |
| 27 | +- validating or finding work emails, or resolving email from a B2B profile URL |
| 28 | +- mobile lookup, job-change checks, and role-based people search at a company |
| 29 | +- researching account fit, funding context, competitors, and technology signals |
| 30 | +- keeping enrichment workflows credit-aware and repeatable |
| 31 | + |
| 32 | +## Data and privacy |
| 33 | + |
| 34 | +MCP tool calls send the parameters you or the agent provide (for example emails, names, company names or domains, profile URLs) to LeadMagic's hosted service using your `LEADMAGIC_API_KEY`. See [Privacy](https://leadmagic.io/privacy) and [Terms](https://leadmagic.io/legal/terms). Support: [leadmagic.io/docs/support](https://leadmagic.io/docs/support). |
| 35 | + |
| 36 | +## Hosted MCP Configuration |
| 37 | + |
| 38 | +The plugin points Cursor at LeadMagic's hosted MCP endpoint: |
| 39 | + |
| 40 | +- MCP endpoint: `https://mcp.leadmagic.io/mcp` |
| 41 | +- MCP transport: `http` |
| 42 | +- Auth header: `x-leadmagic-key` |
| 43 | + |
| 44 | +Users provide their API key through the `LEADMAGIC_API_KEY` environment variable. The plugin forwards that key to the hosted MCP server at runtime. |
| 45 | + |
| 46 | +## What The MCP Supports Today |
| 47 | + |
| 48 | +The hosted MCP surface supports: |
| 49 | + |
| 50 | +- `check_credit_balance`, `validate_work_email`, `find_work_email` |
| 51 | +- `find_mobile_number`, `linkedin_profile_to_work_email`, `detect_job_change` |
| 52 | +- `research_account`, `list_company_competitors`, `get_company_technographics`, `find_people_by_role` |
| 53 | + |
| 54 | +The broader REST API includes more endpoints (jobs, ads, analytics, etc.); this plugin tracks the hosted MCP tool list above. See `leadmagic://docs` in Cursor for the live tool reference. |
| 55 | + |
| 56 | +## Quick Start |
| 57 | + |
| 58 | +You can use this plugin in three ways: |
| 59 | + |
| 60 | +- install it from the Cursor marketplace after approval |
| 61 | +- import the repository into a Cursor team marketplace for internal distribution |
| 62 | +- symlink it locally for development and pre-submission testing |
| 63 | + |
| 64 | +### Install from the marketplace |
| 65 | + |
| 66 | +After approval, install the plugin from the marketplace panel in Cursor. |
| 67 | + |
| 68 | +### Import as a team marketplace |
| 69 | + |
| 70 | +For private team distribution in Cursor: |
| 71 | + |
| 72 | +1. Open `Dashboard -> Settings -> Plugins`. |
| 73 | +2. In `Team Marketplaces`, click `Import`. |
| 74 | +3. Paste `https://github.com/LeadMagic/leadmagic-cursor-plugin`. |
| 75 | +4. Review the parsed plugin and save the marketplace. |
| 76 | + |
| 77 | +### Install locally for testing |
| 78 | + |
| 79 | +#### 1. Set your API key |
| 80 | + |
| 81 | +```bash |
| 82 | +export LEADMAGIC_API_KEY="your_api_key_here" |
| 83 | +``` |
| 84 | + |
| 85 | +#### 2. Link the repository into Cursor |
| 86 | + |
| 87 | +If you are using this repository locally: |
| 88 | + |
| 89 | +```bash |
| 90 | +npm ci |
| 91 | +npm run install:local |
| 92 | +``` |
| 93 | + |
| 94 | +This creates a symlink at `~/.cursor/plugins/local/leadmagic` pointing to this repository. |
| 95 | + |
| 96 | +Then reload Cursor with `Developer: Reload Window`. |
| 97 | + |
| 98 | +#### 3. Verify the connection |
| 99 | + |
| 100 | +Ask Cursor one of these: |
| 101 | + |
| 102 | +- `Check my LeadMagic credit balance.` |
| 103 | +- `Validate this email with LeadMagic: jane@company.com` |
| 104 | +- `Research Ramp as an account and summarize the best buying signals.` |
| 105 | + |
| 106 | +## Local Development |
| 107 | + |
| 108 | +From the repository root, install dependencies and validate the package: |
| 109 | + |
| 110 | +```bash |
| 111 | +npm ci |
| 112 | +npm run validate |
| 113 | +``` |
| 114 | + |
| 115 | +To link the plugin into Cursor locally: |
| 116 | + |
| 117 | +```bash |
| 118 | +npm run install:local |
| 119 | +``` |
| 120 | + |
| 121 | +To remove the local symlink later: |
| 122 | + |
| 123 | +```bash |
| 124 | +npm run uninstall:local |
| 125 | +``` |
| 126 | + |
| 127 | +## Troubleshooting |
| 128 | + |
| 129 | +### Cursor cannot see `LEADMAGIC_API_KEY` |
| 130 | + |
| 131 | +On macOS, if Cursor was launched from the dock or Finder, it may not inherit your shell environment. If `LEADMAGIC_API_KEY` is set in your terminal but LeadMagic still fails inside Cursor, launch Cursor from the same shell session or reload it after exporting the variable in an environment Cursor can see. |
| 132 | + |
| 133 | +### Authentication fails |
| 134 | + |
| 135 | +Confirm that: |
| 136 | + |
| 137 | +- `LEADMAGIC_API_KEY` is set in the environment visible to Cursor |
| 138 | +- the plugin is using `https://mcp.leadmagic.io/mcp` |
| 139 | +- the request header is `x-leadmagic-key` |
| 140 | + |
| 141 | +### You need exact tool details |
| 142 | + |
| 143 | +Use the shared docs resource `leadmagic://docs` or review: |
| 144 | + |
| 145 | +- [LeadMagic MCP Setup](https://leadmagic.io/docs/mcp/setup) |
| 146 | +- [LeadMagic MCP Tools](https://leadmagic.io/docs/mcp/tools) |
| 147 | +- [LeadMagic MCP Troubleshooting](https://leadmagic.io/docs/mcp/troubleshooting) |
| 148 | + |
| 149 | +## Example Prompts |
| 150 | + |
| 151 | +- `Check my LeadMagic credit balance.` |
| 152 | +- `Validate these prospect emails and tell me which are safe to use.` |
| 153 | +- `Find the best work email for Jane Doe at Snowflake.` |
| 154 | +- `Research Ramp as an account and tell me the best buying signals.` |
| 155 | +- `Use contact_lookup to validate jane@company.com and summarize the result.` |
| 156 | +- `Use account_research for Stripe and summarize the strongest GTM angle.` |
| 157 | + |
| 158 | +## Repository Layout |
| 159 | + |
| 160 | +```text |
| 161 | +.cursor-plugin/plugin.json |
| 162 | +.github/pull_request_template.md |
| 163 | +.github/workflows/validate-plugin.yml |
| 164 | +assets/logo.svg |
| 165 | +mcp.json |
| 166 | +package-lock.json |
| 167 | +schemas/plugin.schema.json |
| 168 | +rules/leadmagic-usage.mdc |
| 169 | +skills/*/SKILL.md |
| 170 | +scripts/install-local-plugin.mjs |
| 171 | +scripts/validate-plugin.mjs |
| 172 | +README.md |
| 173 | +SUBMISSION.md |
| 174 | +CHANGELOG.md |
| 175 | +``` |
| 176 | + |
| 177 | +## Validation |
| 178 | + |
| 179 | +```bash |
| 180 | +npm run validate |
| 181 | +``` |
| 182 | + |
| 183 | +The validator checks this package against a vendored snapshot of Cursor's official `plugin.schema.json` and then applies LeadMagic-specific assertions for: |
| 184 | + |
| 185 | +- the hosted MCP endpoint |
| 186 | +- `LEADMAGIC_API_KEY` interpolation |
| 187 | +- the canonical logo asset and submission logo URL |
| 188 | +- skills and rules metadata |
| 189 | +- repository and submission copy consistency |
| 190 | + |
| 191 | +## Marketplace Submission |
| 192 | + |
| 193 | +Use `SUBMISSION.md` for ready-to-paste marketplace form values, reviewer notes, and a final pre-submit checklist. |
| 194 | + |
| 195 | +## Companion Resources |
| 196 | + |
| 197 | +- OpenAPI snapshot and schema docs: [LeadMagic OpenAPI](https://github.com/LeadMagic/leadmagic-openapi) |
| 198 | +- Product docs index: [leadmagic.io/docs/llms.txt](https://leadmagic.io/docs/llms.txt) |
| 199 | +- Website: [leadmagic.io](https://leadmagic.io) |
| 200 | +- Privacy: [leadmagic.io/privacy](https://leadmagic.io/privacy) |
| 201 | +- Terms: [leadmagic.io/legal/terms](https://leadmagic.io/legal/terms) |
0 commit comments