Skip to content

[FEATURE]: Option to deny MCP tools by default #3612

Closed

Description

@sroidl-airup

Feature hasn't been suggested before.

  • I have verified this feature I'm about to request hasn't been suggested before.

Describe the enhancement you want to request

(hope this wasnt suggested before, but did not find anything)

Context: I'd like to use certain MCP servers only with specific agents. E.g. I'm using the jetbrains mcp, but I don't want all agents to use it's file editing capabilities, since it does not work well with the undo feature.

However, I have created a Jetbrains agent for the purpose of collaborating closely on what I do in my current jetbrains IDE (think implement the open TODO() in my current editor).

Problem:
There seems to be no easy way to deny access to all MCP tools of a defined server globally and override this in only one agent.

I've tried setting "permissions" : { "jetbrains_*" : "deny"} in my global openapi.json to no success.
Also the "tools": { "jetbrains_*": false} was not supported globally.

So currently I'm stuck with disallowing the tools for each agent. This is cumbersome and errorprone, since we don't know which agents are going to be active depending on the project I'm working on.

Request:
Make either "tools" a global configuration, so I can disallow tool usage across all agents (with the expectation, that agent specific entries override this global config), or allow MCP tools to be referenced in the "permissions" (global) config.

Activity

  1. added
    discussionUsed for feature requests, proposals, ideas, etc. Open discussion
    on Oct 31, 2025
  2. rekram1-node commented on Oct 31, 2025

    @rekram1-node
    Collaborator

    @sroidl-airup the permissions wildcard support isn't there yet but the tools one should work globally, can u share your config?

    Maybe do opencode debug config

  3. github-actions commented on Oct 31, 2025

    @github-actions
    Contributor

    This issue might be a duplicate of existing issues. Please check:

    The #2888 issue appears to be the most directly related to your request, as it proposed a 'defaultTools' configuration that would allow setting a baseline of available tools globally with per-agent overrides.

    Feel free to ignore if none of these address your specific case.

  4. self-assigned this
    on Oct 31, 2025
  5. sroidl-airup commented on Nov 3, 2025

    @sroidl-airup
    Author

    My bad - I had a typo in the config. sorry to bother you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

discussionUsed for feature requests, proposals, ideas, etc. Open discussion

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions