Skip to content

Conversation

@atif09
Copy link

@atif09 atif09 commented Jan 17, 2026

Summary

This PR adds pagination support to the /rest/v1/tags endpoint to handle large result sets efficiently.

Details

  • Added get_by_tags_with_pagination() method to database layer
  • Updated /rest/v1/tags endpoint to accept page and items_per_page query parameters
  • Returns total_pages and page in JSON response
  • Maintains backward compatibility (works without pagination parameters)
  • Added comprehensive tests for pagination logic

Why this change

The /rest/v1/tags endpoint had a TODO comment indicating pagination was needed. Without pagination, queries with many tags could return large result sets, causing performance issues and poor UX. This change enables efficient data retrieval with client-controlled page sizes.

Scope

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

make pagination also for tag results

1 participant