Skip to content

feat(wallets): add create wrapper for crypto deposit accounts - #201

Closed
ss-privy wants to merge 1 commit into
mainfrom
sina/crypto-deposit-create
Closed

feat(wallets): add create wrapper for crypto deposit accounts#201
ss-privy wants to merge 1 commit into
mainfrom
sina/crypto-deposit-create

Conversation

@ss-privy

Copy link
Copy Markdown
Contributor

Summary

Stainless generates _create for Node on this endpoint (AuthContextBackingMethods) because TypeScript cannot overload create with an authorization-context argument. This adds the public create wrapper that signs via authorization_context, the same pattern as wallets().earn().ethereum().deposit().

await privy.wallets().depositAccounts.crypto.create(walletId, {
  deposit_config_id: 'clg2rvssg025ny5fmul5m95fn',
  authorization_context: { authorization_private_keys: [key] },
});

Base is main (not next) so this sits on top of the generated crypto deposit _create from feat(api): api update.

Test plan

  • tsc --noEmit passes
  • Confirm create shows up on client.wallets().depositAccounts.crypto after install
  • Optional: create a crypto deposit account against staging with an owner authorization key

Made with Cursor

Stainless only emits _create on Node for this auth-context endpoint. Add the public create method that signs via authorization_context, matching earn.deposit.

Co-authored-by: Cursor <cursoragent@cursor.com>
Committed-By-Agent: cursor
@ss-privy

Copy link
Copy Markdown
Contributor Author

Closing in favor of #202.

Same wrapper; 202 also applies WithExpiry (so privy-request-expiry is not left on the public input / signed as body) and imports CreateCryptoDepositAccountResponse from the generated barrel. Better public-type freeze before create() has consumers.

Thirteen Grok reviews of this PR were 13–0 SHIP; none of the deltas in 202 were blockers, but they were the repeated should-fix items.

@ss-privy ss-privy closed this Aug 26, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant