Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Feature]: Use discountCode in PricingPreview #56

Open
holtwick opened this issue Aug 28, 2024 · 4 comments
Open

[Feature]: Use discountCode in PricingPreview #56

holtwick opened this issue Aug 28, 2024 · 4 comments
Assignees

Comments

@holtwick
Copy link

Tell us about your feature request

Pricing preview should allow to apply discount. There is discountId but no way to get discountCode using clientToken.

What problem are you looking to solve?

Additional discountCode property or API to fetch discountId from discountCode using clientToken.

Additional context

No response

How important is this suggestion to you?

Critical

@vijayasingam-paddle
Copy link
Contributor

Hi @holtwick,
Thank you for sharing this feedback with us.

This is the first time we are hearing about this as most integrators will be able to map their discountID while building the pricing page.

To help us understand this further, can you please share more details on how you are integrating the pricing preview API with your pricing page?

We could then help determine if there is a better way of achieving what you are trying to do while we take this to the product team for assessment.

Thank you.

@vijayasingam-paddle vijayasingam-paddle self-assigned this Aug 28, 2024
@holtwick
Copy link
Author

Sure. Take this URL for example:

https://pdfify.app/en/buy?coupon=F9AF6FAA

I distribute coupons to my clients and they should be able to apply them. To make it simple, I usually distribute the URL as seen above. But the coupon still should have a self speaking name like SUMMERSALE2024 or the like.

The checkout for Paddle Billing has the ability to hand over this code, but the preview in the page should also show the effect of the coupon to trigger users to buy. In Paddle Classic this was possible.

@vijayasingam-paddle
Copy link
Contributor

Hello 👋 ,
Thank you for sharing the URL.

Unfortunately, we don't have a way of doing this right now. I will raise this to the product team for further analysis.

Meanwhile, I can think of an alternative approach to what you want.

  1. Instead of adding the discount code to the URL, maybe you can add a discount ID and share it with your clients.
  2. When they load the page, you can pass the ID to the price preview API.
  3. The response will include the discount code (data.details.line_items[].discounts[].discount.code) and the percentage (data.details.line_items[].discounts[].discount.amount ). You can then display this information to your clients.

This approach is not ideal, but it could be a middle ground until the feature is implemented.

Please let us know if we can help you with anything else.

Thank you.

@holtwick
Copy link
Author

Well, for this and a few other reasons, I'm sticking with Paddle Classic for now. The new API doesn't seem to be ready yet... sorry.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants