Repository navigation
0.6.0: white-label platform users and trading competitions - #3
Merged
Merged
Conversation
A platform keeps its own login, imports its users by its own user id (external_id) with their existing wallets, and uses their trades, PnL, leaderboards and trading competitions through the Data API. - Every /v1/platform-users/* endpoint on CabalSpyID and AsyncCabalSpyID (create/upsert, import, get, update, list, delete, wallets, wallet verification incl. the SVG QR code, profile, leaderboard, settings, inbound URL, session, claim link, X, Telegram, KOL), with iterators for the list and the leaderboard. - bulk_import_platform_users: chunks of at most 1,000 users and under the 1 MB body limit, aggregated results in input order; retries 429 (Retry-After wins), re-sends only users rejected with rate_limited, never re-sends a chunk that succeeded; PlatformImportError carries result and remaining to resume. - Trading competitions (/v1/competitions*) with offset iterators. - ConflictError for 409; new error codes, webhook events, TypedDicts and constants. - Tests, README section, examples/white_label.py, CHANGELOG, 0.6.0. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
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.
Adds every
/v1/platform-users/*and/v1/competitions*endpoint to the sync and async clients.bulk_import_platform_users: any number of users, chunks of ≤1,000 and <1 MB, retries 429 (Retry-After), re-sends only items rejected withrate_limited, never re-sends a successful chunk;PlatformImportErrorcarriesresultandremaining.ConflictErrorfor 409 (subclass ofCabalSpyIDError, so existing code keeps working).examples/white_label.py, CHANGELOG.Tests: 157 passed; ruff and mypy (strict) clean.
🤖 Generated with Claude Code