---
title: "Python SDK: Account"
description: "The methods of the Python client under Account. The account, its plan and usage, and account-wide counts."
url: https://doorman.fyi/docs/python/reference/account
markdown: https://doorman.fyi/docs/python/reference/account.md
area: "SDKs and tools"
section: "Python SDK"
---

# Python SDK: Account

The methods of the Python client under Account. The account, its plan and usage, and account-wide counts.

Source: https://doorman.fyi/docs/python/reference/account

## client.me

Python:
```python
client.me() -> models.Me
```

Operation [`me`](https://doorman.fyi/docs/reference/account.md#me): `GET /v1/me`

Who am I.

Access `any`: any API key, or a console session. An app token needs `account:read`.

## client.metrics

Python:
```python
client.metrics(*, from_: str | None = None, to: str | None = None, interval: Literal['hour', 'day'] | None = None, inbox_id: str | None = None) -> models.Metrics
```

Operation [`metrics`](https://doorman.fyi/docs/reference/account.md#metrics): `GET /v1/metrics`

Metrics.

Access `any`: any API key, or a console session. An app token needs `account:read`.

## client.overview

Python:
```python
client.overview() -> models.Overview
```

Operation [`overview`](https://doorman.fyi/docs/reference/account.md#overview): `GET /v1/overview`

Overview.

Access `account`: an account-scoped key or a console session; an inbox-scoped key gets 403 `forbidden`. An app token needs `account:read`.

## client.billing.checkout

Python:
```python
client.billing.checkout() -> models.BillingRedirect
```

Operation [`billing.checkout`](https://doorman.fyi/docs/reference/account.md#billing-checkout): `POST /v1/billing/checkout`

Start a checkout.

Access `session`: a console session only; an API key gets 403 `session_required`. App tokens are refused. Part of billing, which a deployment switches on: where it takes no payments, the call answers `404 not_found`.

## client.billing.portal

Python:
```python
client.billing.portal() -> models.BillingRedirect
```

Operation [`billing.portal`](https://doorman.fyi/docs/reference/account.md#billing-portal): `POST /v1/billing/portal`

Open the billing portal.

Access `session`: a console session only; an API key gets 403 `session_required`. App tokens are refused. Part of billing, which a deployment switches on: where it takes no payments, the call answers `404 not_found`.

## client.billing.seats

Python:
```python
client.billing.seats(body: models.SetSeats) -> models.BillingSynced
```

Operation [`billing.seats`](https://doorman.fyi/docs/reference/account.md#billing-seats): `POST /v1/billing/seats`

Change the organization's seats.

Access `session`: a console session only; an API key gets 403 `session_required`. App tokens are refused. Part of billing, which a deployment switches on: where it takes no payments, the call answers `404 not_found`.

## client.billing.sync

Python:
```python
client.billing.sync() -> models.BillingSynced
```

Operation [`billing.sync`](https://doorman.fyi/docs/reference/account.md#billing-sync): `POST /v1/billing/sync`

Read billing again.

Access `session`: a console session only; an API key gets 403 `session_required`. App tokens are refused. Part of billing, which a deployment switches on: where it takes no payments, the call answers `404 not_found`.

## client.invitations.create

Python:
```python
client.invitations.create(body: models.CreateInvitation) -> models.Invitation
```

Operation [`invitations.create`](https://doorman.fyi/docs/reference/account.md#invitations-create): `POST /v1/invitations`

Invite someone to the organization.

Access `session`: a console session only; an API key gets 403 `session_required`. App tokens are refused.

## client.invitations.list

Python:
```python
client.invitations.list() -> models.InvitationList
```

Operation [`invitations.list`](https://doorman.fyi/docs/reference/account.md#invitations-list): `GET /v1/invitations`

List the organization's invitations.

Access `session`: a console session only; an API key gets 403 `session_required`. App tokens are refused.

## client.invitations.revoke

Python:
```python
client.invitations.revoke(invitation_id: str) -> None
```

Operation [`invitations.revoke`](https://doorman.fyi/docs/reference/account.md#invitations-revoke): `DELETE /v1/invitations/{invitationId}`

Take an invitation back.

Access `session`: a console session only; an API key gets 403 `session_required`. App tokens are refused.

## client.invitations.update

Python:
```python
client.invitations.update(invitation_id: str, body: models.UpdateInvitation) -> models.Invitation
```

Operation [`invitations.update`](https://doorman.fyi/docs/reference/account.md#invitations-update): `PATCH /v1/invitations/{invitationId}`

Record that an invitation was sent.

Access `session`: a console session only; an API key gets 403 `session_required`. App tokens are refused.

## client.members.list

Python:
```python
client.members.list() -> models.MemberList
```

Operation [`members.list`](https://doorman.fyi/docs/reference/account.md#members-list): `GET /v1/members`

List the organization's members.

Access `session`: a console session only; an API key gets 403 `session_required`. App tokens are refused.

## client.members.update

Python:
```python
client.members.update(user_id: str, body: models.UpdateMember) -> models.Member
```

Operation [`members.update`](https://doorman.fyi/docs/reference/account.md#members-update): `PATCH /v1/members/{userId}`

Change a member's role.

Access `session`: a console session only; an API key gets 403 `session_required`. App tokens are refused.

## client.organization.adopt

Python:
```python
client.organization.adopt(body: models.AdoptAccount) -> models.Account
```

Operation [`organization.adopt`](https://doorman.fyi/docs/reference/account.md#organization-adopt): `POST /v1/organization/adopt`

Move a personal account into the organization.

Access `session`: a console session only; an API key gets 403 `session_required`. App tokens are refused.

## client.push.get

Python:
```python
client.push.get() -> models.PushSettings
```

Operation [`push.get`](https://doorman.fyi/docs/reference/account.md#push-get): `GET /v1/push`

Read notification settings.

Access `session`: a console session only; an API key gets 403 `session_required`. App tokens are refused.

## client.push.subscriptions.create

Python:
```python
client.push.subscriptions.create(body: models.CreatePushSubscription) -> models.PushSubscription
```

Operation [`push.subscriptions.create`](https://doorman.fyi/docs/reference/account.md#push-subscriptions-create): `POST /v1/push/subscriptions`

Switch notifications on for a browser.

Access `session`: a console session only; an API key gets 403 `session_required`. App tokens are refused.

## client.push.subscriptions.delete

Python:
```python
client.push.subscriptions.delete(subscription_id: str) -> None
```

Operation [`push.subscriptions.delete`](https://doorman.fyi/docs/reference/account.md#push-subscriptions-delete): `DELETE /v1/push/subscriptions/{subscriptionId}`

Switch notifications off for a browser.

Access `session`: a console session only; an API key gets 403 `session_required`. App tokens are refused.
