> ## Documentation Index
> Fetch the complete documentation index at: https://storekit.com/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Connect Cursor or VS Code

> Add the storekit MCP server to Cursor, or to VS Code with GitHub Copilot, from a short JSON config, then sign in with your storekit login.

**Time:** about five minutes. **You need:** a storekit login on an account enabled for the AI assistant beta, and Cursor or VS Code (with the GitHub Copilot extension and agent mode). Both editors support remote MCP servers over HTTP with OAuth sign-in.

This is the route for a developer or analyst who wants storekit data next to their code or notebooks — for example to check what the API returns while building a webhook consumer.

## Add the Server

<Tabs>
  <Tab title="Cursor">
    <Steps>
      <Step title="Open the MCP config">
        Go to **Cursor Settings** → **Tools & MCP** (older versions: **MCP**) and choose **Add Custom MCP**. Cursor opens `mcp.json`. Use `~/.cursor/mcp.json` to make the server available everywhere, or `.cursor/mcp.json` inside a project.
      </Step>

      <Step title="Add storekit">
        ```json theme={null}
        {
          "mcpServers": {
            "storekit": {
              "url": "https://mcp.storekit.com/mcp"
            }
          }
        }
        ```
      </Step>

      <Step title="Sign in">
        Save the file. Back in **Tools & MCP**, the storekit entry shows **Needs login**; click it.

        Your browser opens the storekit dashboard. Sign in with your usual storekit email and password if you are not already signed in. You briefly see **Connecting your MCP client, please wait...** and are then sent back to your assistant.

        <Info>
          The assistant is connected to the account of the user who signed in. If you belong to more than one storekit account, it uses your first account. There is no account picker during sign-in.
        </Info>

        The entry turns green and lists the storekit tools.
      </Step>
    </Steps>
  </Tab>

  <Tab title="VS Code">
    <Steps>
      <Step title="Open the MCP config">
        Run **MCP: Add Server** from the command palette, choose **HTTP (HTTP or Server-Sent Events)**, enter the URL `https://mcp.storekit.com/mcp`, the name `storekit`, and whether to store it in your user settings or the workspace. VS Code writes the entry to `mcp.json` for you; it looks like this:

        ```json theme={null}
        {
          "servers": {
            "storekit": {
              "type": "http",
              "url": "https://mcp.storekit.com/mcp"
            }
          }
        }
        ```
      </Step>

      <Step title="Sign in">
        VS Code prompts you to allow authentication for the new server. Allow it.

        Your browser opens the storekit dashboard. Sign in with your usual storekit email and password if you are not already signed in. You briefly see **Connecting your MCP client, please wait...** and are then sent back to your assistant.

        <Info>
          The assistant is connected to the account of the user who signed in. If you belong to more than one storekit account, it uses your first account. There is no account picker during sign-in.
        </Info>
      </Step>

      <Step title="Use it in agent mode">
        Open Copilot Chat, switch to **Agent** mode and check the tools picker to confirm the storekit tools are listed and ticked.
      </Step>
    </Steps>
  </Tab>
</Tabs>

## Ask Your First Question

Ask your assistant:

```text theme={null}
Which stores are on my storekit account?
```

<Check>
  The assistant lists your stores by name, with their timezone and currency. If it does, you are connected. Try a second question — "How many orders did we take yesterday?" — then head to [What You Can Ask](/docs/guides/ai/what-you-can-ask).
</Check>

If the assistant says it cannot reach storekit or asks you to sign in again, see [Troubleshooting](/docs/guides/ai/troubleshooting).

## Approving Writes

Both editors ask before running a tool unless you have allowed it for the session. Keep that prompt on for the two storekit writes — creating a discount code and creating a payment link — and read the arguments before you continue.

## Disconnecting

Remove the `storekit` entry from `mcp.json`. In VS Code you can also run **MCP: Reset Trust** or clear the saved sign-in from the server's context menu in the **Extensions** view.


## Related topics

- [Connect Your AI Agent](/docs/guides/ai/overview.md)
- [Authentication](/docs/developers/mcp/authentication.md)
- [Permissions & Privacy](/docs/guides/ai/permissions-and-privacy.md)
- [Developer Introduction](/docs/developers/introduction.md)
- [6. Connect a cloud receipt printer](/docs/getting-started/launch/connect-printing.md)
