- Notifications
You must be signed in to change notification settings - Fork907
docs: clarify details around MCP#17220
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
Uh oh!
There was an error while loading.Please reload this page.
Changes fromall commits
File filter
Filter by extension
Conversations
Uh oh!
There was an error while loading.Please reload this page.
Jump to
Uh oh!
There was an error while loading.Please reload this page.
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
# Custom Agents | ||
> [!NOTE] | ||
> | ||
> This functionality is in early access and subject to change. Do not run in | ||
> production as it is unstable. Instead, deploy these changes into a demo or | ||
> staging environment. | ||
> | ||
> Join our [Discord channel](https://discord.gg/coder) or | ||
> [contact us](https://coder.com/contact) to get help or share feedback. | ||
Custom agents beyond the ones listed in the [Coder registry](https://registry.coder.com/modules?tag=agent) can be used with Coder. | ||
## Prerequisites | ||
- A Coder deployment with v2.21 or later | ||
- A [Coder workspace / template](./create-template.md) | ||
- A custom agent that supports Model Context Protocol (MCP) | ||
## Getting Started | ||
Coder uses the [MCP protocol](https://modelcontextprotocol.io/introduction) to report activity back to the Coder control plane. From there, activity is displayed in the Coder dashboard. | ||
First, your template will need a [coder_app](https://registry.terraform.io/providers/coder/coder/latest/docs/resources/app) for the agent. This can be a web app or command run in the terminal and ideally gives the user a UI to interact with or view more details about the agent. | ||
From there, the agent can run the MCP server with the `coder exp mcp server` command. You will need to set the `CODER_MCP_APP_STATUS_SLUG` environment variable to match the slug in the coder_app resource. | ||
## Example | ||
Inside a Coder workspace, run the following commands: | ||
```sh | ||
coder login # be sure to be authenticated with the Coder CLI | ||
export CODER_MCP_APP_STATUS_SLUG=my-agent # needs to be the same as the slug in the coder_app resource | ||
# Use your own agent's logic and syntax here: | ||
any-custom-agent configure-mcp --name "coder" --command "coder exp mcp server" | ||
``` | ||
This will start the MCP server and report activity back to the Coder control plane on behalf of the coder_app resource. | ||
Comment on lines +26 to +40 There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others.Learn more. If we're mentioning the app status slug, we should also add a note about also needing to specify There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others.Learn more. Oops! Will clarify | ||
> See the [Goose module](https://github.com/coder/modules/blob/main/goose/main.tf) source code for a real world example. | ||
## Contributing | ||
We welcome contributions for various agents via the [Coder registry](https://registry.coder.com/modules?tag=agent)! | ||
See our [contributing guide](https://github.com/coder/modules/blob/main/CONTRIBUTING.md) for more information. |
Uh oh!
There was an error while loading.Please reload this page.