Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 12 additions & 9 deletions .speakeasy/gen.lock
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
lockVersion: 2.0.0
id: e7042734-e669-4c36-85da-bbb4a7500ac8
management:
docChecksum: f9f2707053257f5298131d6530946e63
docChecksum: 0e424b4596ee81d4d7c34b980bdb164c
docVersion: 0.1.0
speakeasyVersion: 1.648.0
generationVersion: 2.737.0
releaseVersion: 0.31.5
configChecksum: 0822c8291f14ca7037c4188b08d3ff60
releaseVersion: 0.31.6
configChecksum: f557b6fdf7b48246fcb012104230f817
repoURL: https://github.com/polarsource/polar-python.git
installationURL: https://github.com/polarsource/polar-python.git
published: true
Expand Down Expand Up @@ -4696,7 +4696,10 @@ examples:
application/json: {}
examplesVersion: 1.0.2
generatedTests: {}
releaseNotes: "## Python SDK Changes Detected:\n* `polar.customer_portal.seats.assign_seat()`: \n * `request.checkout_client_secret` **Removed** **Breaking** :warning:\n* `polar.events.list()`: `response.[list_resource_event_].items.[].[system_event]` **Changed** **Breaking** :warning:\n* `polar._endpointorder_created_post()`: \n * `request.data` **Changed** **Breaking** :warning:\n* `polar._endpointorder_updated_post()`: \n * `request.data` **Changed** **Breaking** :warning:\n* `polar._endpointorder_paid_post()`: \n * `request.data` **Changed** **Breaking** :warning:\n* `polar._endpointorder_refunded_post()`: \n * `request.data` **Changed** **Breaking** :warning:\n* `polar._endpointorganization_updated_post()`: \n * `request.data.feature_settings` **Changed** **Breaking** :warning:\n* `polar.organizations.list()`: `response.items.[].feature_settings` **Changed** **Breaking** :warning:\n* `polar.organizations.create()`: \n * `request.feature_settings` **Changed** **Breaking** :warning:\n * `response.feature_settings` **Changed** **Breaking** :warning:\n* `polar.organizations.get()`: `response.feature_settings` **Changed** **Breaking** :warning:\n* `polar.organizations.update()`: \n * `request.organization_update.feature_settings` **Changed** **Breaking** :warning:\n * `response.feature_settings` **Changed** **Breaking** :warning:\n* `polar.event-types.list()`: `response.items.[]` **Changed** **Breaking** :warning:\n* `polar.events.get()`: `response.[system_event]` **Changed** **Breaking** :warning:\n* `polar.customer-seats.assign_seat()`: `request` **Changed** **Breaking** :warning:\n* `polar.discounts.create()`: `request` **Changed** **Breaking** :warning:\n* `polar.subscriptions.update()`: \n * `request.subscription_update.[subscription_update_clear]` **Added**\n* `polar.members.create_member()`: \n * `request.role` **Changed**\n* `polar.customer_portal.customers.update()`: \n * `request.default_payment_method_id` **Added**\n* `polar.orders.receipt()`: **Added**\n* `polar.customer_portal.orders.list()`: `response.items.[]` **Changed**\n* `polar.customer_portal.orders.get()`: `response` **Changed**\n* `polar.customer_portal.orders.update()`: `response` **Changed**\n* `polar.customer_portal.subscriptions.update()`: \n * `request.customer_subscription_update.[customer_subscription_update_clear]` **Added**\n* `polar.orders.list()`: `response.items.[]` **Changed**\n* `polar.orders.get()`: `response` **Changed**\n* `polar.customer_portal.orders.receipt()`: **Added**\n* `polar.orders.update()`: `response` **Changed**\n"
releaseNotes: |
## Python SDK Changes Detected:
* `polar.organizations.list_organizations()`: **Added**
* `polar.organizations.list()`: **Deleted** **Breaking** :warning:
trackedFiles:
.devcontainer/README.md:
last_write_checksum: sha1:e2a191a1fa8ceb27387eb32eabf36f7ad16a532c
Expand All @@ -4709,7 +4712,7 @@ trackedFiles:
.vscode/settings.json:
last_write_checksum: sha1:f84632c81029fcdda8c3b0c768d02b836fc80526
USAGE.md:
last_write_checksum: sha1:f0b26c208168f2dff9aa26cdbaf5c1a3a8fbff98
last_write_checksum: sha1:100ad323976442d76b2055854c14371dbb36e2d5
docs/models/activesubscriptions.md:
last_write_checksum: sha1:b3eaf87dcdf62890d684cfc6ec8ddb2f574475c9
docs/models/activeuserbyevent.md:
Expand Down Expand Up @@ -7161,7 +7164,7 @@ trackedFiles:
docs/sdks/organizationaccesstokens/README.md:
last_write_checksum: sha1:05bb349d7b4ac8d0feda927af81a9a71de2e4684
docs/sdks/organizations/README.md:
last_write_checksum: sha1:539a9bb438f60e85284e0630399d566cdb139b2c
last_write_checksum: sha1:3fdbe442ff036467bbe8bfcd5befafc7d04c9d40
docs/sdks/payments/README.md:
last_write_checksum: sha1:c0c2c61bef213dfafcb00274baddd1c43ba3e602
docs/sdks/polarbenefitgrants/README.md:
Expand Down Expand Up @@ -7213,7 +7216,7 @@ trackedFiles:
src/polar_sdk/_hooks/types.py:
last_write_checksum: sha1:a218c66f3e2d1f1b9af54f270472b970b0cc1913
src/polar_sdk/_version.py:
last_write_checksum: sha1:d9ff953d823bfd0059ba15ec4ddc7d34b0cdd5a9
last_write_checksum: sha1:46b759bbbc3e8f6fe7eaad0222a2c04f9dfea6e7
src/polar_sdk/basesdk.py:
last_write_checksum: sha1:4523ea81f1381f171fe2d4e60f85b82203208d02
src/polar_sdk/benefit_grants.py:
Expand Down Expand Up @@ -8817,7 +8820,7 @@ trackedFiles:
src/polar_sdk/organization_access_tokens.py:
last_write_checksum: sha1:fc169e6debb5c6918755d3c3ce2dfdda2fad8ce0
src/polar_sdk/organizations.py:
last_write_checksum: sha1:3c21a0fcba6f317fa1ba9a6b7fcc3ca4f8d1e35a
last_write_checksum: sha1:7bbeff0d7a492c946b6eafc1ed411c5d63ecad00
src/polar_sdk/payments.py:
last_write_checksum: sha1:a5dded8ecdfef5faf4ce25fedaeed39c10adb881
src/polar_sdk/polar_benefit_grants.py:
Expand All @@ -8843,7 +8846,7 @@ trackedFiles:
src/polar_sdk/refunds.py:
last_write_checksum: sha1:3a40acdfa627d784ed220738c094536dbcd1a60f
src/polar_sdk/sdk.py:
last_write_checksum: sha1:8546539ea54f6b9708eff5e463e91e3059f27273
last_write_checksum: sha1:7a44c48c491ac2c41d1b0d049bacfd04fbcfcc00
src/polar_sdk/sdkconfiguration.py:
last_write_checksum: sha1:b9b14902f71407dd21a4b209f2e342c54a0a86a7
src/polar_sdk/seats.py:
Expand Down
2 changes: 1 addition & 1 deletion .speakeasy/gen.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ generation:
persistentEdits: {}
versioningStrategy: automatic
python:
version: 0.31.5
version: 0.31.6
additionalDependencies:
dev:
pydantic-ai-slim: ^0.1.0
Expand Down
12 changes: 6 additions & 6 deletions .speakeasy/workflow.lock
Original file line number Diff line number Diff line change
Expand Up @@ -2,20 +2,20 @@ speakeasyVersion: 1.648.0
sources:
Polar-OAS:
sourceNamespace: polar-oas
sourceRevisionDigest: sha256:71002fcc451a5c21286dce02a4500670f3d77017019bf7fd20a4fd669d20c34c
sourceBlobDigest: sha256:0effc8c2537f9cb96cc364f1b6d6e0eb3997dab0bf4b6803d46cca8099f4aa11
sourceRevisionDigest: sha256:5e054cfea98d5256319bb220e9c8f585ebed57dc3cf6aae69f264dc979d4388c
sourceBlobDigest: sha256:45fce03f5ddfb368842171555c811911ef0e2fd4927a744abd8ff62253312a5e
tags:
- latest
- speakeasy-sdk-regen-1779064662
- speakeasy-sdk-regen-1779324054
- 0.1.0
targets:
polar:
source: Polar-OAS
sourceNamespace: polar-oas
sourceRevisionDigest: sha256:71002fcc451a5c21286dce02a4500670f3d77017019bf7fd20a4fd669d20c34c
sourceBlobDigest: sha256:0effc8c2537f9cb96cc364f1b6d6e0eb3997dab0bf4b6803d46cca8099f4aa11
sourceRevisionDigest: sha256:5e054cfea98d5256319bb220e9c8f585ebed57dc3cf6aae69f264dc979d4388c
sourceBlobDigest: sha256:45fce03f5ddfb368842171555c811911ef0e2fd4927a744abd8ff62253312a5e
codeSamplesNamespace: polar-oas-py-code-samples
codeSamplesRevisionDigest: sha256:32cd60a9a754af414d62c8516a90943306093cf779f184d73635f472848df454
codeSamplesRevisionDigest: sha256:581545372f1e107474d0663b10b3ae87e0548feded0de1f7c509cc47d1a2a2bf
workflow:
workflowVersion: 1.0.0
speakeasyVersion: latest
Expand Down
20 changes: 10 additions & 10 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@ with Polar(
access_token="<YOUR_BEARER_TOKEN_HERE>",
) as polar:

