braintree / braintree_node

Braintree Node.js library
https://developer.paypal.com/braintree/docs/start/overview
MIT License
334 stars 104 forks source link

SubscriptionRequest cannot use paymentMethodNonce without paymentMethodToken #183

Closed 9029jonesj closed 3 years ago

9029jonesj commented 3 years ago

General information

Issue description

When updating a subscription using the dropIn wit a clientId, a paymentMethodToken should not be required; otherwise the subscription does not get updated. This is really an issue with the TypeScript definition for the SubscriptionRequest interface.

crookedneighbor commented 3 years ago

@9029jonesj we don't maintain the types library from definitely typed.

In the future, we're planning on migrating this repo to typescript proper, at which point all the type definitions will be built in and maintained by us.

Until then, I recommend you update the types definition to suit your needs: https://github.com/DefinitelyTyped/DefinitelyTyped/blob/master/types/braintree/index.d.ts