Add support for Client Side Tokens #245
Merged
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.
I see you previously closed a request related to this, as it was out of scope (However I'm assuming you were referring to the pricing preview feature itself).
Seeing as Paddle has mostly replaced all their documentation to refer to the "client side token" instead of the seller id, I think its wise to add support for- and prefer this method of configuration, as Paddle has stated that this is the preferred way now.
Quote from the changelog.
https://developer.paddle.com/changelog/2023/client-side-tokens
Implementation Details
This PR adds the
client_side_token
configuration key, and uses thePADDLE_CLIENT_SIDE_TOKEN
env key.If no client side token is provided, it use the
seller_id
as before, however theclient_side token
will be take precedence over theseller_id
if provided.Breaking changes
None.
This change will not have any effect for existing consumers of the package unless they add the new env or config option to their code.