Add chat.spaces.readonly scope for listing spaces
The list_spaces tool was using chat.messages.readonly which is overly broad for simply enumerating available spaces. This adds the chat.spaces.readonly scope and uses it for list_spaces, following the principle of least privilege. Closes #479 Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -19,7 +19,7 @@ logger = logging.getLogger(__name__)
|
||||
|
||||
|
||||
@server.tool()
|
||||
@require_google_service("chat", "chat_read")
|
||||
@require_google_service("chat", "chat_spaces_readonly")
|
||||
@handle_http_errors("list_spaces", service_type="chat")
|
||||
async def list_spaces(
|
||||
service,
|
||||
|
||||
Reference in New Issue
Block a user