⚡ Solution Summary

  • The quote PDF endpoint was not using the correct domain in requests.
  • A bug was identified in the code responsible for handling the endpoint.
  • Update to stripe-python library version 9.3.0 to resolve the issue.
### Describe the bug Looks like the [download quote PDF](https://docs.stripe.com/api/quotes/pdf) endpoint is under a different domain than the other API endpoints, but the client does not update the domain in the request ### To Reproduce ```python resource = stripe.Quote.retrieve(<quote_id>) resource.pdf() ``` causes ``` InvalidRequestError: Unrecognized request URL (GET: /v1/quotes/<quote_id>/pdf). Please see https://stripe.com/docs or we can help at https://support.stripe.com/. ``` ### Expected behavior The client should successfully request the quote endpoint ### Code snippets _No response_ ### OS macOS ### Language version Python 3.12.3 ### Library version v9.1.0 ### API version 2024-04-10 ### Additional context _No response_

Discussion & Fixes

remi-stripe 2024-04-16
Hey @jhhayashi thanks a lot for the report and really sorry for the trouble here. Looks like we have a bug in our code [here](https://github.com/stripe/stripe-python/blob/c3165847/stripe/_quote.py#L1837) where we don't properly pass the `base_address` like we should. Seem like it broke a few months ago in a refactor [on this change](https://github.com/stripe/stripe-python/pull/1206/files#diff-36457d45b860ad529d0e0c23417539eceb47062acda4f0de3f73a1a599cb933dL1644) We'll work on a fix quickly and follow up.
ramya-stripe 2024-04-17
Thanks for reporting this @jhhayashi The fix will be out in tomorrow's release of the stripe-python library
jhhayashi 2024-04-18
Awesome, thanks for the quick turnaround!
ramya-stripe 2024-04-18
The fix is out in version 9.3.0

Get updates

We publish verified fixes weekly. No spam.

Subscribe