Set Oauth Client Mcp Exposure
Replace one credential's MCP-exposure allow-list for one (resource, action) pair - controls which tools list_mcp_tools can ever surface for this credential, independent of and layered on top of the scope grant and the instance-grant allow-list from set_oauth_client_resource_grants.
Same org-scoping and 404 opacity as the sibling resource-grants and revoke routes: a credential belonging to a different organisation is a 404, not a 403.
A populated resource_ids list is rejected with a 422: list_mcp_tools does not yet intersect exposure rows against resource_id, so silently accepting an instance-scoped write here would mislead the caller into believing they had scoped a credential's tool access to specific resources when the write actually has no effect on what the credential can see. Only null (unrestricted) and [] (deny-all) are currently meaningful.
Authorization
OAuth2AuthorizationCodeBearer In: header
Path Parameters
uuiduuidQuery Parameters
trueRequest Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Replace one credential's MCP-exposure allow-list for one (resource, action) pair - the tool-catalog-visibility counterpart to SetResourceGrantsIn's instance-grant allow-list.
resource_ids carries the same three-way semantics as
SetResourceGrantsIn: null writes the unrestricted-within-org
sentinel row, [] is the explicit deny-all state, and a populated
list allow-lists exactly those instance ids.
Response Body
application/json
curl -X PUT "https://example.com/v1/organisations/497f6eca-6276-4993-bfeb-53cbbbba6f08/oauth-clients/497f6eca-6276-4993-bfeb-53cbbbba6f08/mcp-exposure" \ -H "Content-Type: application/json" \ -d '{ "resource": "string", "action": "string", "resource_ids": [ "f3aaf7b6-b51a-43c8-8627-9e1a7630b22a" ] }'{ "detail": [ { "loc": [ "string" ], "msg": "string", "type": "string" } ]}