-
Notifications
You must be signed in to change notification settings - Fork 90
add pagination to tags and text_search endpoints #760
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
|
@@ -65,6 +65,20 @@ paths: | |||||||||||||||||||||||||||||
| schema: | ||||||||||||||||||||||||||||||
| type: string | ||||||||||||||||||||||||||||||
| enum: [json, md, csv, oscal] | ||||||||||||||||||||||||||||||
| - name: page | ||||||||||||||||||||||||||||||
| in: query | ||||||||||||||||||||||||||||||
| required: false | ||||||||||||||||||||||||||||||
| description: 1-based page number for paginated results. | ||||||||||||||||||||||||||||||
| schema: | ||||||||||||||||||||||||||||||
| type: integer | ||||||||||||||||||||||||||||||
| minimum: 1 | ||||||||||||||||||||||||||||||
| - name: items_per_page | ||||||||||||||||||||||||||||||
| in: query | ||||||||||||||||||||||||||||||
| required: false | ||||||||||||||||||||||||||||||
| description: Number of items per page. | ||||||||||||||||||||||||||||||
| schema: | ||||||||||||||||||||||||||||||
| type: integer | ||||||||||||||||||||||||||||||
| minimum: 1 | ||||||||||||||||||||||||||||||
|
Comment on lines
+68
to
+81
|
||||||||||||||||||||||||||||||
| - name: page | |
| in: query | |
| required: false | |
| description: 1-based page number for paginated results. | |
| schema: | |
| type: integer | |
| minimum: 1 | |
| - name: items_per_page | |
| in: query | |
| required: false | |
| description: Number of items per page. | |
| schema: | |
| type: integer | |
| minimum: 1 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The text_search endpoint is missing pagination metadata (page and total_pages) in its JSON response. The tags endpoint returns {"data": [...], "page": X, "total_pages": Y}, but text_search only returns the raw array. This creates an inconsistency between the two endpoints that were both updated to support pagination in this PR. The JSON response should include page and total_pages fields for consistency.