Skip to content

Latest commit

 

History

History
252 lines (159 loc) · 12.3 KB

File metadata and controls

252 lines (159 loc) · 12.3 KB

CustomerSeats

(customer_seats)

Overview

Available Operations

assign_seat

Scopes: customer_seats:write

Example Usage

from polar_sdk import Polar


with Polar(
    access_token="<YOUR_BEARER_TOKEN_HERE>",
) as polar:

    res = polar.customer_seats.assign_seat(request={})

    # Handle response
    print(res)

Parameters

Parameter Type Required Description
request models.SeatAssign ✔️ The request object to use for the request.
retries Optional[utils.RetryConfig] Configuration to override the default retry behavior of the client.

Response

models.CustomerSeat

Errors

Error Type Status Code Content Type
models.HTTPValidationError 422 application/json
models.SDKError 4XX, 5XX */*

list_seats

Scopes: customer_seats:write

Example Usage

from polar_sdk import Polar


with Polar(
    access_token="<YOUR_BEARER_TOKEN_HERE>",
) as polar:

    res = polar.customer_seats.list_seats()

    # Handle response
    print(res)

Parameters

Parameter Type Required Description
subscription_id OptionalNullable[str] N/A
order_id OptionalNullable[str] N/A
retries Optional[utils.RetryConfig] Configuration to override the default retry behavior of the client.

Response

models.SeatsList

Errors

Error Type Status Code Content Type
models.HTTPValidationError 422 application/json
models.SDKError 4XX, 5XX */*

revoke_seat

Scopes: customer_seats:write

Example Usage

from polar_sdk import Polar


with Polar(
    access_token="<YOUR_BEARER_TOKEN_HERE>",
) as polar:

    res = polar.customer_seats.revoke_seat(seat_id="<id>")

    # Handle response
    print(res)

Parameters

Parameter Type Required Description
seat_id str ✔️ N/A
retries Optional[utils.RetryConfig] Configuration to override the default retry behavior of the client.

Response

models.CustomerSeat

Errors

Error Type Status Code Content Type
models.HTTPValidationError 422 application/json
models.SDKError 4XX, 5XX */*

resend_invitation

Scopes: customer_seats:write

Example Usage

from polar_sdk import Polar


with Polar(
    access_token="<YOUR_BEARER_TOKEN_HERE>",
) as polar:

    res = polar.customer_seats.resend_invitation(seat_id="<id>")

    # Handle response
    print(res)

Parameters

Parameter Type Required Description
seat_id str ✔️ N/A
retries Optional[utils.RetryConfig] Configuration to override the default retry behavior of the client.

Response

models.CustomerSeat

Errors

Error Type Status Code Content Type
models.HTTPValidationError 422 application/json
models.SDKError 4XX, 5XX */*

get_claim_info

Get Claim Info

Example Usage

from polar_sdk import Polar


with Polar() as polar:

    res = polar.customer_seats.get_claim_info(invitation_token="<value>")

    # Handle response
    print(res)

Parameters

Parameter Type Required Description
invitation_token str ✔️ N/A
retries Optional[utils.RetryConfig] Configuration to override the default retry behavior of the client.

Response

models.SeatClaimInfo

Errors

Error Type Status Code Content Type
models.HTTPValidationError 422 application/json
models.SDKError 4XX, 5XX */*

claim_seat

Claim Seat

Example Usage

from polar_sdk import Polar


with Polar() as polar:

    res = polar.customer_seats.claim_seat(request={
        "invitation_token": "<value>",
    })

    # Handle response
    print(res)

Parameters

Parameter Type Required Description
request models.SeatClaim ✔️ The request object to use for the request.
retries Optional[utils.RetryConfig] Configuration to override the default retry behavior of the client.

Response

models.CustomerSeatClaimResponse

Errors

Error Type Status Code Content Type
models.HTTPValidationError 422 application/json
models.SDKError 4XX, 5XX */*