Organizations
July 20, 2026 ยท View on GitHub
(organizations)
Overview
Available Operations
- list_organizations - List Organizations
- create - Create Organization
- get - Get Organization
- update - Update Organization
list_organizations
List organizations.
Scopes: organizations:read organizations:write
Example Usage
from polar_sdk import Polar
with Polar(
access_token="<YOUR_BEARER_TOKEN_HERE>",
) as polar:
res = polar.organizations.list_organizations(page=1, limit=10)
while res is not None:
# Handle items
res = res.next()
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
slug | OptionalNullable[str] | :heavy_minus_sign: | Filter by slug. |
page | Optional[int] | :heavy_minus_sign: | Page number, defaults to 1. |
limit | Optional[int] | :heavy_minus_sign: | Size of a page, defaults to 10. Maximum is 100. |
sorting | List[models.OrganizationSortProperty] | :heavy_minus_sign: | Sorting criterion. Several criteria can be used simultaneously and will be applied in order. Add a minus sign - before the criteria name to sort by descending order. |
retries | Optional[utils.RetryConfig] | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. |
Response
models.OrganizationsListResponse
Errors
| Error Type | Status Code | Content Type |
|---|---|---|
| models.HTTPValidationError | 422 | application/json |
| models.SDKError | 4XX, 5XX | */* |
create
Create an organization.
Scopes: organizations:write
Example Usage
from polar_sdk import Polar
with Polar(
access_token="<YOUR_BEARER_TOKEN_HERE>",
) as polar:
res = polar.organizations.create(request={
"name": "<value>",
"slug": "<value>",
})
# Handle response
print(res)
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
request | models.OrganizationCreate | :heavy_check_mark: | The request object to use for the request. |
retries | Optional[utils.RetryConfig] | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. |
Response
Errors
| Error Type | Status Code | Content Type |
|---|---|---|
| models.CannotCreateOrganizationError | 403 | application/json |
| models.HTTPValidationError | 422 | application/json |
| models.SDKError | 4XX, 5XX | */* |
get
Get an organization by ID.
Scopes: organizations:read organizations:write
Example Usage
from polar_sdk import Polar
with Polar(
access_token="<YOUR_BEARER_TOKEN_HERE>",
) as polar:
res = polar.organizations.get(id="1dbfc517-0bbf-4301-9ba8-555ca42b9737")
# Handle response
print(res)
Parameters
| Parameter | Type | Required | Description | Example |
|---|---|---|---|---|
id | str | :heavy_check_mark: | N/A | 1dbfc517-0bbf-4301-9ba8-555ca42b9737 |
retries | Optional[utils.RetryConfig] | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. |
Response
Errors
| Error Type | Status Code | Content Type |
|---|---|---|
| models.ResourceNotFound | 404 | application/json |
| models.HTTPValidationError | 422 | application/json |
| models.SDKError | 4XX, 5XX | */* |
update
Update an organization.
Scopes: organizations:write
Example Usage
from polar_sdk import Polar
with Polar(
access_token="<YOUR_BEARER_TOKEN_HERE>",
) as polar:
res = polar.organizations.update(id="1dbfc517-0bbf-4301-9ba8-555ca42b9737", organization_update={})
# Handle response
print(res)
Parameters
| Parameter | Type | Required | Description | Example |
|---|---|---|---|---|
id | str | :heavy_check_mark: | N/A | 1dbfc517-0bbf-4301-9ba8-555ca42b9737 |
organization_update | models.OrganizationUpdate | :heavy_check_mark: | N/A | |
retries | Optional[utils.RetryConfig] | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. |
Response
Errors
| Error Type | Status Code | Content Type |
|---|---|---|
| models.NotPermitted | 403 | application/json |
| models.ResourceNotFound | 404 | application/json |
| models.SSOEnforcementRequiresConnection | 409 | application/json |
| models.HTTPValidationError | 422 | application/json |
| models.SDKError | 4XX, 5XX | */* |