open-index/open-npm huggingface dataset:
npm package: @openctx/cli
Description: OpenCtx CLI
Latest version: 0.0.18

# OpenCtx CLI

The `@openctx/cli` package is a command-line interface for interacting with OpenCtx providers.

## Usage

The OpenCtx CLI requires Node 22 or later (see known issues below).

```shell
$ npm install -g @openctx/cli@latest

$ export OPENCTX_CONFIG='{"enable":true,"debug":true,"providers":{"https://openctx.org/npm/@openctx/provider-web": true}}'

$ openctx meta
[{"name":"URLs", "annotations": {"selectors": []}, ...}]

$ openctx mentions https://example.com
#1 Example Domain — https://example.com

$ openctx items https://example.com
#1 Example Domain — https://example.com
   - hover.text: Fetched from https://example.com
   - ai.content: (575 characters)
```

`OPENCTX_CONFIG` can be one of:
- JSON object of config
- Path to JSON config
- Provider URI
- Path to provider bundle

## Known issues

- Using providers from JavaScript bundles fetched over HTTPS requires [Node 22](https://nodejs.org/api/esm.html#https-and-http-imports) and running with the `node --experimental-modules --experimental-network-imports` option. These experimental flags are set in the `openctx` CLI when it invokes `node`, so you *should* not need to manually pass these.

## Development

- [Source code](https://sourcegraph.com/github.com/sourcegraph/openctx/-/tree/bin)
- [Docs](https://openctx.org/docs/clients/cli)
- License: Apache 2.0
npm package: @openctx/codemirror-extension
Description: OpenCtx extension for CodeMirror
Latest version: 0.0.18

# OpenCtx extension for CodeMirror

The [`@openctx/codemirror-extension`](https://www.npmjs.com/package/@openctx/codemirror-extension) npm package implements a [CodeMirror](https://codemirror.net/) extension that shows [OpenCtx](https://openctx.org) items in the editor.

Check out the [OpenCtx playground](https://openctx.org/playground) for a live example of this extension.

## Usage

Install it:

```shell
npm install @openctx/codemirror-extension @openctx/client
```

Set up an OpenCtx client and fetch items:

```typescript
import { createClient } from '@openctx/client'

// Set up a client.
const client = createClient({
  configuration: () =>
    Promise.resolve({
      enable: true,
      providers: {
        'https://openctx.org/npm/@openctx/provider-hello-world': true,
      },
    }),
  makeRange: r => r,
  logger: console.error,
})

// Fetch items for the resource.
const items = await client.items({ uri: 'file:///foo.js', content: 'my file\nhello\nworld' })
```

Then register the extension with CodeMirror.

If you're using React, the `useOpenCtxExtension` hook makes it easy:

```typescript
import { useOpenCtxExtension } from '@openctx/codemirror-extension'

function MyComponent() {
  // ...

  // A helpful React hook if using React.
  const octxExtension = useOpenCtxExtension({
    visibility: true,
    items,
  })

  // Pass `octxExtension` to CodeMirror as an extension.

  // ...
}
```

Otherwise, set up the extension manually. If you're using React, you can get UI components from `@openctx/ui-react`; otherwise, use `@openctx/ui-standalone`.

```tsx
import type { Extension } from '@codemirror/state'
import { openCtxData, showOpenCtxDecorations } from '@openctx/codemirror-extension'
import { ChipList, IndentationWrapper } from '@openctx/ui-react'

const octxExtension: Extension = [
  openCtxData(items),
  showOpenCtxDecorations({
    visibility: true,
    createDecoration(container, { indent, items }) {
      const root = createRoot(container)
      root.render(
        <IndentationWrapper indent={indent}>
          <ChipList items={items} chipClassName="octx-chip" popoverClassName="octx-chip-popover" />
        </IndentationWrapper>
      )
      return {
        destroy() {
          root.unmount()
        },
      }
    },
  }),
]

// Pass `octxExtension` to CodeMirror as an extension.
```

## Demo

The [OpenCtx playground](https://openctx.org/playground) is a live demo of this extension.

You can also clone this repository and run `pnpm run demo` from this directory, then visit http://localhost:5902. See the `demo/` dir for source code.

## Development

- [Source code](https://sourcegraph.com/github.com/sourcegraph/openctx/-/tree/client/codemirror)
- [Docs](https://openctx.org/docs/clients/codemirror)
- License: Apache 2.0
npm package: @openctx/monaco-editor-extension
Description: OpenCtx extension for Monaco Editor
Latest version: 0.0.17

# OpenCtx extension for Monaco Editor

The [`@openctx/monaco-editor-extension`](https://www.npmjs.com/package/@openctx/monaco-editor-extension) npm package implements a [Monaco Editor](https://microsoft.github.io/monaco-editor/) extension that shows [OpenCtx](https://openctx.org) items on files.

## Usage

Install it:

```shell
npm install @openctx/monaco-editor-extension @openctx/client
```

Set up an OpenCtx client:

```typescript
import { createClient } from '@openctx/client'
import { createExtension, makeRange } from '@openctx/monaco-editor-extension'

// Set up a client.
const client = createClient({
  configuration: () =>
    Promise.resolve({
      enable: true,
      providers: {
        'https://openctx.org/npm/@openctx/provider-hello-world': true,
      },
    }),
  makeRange,
  logger: console.error,
})

// Now, get the editor object that refers to the Monaco editor you want to
// extend. Some code calls monaco.editor.create directly, and some code uses
// a wrapper around Monaco.
const editor: monaco.editor.IStandaloneCodeEditor = monaco.editor.create(/* ... */)

// Then create the extension and call it on the Monaco editor object.
const disposable = createExtension(client)(editor)

// Call disposable.dispose() when done to free resources.
```

## Demo

Clone this repository and run `pnpm run demo` from this directory, then visit http://localhost:5901. See the `demo/` dir for source code.

## Development

- [Source code](https://sourcegraph.com/github.com/sourcegraph/openctx/-/tree/client/monaco-editor)
- [Docs](https://openctx.org/docs/clients/monaco-editor)
- License: Apache 2.0
npm package: @openctx/provider-azure-devops-workitems
Description: Azure DevOps Work Items (OpenCtx provider)
Latest version: 0.0.9

# Azure DevOps Work Items context provider for OpenCtx

[OpenCtx](https://openctx.org) context provider for bringing Azure DevOps work items context into code AI and editors.

## Usage

1. [Create a personal access token](https://learn.microsoft.com/en-us/azure/devops/organizations/accounts/use-personal-access-tokens-to-authenticate?view=azure-devops&tabs=Windows)
2. Configure your OpenCtx client

### Azure DevOps Services

```json
"openctx.providers": {
    // ...other providers...
    "https://openctx.org/npm/@openctx/provider-azure-devops-workitems": {
        "url": "https://dev.azure.com/<account>", 
        "accessToken": "<your-azure-devops-token>",
    }
},
```

### Azure Devops Server (on-prem)

```json
"openctx.providers": {
    // ...other providers...
    "https://openctx.org/npm/@openctx/provider-azure-devops-workitems": {
        "url": "https://your-server-url/<collection_name>", 
        "accessToken": "<your-azure-devops-token>",
    }
},
```

**Note**: This will require a valid SSL certificate if your URL is using HTTPS.

## Mention support

- Searches issues based on title, description, or work item id.
- Displays the recent issues that are assigned to you, you've created, or you've changed

## Context included

Issues:

- URL
- Title
- Description
- Work Item Type
- State
- Assigned To
- Tags 

## Configuration

- `url` — Azure Devops URL — Required (e.g. `"https://dev.azure.com/some-account/"`)
- `accessToken` — access token — Required

## Development

- [Source code](https://sourcegraph.com/github.com/sourcegraph/openctx/-/tree/provider/azure-devops-workitems)
- [Docs](https://openctx.org/docs/providers/azure-devops-workitems)
- License: Apache 2.0
npm package: @openctx/provider-confluence
Description: Confluence (OpenCtx provider)
Latest version: 0.0.10

# Confluence context provider for OpenCtx

[OpenCtx](https://openctx.org) context provider for bringing Confluence context into code AI and editors.

## Usage

1. [Create an API token](https://id.atlassian.com/manage-profile/security/api-tokens)
2. Configure your OpenCtx client

```json
"openctx.providers": {
    // ...other providers...
    "https://openctx.org/npm/@openctx/provider-confluence": {
        "url": "https://some-org.atlassian.net/wiki",
        "email": "<email-address>",
        "apiToken": "<api-token>",
    }
},
```

## Mention support

- Searches page titles

## Context included

- Page body

## Configuration

- `url` — Confluence URL — Required (e.g. `"https://some-org.atlassian.net/wiki"`)
- `email` — Email — Required
- `apiToken` — API token — Required

## Development

- [Source code](https://sourcegraph.com/github.com/sourcegraph/openctx/-/tree/provider/confluence)
- [Docs](https://openctx.org/docs/providers/confluence)
- License: Apache 2.0

### Local Testing

1. Clone the repo
1. `pnpm install`
1. `pnpm -C provider/confluence bundle --watch` to automatically recompile on changes
1. Run `echo file://$(pwd)/provider/confluence/dist/bundle.js` and use that URL in your OpenCtx instead of `"https://openctx.org/npm/@openctx/provider-confluence"`
1. Reload your OpenCtx client
npm package: @openctx/provider-devdocs
Description: Use documentation from https://devdocs.io (OpenCtx provider)
Latest version: 0.0.13

# DevDocs page context provider for OpenCtx

This is a context provider for [OpenCtx](https://openctx.org) that fetches contents from https://devdocs.io/ pages by name for use as context.

## Usage

Add the following to your settings in any OpenCtx client:

```json
"openctx.providers": {
    // ...other providers...
    "https://openctx.org/npm/@openctx/provider-devdocs": true,
},
```

This will use the default documentation sets as used by https://devdocs.io/. To specify the documentation use a configuration like:

```json
"openctx.providers": {
    // ...other providers...
    "https://openctx.org/npm/@openctx/provider-devdocs": {
        "urls": ["https://devdocs.io/go/", "https://devdocs.io/angular~16/"]
    }
},
```

A URL is any top-level documentation URL on https://devdocs.io/.

## Development

- [Source code](https://sourcegraph.com/github.com/sourcegraph/openctx/-/tree/provider/devdocs)
- [Docs](https://openctx.org/docs/providers/devdocs)
- License: Apache 2.0
npm package: @openctx/provider-github
Description: GitHub OpenCtx provider
Latest version: 0.0.12

# GitHub provider for OpenCtx

This is a context provider for [OpenCtx](https://openctx.org) that fetches pull requests and issues contents from GitHub.

## Usage

Add the following to your settings in any OpenCtx client:

```json
"openctx.providers": {
    // ...other providers...
    "https://openctx.org/npm/@openctx/provider-github": {
        // create an access token from here: https://github.com/settings/tokens/new?scopes=repo
        "accessToken": "<your-access-token>",
    }
},
```

### Usage with other GitHub instances

By default, this provider talks to GitHub.com. Add the URL to your GitHub Enterprise Server or GitHub AE instance to the configuration to point this openctx provider at that:

```json
"openctx.providers": {
    // ...other providers...
    "https://openctx.org/npm/@openctx/provider-github": {
        // create an access token from here: https://github.com/settings/tokens/new?scopes=repo
        "accessToken": "<your-access-token>",
        "baseURL": "https://ghe.example.com"
    }
},
```

Then use the `@`-mention type **GitHub PRs & Issues** and search for issues or pull requests to include in context using the followining possible query examples:

- <https://github.com/facebook/react/issues/1234>
- <https://github.com/facebook/react/pull/1234>
- <https://ghe.example.com/facebook/react/pull/1234>
- github.com/facebook/react/issues/1234
- ghe.example.com/facebook/react/issues/1234
- facebook/react/issues/1234
- facebook/react:1234

## Development

- [Source code](https://sourcegraph.com/github.com/sourcegraph/openctx/-/tree/provider/github)
- [Docs](https://openctx.org/docs/providers/github)
- License: Apache 2.0
npm package: @openctx/provider-google-docs
Description: Google Docs context for code AI and editors (OpenCtx provider)
Latest version: 0.0.18

# Google Docs context provider for OpenCtx

This is a context provider for [OpenCtx](https://openctx.org) that brings Google Docs context to code AI and editors. Only items, not annotations, are supported.

**Status:** experimental

## Configuration for Sourcegraph teammates

1. Find "OpenCtx Google Docs provider config" in 1Password and follow instructions from there.

## Configuration outside of Sourcegraph

To create Google Drive/Docs API credentials:

1. Enable the following services in your Google Cloud project: `gcloud services enable drive.googleapis.com docs.googleapis.com`
1. [Configure the OAuth consent screen](https://console.cloud.google.com/apis/credentials/consent) (only a name and email addresses are required)
1. [Create a new OAuth client ID](https://console.cloud.google.com/apis/credentials/oauthclient) (select "Desktop app" as the application type)
1. Save the credentials JSON file (`client_secret_xxx.apps.googleusercontent.json`)
1. Obtain an access token for your Google Drive user account: run `GOOGLE_OAUTH_CLIENT_FILE=path/to/client_secret_xxx.apps.googleusercontent.json pnpm run google-auth` and continue in your web browser

Then use the following OpenCtx provider configuration:

```json
"openctx.providers": {
    // ...other providers...
    "https://openctx.org/npm/@openctx/provider-google-docs": {
        "googleOAuthClient": {
            "client_id": "XXX",
            "client_secret": "XXX",
            "redirect_uris": ["http://localhost"]
        },
        "googleOAuthCredentials": {
            "refresh_token": "XXX",
            "access_token": "XXX",
            "expiry_date": "XXX",
        }
    }
},
```

## Development

- [Source code](https://sourcegraph.com/github.com/sourcegraph/openctx/-/tree/provider/google-docs)
- [Docs](https://openctx.org/docs/providers/google-docs)
- License: Apache 2.0
npm package: @openctx/provider-hello-world
Description: Hello World (OpenCtx provider)
Latest version: 0.0.22

# Hello World context provider for OpenCtx

This is a sample context provider for [OpenCtx](https://openctx.org) that annotates every file with `✨ Hello, world!` every 10 lines or so.

## Usage

Add the following to your settings in any OpenCtx client:

```json
"openctx.providers": {
    // ...other providers...
    "https://openctx.org/npm/@openctx/provider-hello-world": true
},
```

## Configuration

This sample provider is not configurable.

## Development

- [Source code](https://sourcegraph.com/github.com/sourcegraph/openctx/-/tree/provider/hello-world)
- [Docs](https://openctx.org/docs/providers/hello-world)
- License: Apache 2.0
npm package: @openctx/provider-jira
Description: Jira (OpenCtx provider)
Latest version: 0.0.16

# Jira context provider for OpenCtx

[OpenCtx](https://openctx.org) context provider for bringing Jira context into code AI and editors.

## Usage

1. [Create an API token](https://id.atlassian.com/manage-profile/security/api-tokens)
2. Configure your OpenCtx client

```json
"openctx.providers": {
    // ...other providers...
    "https://openctx.org/npm/@openctx/provider-jira": {
        "url": "https://<subdomain>.atlassian.net/",
        "email": "<email-address>",
        "apiToken": "<your-atlassian-api-token>",
    }
},
```

## Mention support

- Searches issues based on title, summary, or issue key (PROJ-123).
- Displays the recent issues that are assigned to you, you've created, or you've commented on

## Context included

Issues:

- URL
- Summary
- Description
- Labels
- Subtasks (max 10)

## Configuration

- `url` — Jira URL — Required (e.g. `"https://some-org.atlassian.net/"`)
- `email` — Email — Required
- `apiToken` — API token — Required

## Development

- [Source code](https://sourcegraph.com/github.com/sourcegraph/openctx/-/tree/provider/jira)
- [Docs](https://openctx.org/docs/providers/jira)
- License: Apache 2.0
npm package: @openctx/provider-linear
Description: Linear context for code AI and editors (OpenCtx provider)
Latest version: 0.0.5

# Linear context provider for OpenCtx

This is a context provider for [OpenCtx](https://openctx.org) that brings Linear context to code AI and editors. Only items, not annotations, are supported.

**Status:** Experimental

## Configuration for Sourcegraph teammates

1. Find "OpenCtx Linear provider config" in 1Password and add it to your user settings.
1. Start using the provider!

```json
"openctx.providers": {
    // ...other providers...
    "https://openctx.org/npm/@openctx/provider-linear": {
        "accessToken": "YOUR_ACCESS_TOKEN",
    }
},
```

## Configuration outside of Sourcegraph

To create Linear API credentials:

1. [Create an OAuth2 application in Linear](https://linear.app/settings/api/applications/new).
1. Save the client configuration JSON file (`linear_client_config.json`).
1. Obtain an access token for your user account: run `LINEAR_OAUTH_CLIENT_FILE=path/to/linear_client_config.json pnpm auth` and continue in your web browser.
1. The access token will be saved in a JSON file with a path printed to the console.

Then use the following OpenCtx provider configuration:

```json
"openctx.providers": {
    // ...other providers...
    "https://openctx.org/npm/@openctx/provider-linear": {
        "userCredentialsPath": "path/to/access_token_file_printed.json",
    }
},
```

## Development

- [Source code](https://sourcegraph.com/github.com/sourcegraph/openctx/-/tree/provider/linear)
- [Docs](https://openctx.org/docs/providers/linear)
- License: Apache 2.0
npm package: @openctx/provider-linear-docs
Description: Linear Docs context for code AI and editors (OpenCtx provider)
Latest version: 0.0.8

# Linear Docs context provider for OpenCtx

This is a context provider for [OpenCtx](https://openctx.org) that brings Linear Docs context to code AI and editors. Only items, not annotations, are supported.

**Status:** Experimental

## Configuration for Sourcegraph teammates

1. Find "OpenCtx Linear Docs provider config" in 1Password and add it to your user settings.
1. Start using the provider!

```json
"openctx.providers": {
    // ...other providers...
    "https://openctx.org/npm/@openctx/provider-linear-docs": {
        "accessToken": "YOUR_ACCESS_TOKEN",
    }
},
```

## Configuration outside of Sourcegraph

To create Linear API credentials:

1. [Create an OAuth2 application in Linear](https://linear.app/settings/api/applications/new).
1. Save the client configuration JSON file (`linear_client_config.json`).
1. Obtain an access token for your user account: run `LINEAR_OAUTH_CLIENT_FILE=path/to/linear_client_config.json pnpm auth` and continue in your web browser.
1. The access token will be saved in a JSON file with a path printed to the console.

Then use the following OpenCtx provider configuration:

```json
"openctx.providers": {
    // ...other providers...
    "https://openctx.org/npm/@openctx/provider-linear-docs": {
        "userCredentialsPath": "path/to/access_token_file_printed.json",
    }
},
```

## Development

- [Source code](https://sourcegraph.com/github.com/sourcegraph/openctx/-/tree/provider/linear-docs)
- [Docs](https://openctx.org/docs/providers/linear-docs)
- License: Apache 2.0
npm package: @openctx/provider-linear-issues
Description: Linear Issues context for code AI and editors (OpenCtx provider)
Latest version: 0.0.13

# Linear Issues context provider for OpenCtx

This is a context provider for [OpenCtx](https://openctx.org) that brings Linear Issues context to code AI and editors. Only items, not annotations, are supported.

**Status:** Experimental

## Configuration for Sourcegraph teammates

1. Find "OpenCtx Linear Issues provider config" in 1Password and add it to your user settings.
1. Start using the provider!

```json
"openctx.providers": {
    // ...other providers...
    "https://openctx.org/npm/@openctx/provider-linear-issues": {
        "accessToken": "YOUR_ACCESS_TOKEN",
    }
},
```

## Configuration outside of Sourcegraph

To create Linear API credentials:

1. [Create an OAuth2 application in Linear](https://linear.app/settings/api/applications/new).
1. Save the client configuration JSON file (`linear_client_config.json`).
1. Obtain an access token for your user account: run `LINEAR_OAUTH_CLIENT_FILE=path/to/linear_client_config.json pnpm auth` and continue in your web browser.
1. The access token will be saved in a JSON file with a path printed to the console.

Then use the following OpenCtx provider configuration:

```json
"openctx.providers": {
    // ...other providers...
    "https://openctx.org/npm/@openctx/provider-linear-issues": {
        "userCredentialsPath": "path/to/access_token_file_printed.json",
    }
},
```

## Development

- [Source code](https://sourcegraph.com/github.com/sourcegraph/openctx/-/tree/provider/linear-issues)
- [Docs](https://openctx.org/docs/providers/linear-issues)
- License: Apache 2.0
npm package: @openctx/provider-mcp
Description: Use information from MCP providers
Latest version: 0.0.13

# MCP proxy for OpenCtx

This is a context provider for [OpenCtx](https://openctx.org) that fetches contents from a [MCP](https://github.com/modelcontextprotocol/specification) provider for use as context.

Currently, only MCP over stdio is supported (HTTP is not yet supported).

## Development

1. Clone the [modelcontextprotocol/servers](https://github.com/modelcontextprotocol/servers) repository. Follow the instructions there to build the example providers. This should generate output files of the form `build/${example_name}/index.js`.
1. Run `pnpm watch` in this directory.
1. Add the following to your VS Code settings:
    ```json
    "openctx.providers": {
        // ...other providers...
        "https://openctx.org/npm/@openctx/modelcontextprotocol": {
            "nodeCommand": "node",
            "mcp.provider.uri": "file:///path/to/servers/root/build/everything/index.js",
        }
    }
    ```
1. Reload the VS Code window. You should see `servers/everything` in the `@`-mention dropdown.

To hook up to the Postgres MCP provider, use:

```json
"openctx.providers": {
    // ...other providers...
    "https://openctx.org/npm/@openctx/modelcontextprotocol": {
        "nodeCommand": "node",
        "mcp.provider.uri": "file:///path/to/servers/root/build/postgres/index.js",
        "mcp.provider.args": [
            "postgresql://sourcegraph:sourcegraph@localhost:5432/sourcegraph"
        ]
    }
}
```

## More MCP Servers

The following MCP servers are available in the [modelcontextprotocol/servers](https://github.com/modelcontextprotocol/servers) repository:

- [Postgres](https://github.com/modelcontextprotocol/servers/tree/main/src/postgres) - Connect to your Postgres databases to query schema information and write optimized SQL
- [Everything](https://github.com/modelcontextprotocol/servers/tree/main/src/everything) - A demo server showing MCP capabilities
- [Google Drive](https://github.com/modelcontextprotocol/servers/tree/main/src/gdrive) - Search and access your Google Drive documents
- [Giphy](https://github.com/modelcontextprotocol/servers/tree/main/src/giphy) - Search gifs
- [Git](https://github.com/modelcontextprotocol/servers/tree/main/src/git) - Get git history and commit information
- [HubSpot](https://github.com/modelcontextprotocol/servers/tree/main/src/hubspot) - Access your HubSpot CRM data
- [OSAScript](https://github.com/modelcontextprotocol/servers/tree/main/src/osascript) - Execute AppleScript commands on macOS
- [Puppeteer](https://github.com/modelcontextprotocol/servers/tree/main/src/puppeteer) - Control headless Chrome for web automation
- [Spotify](https://github.com/modelcontextprotocol/servers/tree/main/src/spotify) - Access Spotify music data and playlists

## Creating your own MCP server

See the [MCP docs](https://modelcontextprotocol.io) for how to create your own MCP servers.
npm package: @openctx/provider-modelcontextprotocol
Description: Use information from MCP providers
Latest version: 0.0.14

# MCP proxy for OpenCtx

This is a context provider for [OpenCtx](https://openctx.org) that fetches contents from a [MCP](https://modelcontextprotocol.io) provider for use as context.

Currently, only MCP over stdio is supported (HTTP is not yet supported).

## Development

1. Clone the [modelcontextprotocol/servers](https://github.com/modelcontextprotocol/servers) repository. Follow the instructions there to build the example providers. This should generate output files of the form `build/${example_name}/index.js`.
1. Run `pnpm watch` in this directory.
1. Add the following to your VS Code settings:
    ```json
    "openctx.providers": {
        // ...other providers...
        "https://openctx.org/npm/@openctx/provider-modelcontextprotocol": {
            "nodeCommand": "node",
            "mcp.provider.uri": "file:///path/to/servers/root/build/everything/index.js",
        }
    }
    ```
1. Reload the VS Code window. You should see `servers/everything` in the `@`-mention dropdown.

To hook up to the Postgres MCP provider, use:

```json
"openctx.providers": {
    // ...other providers...
    "https://openctx.org/npm/@openctx/provider-modelcontextprotocol": {
        "nodeCommand": "node",
        "mcp.provider.uri": "file:///path/to/servers/root/build/postgres/index.js",
        "mcp.provider.args": [
            "postgresql://sourcegraph:sourcegraph@localhost:5432/sourcegraph"
        ]
    }
}
```

## More MCP Servers

The following MCP servers are available in the [modelcontextprotocol/servers](https://github.com/modelcontextprotocol/servers) repository:

- [Brave Search](https://github.com/modelcontextprotocol/servers/tree/main/src/brave-search) - Search the Brave search API
- [Postgres](https://github.com/modelcontextprotocol/servers/tree/main/src/postgres) - Connect to your Postgres databases to query schema information and write optimized SQL
- [Filesystem](https://github.com/modelcontextprotocol/servers/tree/main/src/filesystem) - Access files on your local machine
- [Everything](https://github.com/modelcontextprotocol/servers/tree/main/src/everything) - A demo server showing MCP capabilities
- [Google Drive](https://github.com/modelcontextprotocol/servers/tree/main/src/gdrive) - Search and access your Google Drive documents
- [Google Maps](https://github.com/modelcontextprotocol/servers/tree/main/src/google-maps) - Get directions and information about places
- [Memo](https://github.com/modelcontextprotocol/servers/tree/main/src/memo) - Access your Memo notes
- [Git](https://github.com/modelcontextprotocol/servers/tree/main/src/git) - Get git history and commit information
- [Puppeteer](https://github.com/modelcontextprotocol/servers/tree/main/src/puppeteer) - Control headless Chrome for web automation
- [SQLite](https://github.com/modelcontextprotocol/servers/tree/main/src/sqlite) - Query SQLite databases

## Creating your own MCP server

See the [MCP docs](https://modelcontextprotocol.io) for how to create your own MCP servers.
npm package: @openctx/provider-modelcontextprotocoltools
Description: Use information from MCP providers
Latest version: 0.0.14

# MCP Tools Provider for OpenCtx (Work in Progress)

This is a context provider for [OpenCtx](https://openctx.org) that enables access to tools exposed by [MCP](https://modelcontextprotocol.io) providers. This provider specifically handles tool interactions - it does not support MCP resources.

Currently, only MCP over stdio is supported (HTTP is not yet supported).

## What This Provider Does
- Connects to MCP providers to expose their available tools
- Validates tool inputs against their schemas
- Executes tool calls and returns results
- Supports tool discovery and filtering via mentions

## Creating MCP Tools

To create tools that can be used with this provider, see the [MCP documentation](https://modelcontextprotocol.io) on implementing tool endpoints in your MCP server.

> Note: This provider documentation is under active development. Additional documentation and features examples will be added once design decisions are finalized.
npm package: @openctx/provider-notion
Description: Notion (OpenCtx provider)
Latest version: 0.0.9

# Notion context provider for OpenCtx

This is a context provider for [OpenCtx](https://openctx.org) that provides Notion results as context via the mentions and items APIs.

## Usage

Add the following to your settings in any OpenCtx client:

```json
"openctx.providers": {
    // ...other providers...
    "https://openctx.org/npm/@openctx/provider-notion": {
        "auth": "<your notion bot access token>"
    }
},
```

See https://developers.notion.com/docs/getting-started to get set up with a
token for the Notion API.

Remember to add your integration to a page such that it can search that page and
all sub pages.

## Configuration

This provider configuration is a subset of the configuration for the NotionHQ JavaScript client:

- `auth` :: Bearer token for authentication. Required.
- `logLevel` :: Verbosity of logs the client will produce. Levels are `"debug"`, `"info"`, `"warn"` (default) and `"error"`.
- `timeoutMs` :: The number of milliseconds to wait before timing out an API call to Notion. Defaults to `60000`.

## Development

- [Source code](https://sourcegraph.com/github.com/sourcegraph/openctx/-/tree/provider/notion)
- [Docs](https://openctx.org/docs/providers/notion)
- License: Apache 2.0
npm package: @openctx/provider-semgrep
Description: Semgrep OpenCtx provider
Latest version: 0.0.10

# Semgrep context provider for OpenCtx

This is a sample context provider for [OpenCtx](https://openctx.org) that fetches the contents of a Semgrep finding from a given URL.

## Usage

Add the following to your settings in any OpenCtx client:

```json
"openctx.providers": {
    // ...other providers...
    "https://openctx.org/npm/@openctx/provider-semgrep": {
        "token": "Your <SEMGREP_APP_TOKEN>",
        "repo": "Semgrep repository or project filter"
    }
},
```

You can create and download a `SEMGREP_APP_TOKEN` from <https://semgrep.dev/orgs/-/settings/tokens> under the "API tokens" tab menu option.

The `repo` setting, if provided, filters all the findings in your organization using the provided value.

## Development

- [Source code](https://sourcegraph.com/github.com/sourcegraph/openctx/-/tree/provider/semgrep)
- [Docs](https://openctx.org/docs/providers/semgrep)
- License: Apache 2.0
npm package: @openctx/provider-sentry
Description: Use information from Sentry.io issues (OpenCtx provider)
Latest version: 0.0.10

# Sentry issue context provider for OpenCtx

This is a context provider for [OpenCtx](https://openctx.org) that fetches contents from a Sentry issue by just pasting the URL to it.

## Usage

Add the following to your settings in any OpenCtx client:

```json
"openctx.providers": {
    // ...other providers...
    "https://openctx.org/npm/@openctx/provider-sentry": {
        "apiToken": "SENTRYTOKENHERE"
    }
},
```

Then use the `@`-mention type **Sentry Issues** and enter a URL, such as `https://sourcegraph.sentry.io/issues/1234567890/?project=1234567&query=is%3Aunresolved+issue.priority%3A%5Bhigh%2C+medium%5D&referrer=issue-stream&statsPeriod=14d&stream_index=17`, to include the context in the Sentry issue.

## Setup

For this provider to work, you need to provide an API token for your Sentry account.

To obtain one:

1. Go to Sentry
2. Click on your organization in the top left corner
3. In the dropdown, select "User auth tokens"
4. Create a new auth token on that page. For scopes, select `event:read, project:read`

Then, add the token to your OpenCtx settings:

```json
"openctx.providers": {
    // ...other providers...
    "https://openctx.org/npm/@openctx/provider-sentry": {
        "apiToken": "SENTRYTOKENHERE",
        // or:
        "apiTokenPath": "path/to/file/withsentrytoken"
    }
},
```

## Development

- [Source code](https://sourcegraph.com/github.com/sourcegraph/openctx/-/tree/provider/sentry)
- [Docs](https://openctx.org/docs/providers/sentry)
- License: Apache 2.0
npm package: @openctx/provider-slack
Description: Slack context for code AI and editors (OpenCtx provider)
Latest version: 0.0.12

# Slack context provider for OpenCtx

This is a context provider for [OpenCtx](https://openctx.org) that brings Slack context to code AI and editors. Slack context provider allows to search for relevant threads when mentioning a slack channel and use all the messages in the thread as the context to AI.

**Status:** Experimental

## Configuration

To create Slack User Auth token:

1. [Create a slack app for you workspace from scratch using slack api - Click on "Create New App" button.](https://api.slack.com/apps).
2. Go to the "OAuth & Permissions" tab and add the following permission in the User Token Scopes.
 - `channels:history`
 - `channels:read`
 - `search:read`
 - `users:read`
3. Click on "Install to workspace".
4. Copy the "User OAuth Token" and use it as the `slackAuthToken` in the OpenCtx provider configuration.
5. Use the following OpenCtx provider configuration:


```json
"openctx.providers": {
    // ...other providers...
    "https://openctx.org/npm/@openctx/provider-slack": {
      "slackAuthToken": "<USER OAuth Token>"
    }
},
```

## Development

- [Source code](https://sourcegraph.com/github.com/sourcegraph/openctx/-/tree/provider/linear)
- [Docs](https://openctx.org/docs/providers/linear)
- License: Apache 2.0
npm package: @openctx/provider-sourcegraph-search
Description: Sourcegraph Search (OpenCtx provider)
Latest version: 0.0.14

# Sourcegraph Search context provider for OpenCtx

This is a context provider for [OpenCtx](https://openctx.org) that provides Sourcegraph search results as context via the mention and items APIs.

## Usage

Add the following to your settings in any OpenCtx client:

```json
"openctx.providers": {
    // ...other providers...
    "https://openctx.org/npm/@openctx/provider-sourcegraph-search": true
},
```

## Configuration

This sample provider is not configurable.

## Development

- [Source code](https://sourcegraph.com/github.com/sourcegraph/openctx/-/tree/provider/sourcegraph-search)
- [Docs](https://openctx.org/docs/providers/sourcegraph-search)
- License: Apache 2.0
npm package: @openctx/provider-storybook
Description: Add Storybook links and image previews to your code (OpenCtx provider)
Latest version: 0.0.20

# Storybook context provider for OpenCtx

This is a context provider for [OpenCtx](https://openctx.org) that annotates your React components and `*.story.ts?(x)` files with screenshots and links to your [Storybook](https://storybook.js.org/) component library. It works well with storybooks hosted on [Chromatic](https://chromatic.com/).

## Screenshot

![Screenshot of OpenCtx annotations for Storybook in a code file](https://storage.googleapis.com/sourcegraph-assets/blog/screencast-vscode-storybook-v0.gif)

_Hover over a UI component in code to see what it looks like_

Visit the [OpenCtx playground](https://openctx.org/playground) for live examples.

## Usage

Add the following to your settings in any OpenCtx client:

```json
"openctx.providers": {
    // ...other providers...
    "https://openctx.org/npm/@openctx/provider-storybook": {
        "storybookUrl": "<URL to the Storybook for your application>"
    }
},
```

Tips:

- If you're using VS Code, you can put the snippet above in `.vscode/settings.json` in each repository if you have different storybooks per-repository.
- To use this with storybooks hosted on [Chromatic](https://chromatic.com/), see below in the "[Configuration](#configuration)" section.
- Play around with the Storybook provider in realtime on the [OpenCtx playground](https://openctx.org/playground).

## Configuration

<!-- Keep in sync with index.ts -->

```typescript
/** Settings for the Storybook OpenCtx provider. */
interface Settings {
  /**
   * The URL to a published Storybook for your project.
   *
   * If you're using Chromatic, this is of the form `https://<branch>--<appid>.chromatic.com`; see
   * https://www.chromatic.com/docs/permalinks/#get-permalinks-to-your-project for how to obtain
   * this value.
   *
   * If the URL contains `<branch>`, it will always be replaced with `main`.
   *
   * TODO(sqs): Support non-main branches.
   */
  storybookUrl: string
}
```

## Development

- [Source code](https://sourcegraph.com/github.com/sourcegraph/openctx/-/tree/provider/storybook)
- [Docs](https://openctx.org/docs/providers/storybook)
- License: Apache 2.0
npm package: @openctx/provider-url-fetcher
Description: URL Fetcher (OpenCtx provider)
Latest version: 0.0.3

# URL Fetcher context provider for OpenCtx


This is a context provider for [OpenCtx](https://openctx.org) that fetches URLs for use as context items.

## Usage

Add the following to your settings in any OpenCtx client:

```json
"openctx.providers": {
    // ...other providers...
    "https://openctx.org/npm/@openctx/url-fetcher": true
},

## Development

- [Source code](https://sourcegraph.com/github.com/sourcegraph/openctx/-/tree/provider/url-fetcher)
- [Docs](https://openctx.org/docs/providers/url-fetcher)
- License: Apache 2.0
npm package: @openctx/provider-web
Description: Use information from web pages (OpenCtx provider)
Latest version: 0.0.14

# Web page context provider for OpenCtx

This is a context provider for [OpenCtx](https://openctx.org) that fetches contents from web pages by URL for use as context.

## Usage

Add the following to your settings in any OpenCtx client:

```json
"openctx.providers": {
    // ...other providers...
    "https://openctx.org/npm/@openctx/provider-web": true
},
```

Then use the `@`-mention type **Web URLs** and enter a URL, such as `https://example.com`, to include the web page's contents as context.

## Development

- [Source code](https://sourcegraph.com/github.com/sourcegraph/openctx/-/tree/provider/web)
- [Docs](https://openctx.org/docs/providers/web)
- License: Apache 2.0
npm package: @openctx/vscode-lib
Description: OpenCtx library for VS Code extensions
Latest version: 0.0.29

# OpenCtx library for VS Code extensions

The [`@openctx/vscode-lib`](https://www.npmjs.com/package/@openctx/vscode-lib) npm package is a library that lets VS Code extensions use OpenCtx functionality. The [OpenCtx VS Code extension](https://openctx.org/docs/clients/vscode) uses this library.

## Usage

_Status: experimental, for use by VS Code extension authors only (not end users)_

1. Add `@openctx/vscode-lib` as a dependency to your VS Code extension.
1. In your extension's `activate` function, call `createController({...})`.
1. Add the relevant `contributions` to your extension's `package.json`.

See the [OpenCtx VS Code extension source code](https://sourcegraph.com/github.com/sourcegraph/openctx/-/tree/client/vscode-lib) for an example.

### Developing this library and your VS Code extension

If you want your VS Code extension to automatically incorporate your latest local changes to this package, you can use `pnpm link`.

In your VS Code extension's package directory, run the following (where `$OPENCTX` is the path to the `openctx` repository root):

```shell
cd path/to/your/vscode/extension
pnpm link $OPENCTX/lib/client
pnpm link $OPENCTX/lib/schema
pnpm link $OPENCTX/lib/protocol
pnpm link $OPENCTX/client/vscode-lib
```

## Known issues

- Only 1 activated extension can use this library at a time. If a second extension using this library tries to activate, it will encounter name collisions in the commands it registers.
- Providers that are implemented as JavaScript programs must be bundled to CommonJS to be used with VS Code. (ESM-bundled JavaScript providers only work with the VS Code debug extension host.)

## Development

- [Source code](https://sourcegraph.com/github.com/sourcegraph/openctx/-/tree/client/vscode-lib)
- [Docs](https://openctx.org/docs/clients/vscode)
- License: Apache 2.0