chore: remove legacy createX402Client in favor of SDK paymentHandler#11
Merged
acedatacloud-dev merged 1 commit intomainfrom Apr 19, 2026
Merged
chore: remove legacy createX402Client in favor of SDK paymentHandler#11acedatacloud-dev merged 1 commit intomainfrom
acedatacloud-dev merged 1 commit intomainfrom
Conversation
Follow-up to #10. With createX402PaymentHandler now wired into the @acedatacloud/sdk transport, the standalone createX402Client + post/get wrapper in src/client.ts is redundant — everyone should go through the SDK, and the few places that need to bypass the SDK already import the low-level signSolanaPayment / signEVMPayment primitives directly. Changes: - delete src/client.ts (createX402Client, post, get, request) - drop X402ClientOptions + X402Response from src/types.ts - prune the top-level exports in src/index.ts - rewrite README.md as a single coherent doc (the old README had been stacked, with duplicate sections referencing createX402Client) - fix a stale console.log in scripts/test-e2e.ts Public API after this change: createX402PaymentHandler, X402PaymentHandlerOptions signSolanaPayment, signEVMPayment PaymentRequirement, PaymentRequiredResponse, X402PaymentEnvelope SolanaWalletAdapter, EVMProvider, SolanaPayload, EVMPayload, EVMAuthorization Build verified (npm run build → 0 errors).
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.
Follow-up cleanup to #10.
With
createX402PaymentHandlernow wired into the@acedatacloud/sdktransport,the standalone
createX402Client+post/getwrapper insrc/client.tsisredundant. Every application path should go through the SDK; the few scripts
and tests that need to bypass the SDK already import the low-level
signSolanaPayment/signEVMPaymentprimitives directly.Changes
src/client.ts(createX402Client,post,get,request)X402ClientOptions+X402Responsefromsrc/types.tssrc/index.tsREADME.mdas a single coherent doc (The old README had beenstacked, with duplicate sections referencing
createX402Client)console.loginscripts/test-e2e.tsPublic API after this change
Verification
npm run build→ 0 errorsgrep createX402Client src/ scripts/ README.md→ 0 matches