Skip to content

Commit fbe0864

Browse files
speakeasybotfrankie567
authored andcommitted
## Python SDK Changes Detected:
* `polar._endpointorder_paid_post()`: * `request.data.invoice_number` **Added** **Breaking** ⚠️ * `polar._endpointorder_refunded_post()`: * `request.data.invoice_number` **Added** **Breaking** ⚠️ * `polar._endpointorder_created_post()`: * `request.data.invoice_number` **Added** **Breaking** ⚠️ * `polar._endpointorder_updated_post()`: * `request.data.invoice_number` **Added** **Breaking** ⚠️ * `polar.orders.update()`: `response.invoice_number` **Added** * `polar.customer_portal.orders.get()`: `response.invoice_number` **Added** * `polar.orders.list()`: `response.items.[].invoice_number` **Added** * `polar.orders.get()`: `response.invoice_number` **Added** * `polar.customers.get_balance()`: **Added** * `polar.customer_portal.customers.add_payment_method()`: `response` **Changed** * `polar.customer_portal.orders.list()`: `response.items.[].invoice_number` **Added** * `polar.customer_portal.customers.confirm_payment_method()`: **Added** * `polar.customer_portal.orders.update()`: `response.invoice_number` **Added** * `polar.customer_portal.subscriptions.list()`: `response.items.[].is_polar_managed` **Added** * `polar.customer_portal.subscriptions.get()`: `response.is_polar_managed` **Added** * `polar.customer_portal.subscriptions.cancel()`: `response.is_polar_managed` **Added** * `polar.customer_portal.subscriptions.update()`: `response.is_polar_managed` **Added** * `polar.meters.quantities()`: `request.customer_aggregation_function` **Added**
1 parent 8692905 commit fbe0864

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

48 files changed

+1992
-973
lines changed

.speakeasy/gen.lock

Lines changed: 65 additions & 24 deletions
Large diffs are not rendered by default.

.speakeasy/gen.yaml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ generation:
2525
generateNewTests: false
2626
skipResponseBodyAssertions: false
2727
python:
28-
version: 0.24.1
28+
version: 0.25.0
2929
additionalDependencies:
3030
dev:
3131
pydantic-ai-slim: ^0.1.0
@@ -36,6 +36,7 @@ python:
3636
allowedRedefinedBuiltins:
3737
- id
3838
- object
39+
asyncMode: both
3940
authors:
4041
- Polar
4142
baseErrorName: PolarError
@@ -58,6 +59,7 @@ python:
5859
shared: ""
5960
webhooks: ""
6061
inputModelSuffix: input
62+
legacyPyright: true
6163
maxMethodParams: 100
6264
methodArguments: infer-optional-args
6365
moduleName: ""

.speakeasy/workflow.lock

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,21 @@
1-
speakeasyVersion: 1.622.1
1+
speakeasyVersion: 1.631.4
22
sources:
33
Polar-OAS:
44
sourceNamespace: polar-oas
5-
sourceRevisionDigest: sha256:0d9a9658418370b636bfbcfc096e4a9c0e60b11f4bd3d14ad12983113f3a4c96
6-
sourceBlobDigest: sha256:7b79efd220fdcd869f7e48ef5168170576863031eb79cf1c338e0bb4fde28b76
5+
sourceRevisionDigest: sha256:1892991b5bcde6ddaa85ab053285b4b16032e0abd39596d3904bcfd4b0f2b9b5
6+
sourceBlobDigest: sha256:3d99dbf80059f5861879922b94bf7f2ebee0dd1e8c0acdfc80eed643f31aa1f0
77
tags:
88
- latest
9-
- speakeasy-sdk-regen-1758586426
9+
- speakeasy-sdk-regen-1758672830
1010
- 0.1.0
1111
targets:
1212
polar:
1313
source: Polar-OAS
1414
sourceNamespace: polar-oas
15-
sourceRevisionDigest: sha256:0d9a9658418370b636bfbcfc096e4a9c0e60b11f4bd3d14ad12983113f3a4c96
16-
sourceBlobDigest: sha256:7b79efd220fdcd869f7e48ef5168170576863031eb79cf1c338e0bb4fde28b76
15+
sourceRevisionDigest: sha256:1892991b5bcde6ddaa85ab053285b4b16032e0abd39596d3904bcfd4b0f2b9b5
16+
sourceBlobDigest: sha256:3d99dbf80059f5861879922b94bf7f2ebee0dd1e8c0acdfc80eed643f31aa1f0
1717
codeSamplesNamespace: polar-oas-py-code-samples
18-
codeSamplesRevisionDigest: sha256:c9ff0306d673e4ed1895ad8707b154aacb28256eec86423dc446d0c552efb64e
18+
codeSamplesRevisionDigest: sha256:bb81bca13bbbe25b9ce7971c18e98a33ca0e48798b8879492f75b52b5045beef
1919
workflow:
2020
workflowVersion: 1.0.0
2121
speakeasyVersion: latest

