Skip to content

API: Implement pagination limits on list_repos endpoint #24

Description

@eshaanag

What is missing / Why it matters

The GET /api/repos endpoint fetches and returns all ingested repositories in the database without any limits or pagination. If the app grows and ingests hundreds of repositories, querying and returning the full list of repositories degrades API performance and inflates payload sizes.

Acceptance Criteria

  • Add limit: int = 20 and offset: int = 0 query parameters to the list_repos route in backend/features/repo_ingestion/router.py.
  • Enforce a maximum limit cap (e.g. 100) to prevent abuse.
  • Verify parameters with unit tests to ensure offset and limit are applied correctly.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or requestintermediateIntermediate complexity issue

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions