lemonsqueezy.ts icon indicating copy to clipboard operation
lemonsqueezy.ts copied to clipboard

Create Checkout URL gives 500 server error

Open Parth971 opened this issue 1 year ago • 12 comments

Hi I've been using leamonsqeezy payment gateway since few days.

I found one Bug/Error in create checkout API.

Senario: I want to pre-feel checkout form with discount-code and other details.

I am able to do it with documentation, but during one case It returned 500 server error, so I thought you might be able help me.

I am hitting "https://api.lemonsqueezy.com/v1/checkouts", with some data (attached image). Now for this to work, I need to have dicount created in dashboard. So I created a discount by filling name, code, price, and remaining as it is; then it works as expected, but while creating discount if I manually select all product under "Discount applies to specific products?" dropdown, then checkout url is giving error which is not specified anywhere, and error message is also not making any sense.

Json data for Create Checkout URl: Screenshot from 2023-06-22 16-59-47

Response: status_code: 500 json: {'message': 'An unexpected error occurred.', 'event_id': {}}

please do let me know if this is issue from your end or I am doing something wrong. To note, I am doing this code in test mode.

Parth971 avatar Jun 22 '23 11:06 Parth971