fix(hwid): paginate get_hwid_users via query params, not GET body#59
Open
masasibata wants to merge 1 commit into
Open
fix(hwid): paginate get_hwid_users via query params, not GET body#59masasibata wants to merge 1 commit into
masasibata wants to merge 1 commit into
Conversation
size/start were annotated with AttributeBody, so the SDK serialized them into the GET request body. The API reads pagination from query params, so they were ignored and every call to GET /api/hwid/devices returned a single default page — bulk HWID device enumeration only ever saw the first page. Switch size/start to Query, matching get_top_users_by_hwid_devices on the adjacent /hwid/devices/top-users endpoint. Drop the now-unused AttributeBody import.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The
get_hwid_userscontroller (GET /api/hwid/devices) annotatessize/startwithAttributeBody, so the SDK serializes them into the GET request body. The API reads pagination from query params, sosize/startare ignored and every call returns a single default page.Effect on consumers: bulk HWID device enumeration only ever sees the first page (e.g. ~25 users / <1000 devices for accounts with 60k+ real devices). Any code that assumes a complete snapshot silently gets partial data.
Fix
Switch
size/starttoQuery(default=None, ...), matchingget_top_users_by_hwid_deviceson the adjacent/hwid/devices/top-usersendpoint. Drop the now-unusedAttributeBodyimport.Verification
get_top_users_by_hwid_devicesalready uses the sameQuerypattern and paginates correctly.GET /api/hwid/deviceswith querysize/start.