res = polar.organizations.list(page=1, limit=10)
res = polar.organizations.list_organizations(page=1, limit=10)

while res is not None:
# Handle items
Expand All @@ -143,7 +143,7 @@ async def main():
access_token="<YOUR_BEARER_TOKEN_HERE>",
) as polar:

res = await polar.organizations.list_async(page=1, limit=10)
res = await polar.organizations.list_organizations_async(page=1, limit=10)

while res is not None:
# Handle items
Expand Down Expand Up @@ -460,7 +460,7 @@ of crashing on a `pydantic.ValidationError`.

### [organizations](docs/sdks/organizations/README.md)

* [list](docs/sdks/organizations/README.md#list) - List Organizations
* [list_organizations](docs/sdks/organizations/README.md#list_organizations) - List Organizations
* [create](docs/sdks/organizations/README.md#create) - Create Organization
* [get](docs/sdks/organizations/README.md#get) - Get Organization
* [update](docs/sdks/organizations/README.md#update) - Update Organization
Expand Down Expand Up @@ -521,7 +521,7 @@ with Polar(
access_token="<YOUR_BEARER_TOKEN_HERE>",
) as polar:

res = polar.organizations.list(page=1, limit=10,
res = polar.organizations.list_organizations(page=1, limit=10,
RetryConfig("backoff", BackoffStrategy(1, 50, 1.1, 100), False))

while res is not None:
Expand All @@ -542,7 +542,7 @@ with Polar(
access_token="<YOUR_BEARER_TOKEN_HERE>",
) as polar:

res = polar.organizations.list(page=1, limit=10)
res = polar.organizations.list_organizations(page=1, limit=10)

while res is not None:
# Handle items
Expand Down Expand Up @@ -578,7 +578,7 @@ with Polar(
res = None
try:

res = polar.organizations.list(page=1, limit=10)
res = polar.organizations.list_organizations(page=1, limit=10)

while res is not None:
# Handle items
Expand Down Expand Up @@ -665,7 +665,7 @@ with Polar(
access_token="<YOUR_BEARER_TOKEN_HERE>",
) as polar:

res = polar.organizations.list(page=1, limit=10)
res = polar.organizations.list_organizations(page=1, limit=10)

while res is not None:
# Handle items
Expand All @@ -686,7 +686,7 @@ with Polar(
access_token="<YOUR_BEARER_TOKEN_HERE>",
) as polar:

res = polar.organizations.list(page=1, limit=10)
res = polar.organizations.list_organizations(page=1, limit=10)

while res is not None:
# Handle items
Expand Down Expand Up @@ -797,7 +797,7 @@ with Polar(
access_token="<YOUR_BEARER_TOKEN_HERE>",
) as polar:

res = polar.organizations.list(page=1, limit=10)
res = polar.organizations.list_organizations(page=1, limit=10)

while res is not None:
# Handle items
Expand Down Expand Up @@ -886,7 +886,7 @@ with Polar(
access_token="<YOUR_BEARER_TOKEN_HERE>",
) as polar:

res = polar.organizations.list(page=1, limit=10)
res = polar.organizations.list_organizations(page=1, limit=10)

while res is not None:
# Handle items
Expand Down
12 changes: 11 additions & 1 deletion RELEASES.md
Original file line number Diff line number Diff line change
Expand Up @@ -1123,4 +1123,14 @@ Based on:
### Generated
- [python v0.31.5] .
### Releases
- [PyPI v0.31.5] https://pypi.org/project/polar-sdk/0.31.5 - .
- [PyPI v0.31.5] https://pypi.org/project/polar-sdk/0.31.5 - .

## 2026-05-23 00:37:52
### Changes
Based on:
- OpenAPI Doc
- Speakeasy CLI 1.648.0 (2.737.0) https://github.com/speakeasy-api/speakeasy
### Generated
- [python v0.31.6] .
### Releases
- [PyPI v0.31.6] https://pypi.org/project/polar-sdk/0.31.6 - .
4 changes: 2 additions & 2 deletions USAGE.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ with Polar(
access_token="<YOUR_BEARER_TOKEN_HERE>",
) as polar:

res = polar.organizations.list(page=1, limit=10)
res = polar.organizations.list_organizations(page=1, limit=10)

while res is not None:
# Handle items
Expand All @@ -31,7 +31,7 @@ async def main():
access_token="<YOUR_BEARER_TOKEN_HERE>",
) as polar:

res = await polar.organizations.list_async(page=1, limit=10)
res = await polar.organizations.list_organizations_async(page=1, limit=10)

while res is not None:
# Handle items
Expand Down
2 changes: 1 addition & 1 deletion codeSamples.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -944,7 +944,7 @@ actions:
"x-codeSamples":
- "lang": "python"
"label": "Python (SDK)"
"source": "from polar_sdk import Polar\n\n\nwith Polar(\n access_token=\"<YOUR_BEARER_TOKEN_HERE>\",\n) as polar:\n\n res = polar.organizations.list(page=1, limit=10)\n\n while res is not None:\n # Handle items\n\n res = res.next()"
"source": "from polar_sdk import Polar\n\n\nwith Polar(\n access_token=\"<YOUR_BEARER_TOKEN_HERE>\",\n) as polar:\n\n res = polar.organizations.list_organizations(page=1, limit=10)\n\n while res is not None:\n # Handle items\n\n res = res.next()"
- target: $["paths"]["/v1/organizations/"]["post"]
update:
"x-codeSamples":
Expand Down
6 changes: 3 additions & 3 deletions docs/sdks/organizations/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,12 @@

### Available Operations

* [list](#list) - List Organizations
* [list_organizations](#list_organizations) - List Organizations
* [create](#create) - Create Organization
* [get](#get) - Get Organization
* [update](#update) - Update Organization

## list
## list_organizations

List organizations.

Expand All @@ -27,7 +27,7 @@ with Polar(
access_token="<YOUR_BEARER_TOKEN_HERE>",
) as polar:

res = polar.organizations.list(page=1, limit=10)
res = polar.organizations.list_organizations(page=1, limit=10)

while res is not None:
# Handle items
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@

[project]
name = "polar-sdk"
version = "0.31.5"
version = "0.31.6"
description = "Polar SDK for Python"
authors = [{ name = "Polar" },]
readme = "README-PYPI.md"
Expand Down
4 changes: 2 additions & 2 deletions src/polar_sdk/_version.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,10 @@
import importlib.metadata

__title__: str = "polar-sdk"
__version__: str = "0.31.5"
__version__: str = "0.31.6"
__openapi_doc_version__: str = "0.1.0"
__gen_version__: str = "2.737.0"
__user_agent__: str = "speakeasy-sdk/python 0.31.5 2.737.0 0.1.0 polar-sdk"
__user_agent__: str = "speakeasy-sdk/python 0.31.6 2.737.0 0.1.0 polar-sdk"

try:
if __package__ is not None:
Expand Down
8 changes: 4 additions & 4 deletions src/polar_sdk/organizations.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@


class Organizations(BaseSDK):
def list(
def list_organizations(
self,
*,
slug: OptionalNullable[str] = UNSET,
Expand Down Expand Up @@ -109,7 +109,7 @@ def next_func() -> Optional[models.OrganizationsListResponse]:
if len(results[0]) < limit:
return None

return self.list(
return self.list_organizations(
slug=slug,
page=next_page,
limit=limit,
Expand Down Expand Up @@ -139,7 +139,7 @@ def next_func() -> Optional[models.OrganizationsListResponse]:

raise models.SDKError("Unexpected response received", http_res)

async def list_async(
async def list_organizations_async(
self,
*,
slug: OptionalNullable[str] = UNSET,
Expand Down Expand Up @@ -238,7 +238,7 @@ def next_func() -> Optional[models.OrganizationsListResponse]:
if len(results[0]) < limit:
return None

return self.list(
return self.list_organizations(
slug=slug,
page=next_page,
limit=limit,
Expand Down