refactor(usage): consolidate shared poll logic; migrate freeTrial API… - #148
Merged
Conversation
…s to bailian-commerce Dedup: - shared.ts: extract generic pollConsoleUntilDone (request-builder callback absorbs each wrapper convention); pollTelemetryApi becomes a thin wrapper; add pollFreeTierBatch - freetier.ts / stats.ts: drop inline duplicates of extractResponseData, polling, model-list paging, free-tier extractors and usage label maps; import from shared.ts (behaviour unchanged: freetier keeps its 20-poll budget, telemetry keeps 30) Endpoint migration (broadscope-bailian.freeTrial -> bailian-commerce.freeTrial): - queryFreeTierQuota, queryFreeTierOnlyStatus, batchActivateFreeTierOnly, batchDeactivateFreeTierOnly - update the console call example and the gateway doc comment to match Note: verified statically and via dry-run; live calls pending a fresh console login (session expired).
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.
…s to bailian-commerce
Dedup:
Endpoint migration (broadscope-bailian.freeTrial -> bailian-commerce.freeTrial):
Note: verified statically and via dry-run; live calls pending a fresh console login (session expired).