README.md

Lines changed: 23 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -131,6 +131,7 @@ with Polar(
131131
</br>
132132

133133
The same SDK client can also be used to make asynchronous requests by importing asyncio.
134+
134135
```python
135136
# Asynchronous Example
136137
import asyncio
@@ -249,6 +250,7 @@ def webhook():
249250
* [update](docs/sdks/polarcustomers/README.md#update) - Update Customer
250251
* [list_payment_methods](docs/sdks/polarcustomers/README.md#list_payment_methods) - List Customer Payment Methods
251252
* [add_payment_method](docs/sdks/polarcustomers/README.md#add_payment_method) - Add Customer Payment Method
253+
* [confirm_payment_method](docs/sdks/polarcustomers/README.md#confirm_payment_method) - Confirm Customer Payment Method
252254
* [delete_payment_method](docs/sdks/polarcustomers/README.md#delete_payment_method) - Delete Customer Payment Method
253255

254256
#### [customer_portal.downloadables](docs/sdks/downloadables/README.md)
@@ -301,6 +303,7 @@ def webhook():
301303
* [delete_external](docs/sdks/customers/README.md#delete_external) - Delete Customer by External ID
302304
* [get_state](docs/sdks/customers/README.md#get_state) - Get Customer State
303305
* [get_state_external](docs/sdks/customers/README.md#get_state_external) - Get Customer State by External ID
306+
* [get_balance](docs/sdks/customers/README.md#get_balance) - Get Customer Balance
304307

305308
### [discounts](docs/sdks/discounts/README.md)
306309

@@ -510,7 +513,7 @@ with Polar(
510513
* [`PolarError`](./src/polar_sdk/models/polarerror.py): The base class for HTTP error responses.
511514
* [`HTTPValidationError`](./src/polar_sdk/models/httpvalidationerror.py): Validation Error. Status code `422`. *
512515

513-
<details><summary>Less common errors (23)</summary>
516+
<details><summary>Less common errors (24)</summary>
514517

515518
<br />
516519

@@ -521,24 +524,25 @@ with Polar(
521524

522525

523526
**Inherit from [`PolarError`](./src/polar_sdk/models/polarerror.py)**:
524-
* [`ResourceNotFound`](./src/polar_sdk/models/resourcenotfound.py): Status code `404`. Applicable to 76 of 130 methods.*
525-
* [`NotPermitted`](./src/polar_sdk/models/notpermitted.py): Status code `403`. Applicable to 10 of 130 methods.*
526-
* [`Unauthorized`](./src/polar_sdk/models/unauthorized.py): Not authorized to manage license key. Status code `401`. Applicable to 5 of 130 methods.*
527-
* [`AlreadyCanceledSubscription`](./src/polar_sdk/models/alreadycanceledsubscription.py): Status code `403`. Applicable to 4 of 130 methods.*
528-
* [`AlreadyActiveSubscriptionError`](./src/polar_sdk/models/alreadyactivesubscriptionerror.py): The checkout is expired, the customer already has an active subscription, or the organization is not ready to accept payments. Status code `403`. Applicable to 3 of 130 methods.*
529-
* [`NotOpenCheckout`](./src/polar_sdk/models/notopencheckout.py): The checkout is expired, the customer already has an active subscription, or the organization is not ready to accept payments. Status code `403`. Applicable to 3 of 130 methods.*
530-
* [`PaymentNotReady`](./src/polar_sdk/models/paymentnotready.py): The checkout is expired, the customer already has an active subscription, or the organization is not ready to accept payments. Status code `403`. Applicable to 3 of 130 methods.*
531-
* [`ExpiredCheckoutError`](./src/polar_sdk/models/expiredcheckouterror.py): The checkout session is expired. Status code `410`. Applicable to 3 of 130 methods.*
532-
* [`SubscriptionLocked`](./src/polar_sdk/models/subscriptionlocked.py): Subscription is pending an update. Status code `409`. Applicable to 2 of 130 methods.*
533-
* [`InvoiceAlreadyExists`](./src/polar_sdk/models/invoicealreadyexists.py): Order already has an invoice. Status code `409`. Applicable to 2 of 130 methods.*
534-
* [`MissingInvoiceBillingDetails`](./src/polar_sdk/models/missinginvoicebillingdetails.py): Order is not paid or is missing billing name or address. Status code `422`. Applicable to 2 of 130 methods.*
535-
* [`NotPaidOrder`](./src/polar_sdk/models/notpaidorder.py): Order is not paid or is missing billing name or address. Status code `422`. Applicable to 2 of 130 methods.*
536-
* [`RefundAmountTooHigh`](./src/polar_sdk/models/refundamounttoohigh.py): Refund amount exceeds remaining order balance. Status code `400`. Applicable to 1 of 130 methods.*
537-
* [`PaymentError`](./src/polar_sdk/models/paymenterror.py): The payment failed. Status code `400`. Applicable to 1 of 130 methods.*
538-
* [`PaymentMethodInUseByActiveSubscription`](./src/polar_sdk/models/paymentmethodinusebyactivesubscription.py): Payment method is used by active subscription(s). Status code `400`. Applicable to 1 of 130 methods.*
539-
* [`RefundedAlready`](./src/polar_sdk/models/refundedalready.py): Order is already fully refunded. Status code `403`. Applicable to 1 of 130 methods.*
540-
* [`PaymentAlreadyInProgress`](./src/polar_sdk/models/paymentalreadyinprogress.py): Payment already in progress. Status code `409`. Applicable to 1 of 130 methods.*
541-
* [`OrderNotEligibleForRetry`](./src/polar_sdk/models/ordernoteligibleforretry.py): Order not eligible for retry or payment confirmation failed. Status code `422`. Applicable to 1 of 130 methods.*
527+
* [`ResourceNotFound`](./src/polar_sdk/models/resourcenotfound.py): Status code `404`. Applicable to 77 of 132 methods.*
528+
* [`NotPermitted`](./src/polar_sdk/models/notpermitted.py): Status code `403`. Applicable to 10 of 132 methods.*
529+
* [`Unauthorized`](./src/polar_sdk/models/unauthorized.py): Not authorized to manage license key. Status code `401`. Applicable to 5 of 132 methods.*
530+
* [`AlreadyCanceledSubscription`](./src/polar_sdk/models/alreadycanceledsubscription.py): Status code `403`. Applicable to 4 of 132 methods.*
531+
* [`AlreadyActiveSubscriptionError`](./src/polar_sdk/models/alreadyactivesubscriptionerror.py): The checkout is expired, the customer already has an active subscription, or the organization is not ready to accept payments. Status code `403`. Applicable to 3 of 132 methods.*
532+
* [`NotOpenCheckout`](./src/polar_sdk/models/notopencheckout.py): The checkout is expired, the customer already has an active subscription, or the organization is not ready to accept payments. Status code `403`. Applicable to 3 of 132 methods.*
533+
* [`PaymentNotReady`](./src/polar_sdk/models/paymentnotready.py): The checkout is expired, the customer already has an active subscription, or the organization is not ready to accept payments. Status code `403`. Applicable to 3 of 132 methods.*
534+
* [`ExpiredCheckoutError`](./src/polar_sdk/models/expiredcheckouterror.py): The checkout session is expired. Status code `410`. Applicable to 3 of 132 methods.*
535+
* [`SubscriptionLocked`](./src/polar_sdk/models/subscriptionlocked.py): Subscription is pending an update. Status code `409`. Applicable to 2 of 132 methods.*
536+
* [`InvoiceAlreadyExists`](./src/polar_sdk/models/invoicealreadyexists.py): Order already has an invoice. Status code `409`. Applicable to 2 of 132 methods.*
537+
* [`MissingInvoiceBillingDetails`](./src/polar_sdk/models/missinginvoicebillingdetails.py): Order is not paid or is missing billing name or address. Status code `422`. Applicable to 2 of 132 methods.*
538+
* [`NotPaidOrder`](./src/polar_sdk/models/notpaidorder.py): Order is not paid or is missing billing name or address. Status code `422`. Applicable to 2 of 132 methods.*
539+
* [`RefundAmountTooHigh`](./src/polar_sdk/models/refundamounttoohigh.py): Refund amount exceeds remaining order balance. Status code `400`. Applicable to 1 of 132 methods.*
540+
* [`PaymentError`](./src/polar_sdk/models/paymenterror.py): The payment failed. Status code `400`. Applicable to 1 of 132 methods.*
541+
* [`CustomerNotReady`](./src/polar_sdk/models/customernotready.py): Customer is not ready to confirm a payment method. Status code `400`. Applicable to 1 of 132 methods.*
542+
* [`PaymentMethodInUseByActiveSubscription`](./src/polar_sdk/models/paymentmethodinusebyactivesubscription.py): Payment method is used by active subscription(s). Status code `400`. Applicable to 1 of 132 methods.*
543+
* [`RefundedAlready`](./src/polar_sdk/models/refundedalready.py): Order is already fully refunded. Status code `403`. Applicable to 1 of 132 methods.*
544+
* [`PaymentAlreadyInProgress`](./src/polar_sdk/models/paymentalreadyinprogress.py): Payment already in progress. Status code `409`. Applicable to 1 of 132 methods.*
545+
* [`OrderNotEligibleForRetry`](./src/polar_sdk/models/ordernoteligibleforretry.py): Order not eligible for retry or payment confirmation failed. Status code `422`. Applicable to 1 of 132 methods.*
542546
* [`ResponseValidationError`](./src/polar_sdk/models/responsevalidationerror.py): Type mismatch between the response data and the expected Pydantic model. Provides access to the Pydantic validation error via the `cause` attribute.
543547

544548
</details>

RELEASES.md

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -913,4 +913,14 @@ Based on:
913913
### Generated
914914
- [python v0.24.1] .
915915
### Releases
916-
- [PyPI v0.24.1] https://pypi.org/project/polar-sdk/0.24.1 - .
916+
- [PyPI v0.24.1] https://pypi.org/project/polar-sdk/0.24.1 - .
917+
918+
## 2025-09-29 00:13:28
919+
### Changes
920+
Based on:
921+
- OpenAPI Doc
922+
- Speakeasy CLI 1.631.4 (2.716.16) https://github.com/speakeasy-api/speakeasy
923+
### Generated
924+
- [python v0.25.0] .
925+
### Releases
926+
- [PyPI v0.25.0] https://pypi.org/project/polar-sdk/0.25.0 - .

USAGE.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ with Polar(
1919
</br>
2020

2121
The same SDK client can also be used to make asynchronous requests by importing asyncio.
22+
2223
```python
2324
# Asynchronous Example
2425
import asyncio

0 commit comments

Comments
 (0)