Skip to content

get_advisors tool returns responses exceeding token limits without pagination support #124

Open

Description

@Thelastpoet

Bug report

Describe the bug

Using Claude Code, the get_advisors MCP tool consistently returns responses that exceed the maximum allowed token limit (25,000 tokens), making it impossible to retrieve
advisor information programmatically. The tool fails with "MCP tool 'get_advisors' response (28254 tokens) exceeds maximum allowed tokens (25000)" error.

To Reproduce

Steps to reproduce the behavior:

  1. Use the Supabase MCP with a project containing multiple tables/database objects
  2. Call the get_advisors tool with any project ID:
mcp__supabase__get_advisors({
  project_id: "your-project-id",
  type: "security"
})
3. Tool returns error due to response size exceeding token limits
4. Same issue occurs with type: "performance"

Expected behavior

The tool should successfully return advisor information, either by:
- Supporting pagination parameters to limit response size
- Implementing automatic chunking/filtering
- Providing a summary view with drill-down options
- Including response size limits in documentation

Screenshots

N/A - This is an MCP tool API issue

System information

- OS: Linux (WSL2)
- MCP Client: Claude Code CLI
- Supabase MCP version: [current version]
- Node.js: [applicable version]
- Project: Standard Supabase project with normal table count

Additional context

This makes the get_advisors tool unusable for any project with a reasonable amount of data, as most real-world projects will have enough advisors
(particularly missing RLS policies) to exceed the token limit. The tool would benefit from pagination support (limit/offset parameters) or severity-based
filtering to make it practical for automated security monitoring.

Activity

  1. added
    bug
    on Aug 11, 2025
  2. Brian-1812 commented on Nov 11, 2026

    @Brian-1812
    Contributor

    This still happens on main. #390 groups repeated lints, but a project with many different findings can still go over the client's limit, because get_advisors has no way to filter or cap what it returns.

    Would something like this work?

    • an optional level input (ERROR, WARN or INFO) to get only that level
    • an optional limit input, with the response saying how many findings were left out

    Without them the tool works the same as today. If that sounds fine, I'll send a PR with tests.

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    bug

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions