Skip to content

feat(paypal-js/types): add missing vaultSetupToken to OnApproveData#780

Open
nguyenkhavi wants to merge 1 commit intopaypal:mainfrom
nguyenkhavi:main
Open

feat(paypal-js/types): add missing vaultSetupToken to OnApproveData#780
nguyenkhavi wants to merge 1 commit intopaypal:mainfrom
nguyenkhavi:main

Conversation

@nguyenkhavi
Copy link
Copy Markdown

@nguyenkhavi nguyenkhavi commented Dec 23, 2025

Summary

This PR adds the missing vaultSetupToken property to the OnApproveData TypeScript type.

Background

When using Vault with the PayPal JS SDK, the vaultSetupToken value can be returned in the onApprove callback. However, this field was not previously included in the OnApproveData type definition, leading to incomplete typings and requiring consumers to use type assertions or workarounds.

Changes

  • Added vaultSetupToken to the OnApproveData type
  • Improves TypeScript accuracy for Vault-related integrations
  • No runtime behavior changes

Impact

  • TypeScript-only change
  • Backward compatible at runtime
  • Improves developer experience and type safety

Checklist

  • Type definitions updated
  • No breaking runtime changes
  • Changelog / changeset included (if applicable)

@nguyenkhavi nguyenkhavi requested a review from a team as a code owner December 23, 2025 02:53
@changeset-bot
Copy link
Copy Markdown

changeset-bot bot commented Dec 23, 2025

🦋 Changeset detected

Latest commit: a2b3a01

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 2 packages
Name Type
@paypal/paypal-js Major
@paypal/react-paypal-js Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@nguyenkhavi nguyenkhavi changed the title feat(paypal-js/types): add missing vaultSetupToken to OnApproveData` feat(paypal-js/types): add missing vaultSetupToken to OnApproveData Dec 23, 2025
@github-actions
Copy link
Copy Markdown
Contributor

This pull request has been automatically marked as stale. If this pull request is still relevant, please leave any comment (for example, "bump"), and we'll keep it open. We are sorry that we haven't been able to prioritize reviewing it yet. Your contribution is very much appreciated.

@github-actions github-actions bot added the Stale label Mar 24, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant