package main
import(
"context"
polargo "github.com/polarsource/polar-go"
"github.com/polarsource/polar-go/models/components"
"log"
)
func main() {
ctx := context.Background()
s := polargo.New()
res, err := s.CustomerSeats.ClaimSeat(ctx, components.SeatClaim{
InvitationToken: "<value>",
})
if err != nil {
log.Fatal(err)
}
if res.CustomerSeatClaimResponse != nil {
// handle response
}
}{
"seat": {
"created_at": "2023-11-07T05:31:56Z",
"modified_at": "2023-11-07T05:31:56Z",
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"status": "pending",
"subscription_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"order_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"customer_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"customer_email": "<string>",
"invitation_token_expires_at": "2023-11-07T05:31:56Z",
"claimed_at": "2023-11-07T05:31:56Z",
"revoked_at": "2023-11-07T05:31:56Z",
"seat_metadata": {}
},
"customer_session_token": "<string>"
}Invitation token to claim the seat
Successful Response
Response after successfully claiming a seat.
The claimed seat
Show child attributes
Creation timestamp of the object.
Last modification timestamp of the object.
The seat ID
Status of the seat
pending, claimed, revoked The subscription ID (for recurring seats)
The order ID (for one-time purchase seats)
The assigned customer ID
The assigned customer email
When the invitation token expires
When the seat was claimed
When the seat was revoked
Additional metadata for the seat
Session token for immediate customer portal access
Was this page helpful?
package main
import(
"context"
polargo "github.com/polarsource/polar-go"
"github.com/polarsource/polar-go/models/components"
"log"
)
func main() {
ctx := context.Background()
s := polargo.New()
res, err := s.CustomerSeats.ClaimSeat(ctx, components.SeatClaim{
InvitationToken: "<value>",
})
if err != nil {
log.Fatal(err)
}
if res.CustomerSeatClaimResponse != nil {
// handle response
}
}{
"seat": {
"created_at": "2023-11-07T05:31:56Z",
"modified_at": "2023-11-07T05:31:56Z",
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"status": "pending",
"subscription_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"order_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"customer_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"customer_email": "<string>",
"invitation_token_expires_at": "2023-11-07T05:31:56Z",
"claimed_at": "2023-11-07T05:31:56Z",
"revoked_at": "2023-11-07T05:31:56Z",
"seat_metadata": {}
},
"customer_session_token": "<string>"
}