---
title: "Python SDK: Passport"
description: "The methods of the Python client under Passport. The outside services an inbox's address is signed up for, the verification codes and sign-in links they send, and how the address signs in to the ones that accept Sign in with Doorman."
url: https://doorman.fyi/docs/python/reference/passport
markdown: https://doorman.fyi/docs/python/reference/passport.md
area: "SDKs and tools"
section: "Python SDK"
---

# Python SDK: Passport

The methods of the Python client under Passport. The outside services an inbox's address is signed up for, the verification codes and sign-in links they send, and how the address signs in to the ones that accept Sign in with Doorman.

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

## client.inboxes.services.create

Python:
```python
client.inboxes.services.create(inbox_id: str, body: models.CreateService) -> models.Service
```

Operation [`inboxes.services.create`](https://doorman.fyi/docs/reference/passport.md#inboxes-services-create): `POST /v1/inboxes/{inboxId}/services`

Declare or add a service.

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

## client.inboxes.sign_ins.create

Python:
```python
client.inboxes.sign_ins.create(inbox_id: str, body: models.StartSignIn) -> models.SignInStart
```

Operation [`inboxes.signIns.create`](https://doorman.fyi/docs/reference/passport.md#inboxes-signIns-create): `POST /v1/inboxes/{inboxId}/sign-ins`

Start a sign-in.

Access `any`: any API key, or a console session. An app token needs `mail:write` and `mail:read`. Part of [Sign in with Doorman](https://doorman.fyi/docs/passport.md#sign-in), which a deployment switches on: where it is off, the call answers `404 not_found`.

## client.inboxes.verifications.list

Python:
```python
client.inboxes.verifications.list(inbox_id: str, *, domain: str | None = None, since: str | None = None, wait_seconds: int | None = None) -> models.VerificationList
```

Operation [`inboxes.verifications.list`](https://doorman.fyi/docs/reference/passport.md#inboxes-verifications-list): `GET /v1/inboxes/{inboxId}/verifications`

Read verification codes.

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

## client.passport.get

Python:
```python
client.passport.get() -> models.PassportSettings
```

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

Read passport settings.

Access `account`: an account-scoped key or a console session; an inbox-scoped key gets 403 `forbidden`. App tokens are refused.

## client.passport.update

Python:
```python
client.passport.update(body: models.UpdatePassportSettings) -> models.PassportSettings
```

Operation [`passport.update`](https://doorman.fyi/docs/reference/passport.md#passport-update): `PATCH /v1/passport`

Update passport settings.

Access `account`: an account-scoped key or a console session; an inbox-scoped key gets 403 `forbidden`. App tokens are refused.

## client.services.delete

Python:
```python
client.services.delete(service_id: str) -> None
```

Operation [`services.delete`](https://doorman.fyi/docs/reference/passport.md#services-delete): `DELETE /v1/services/{serviceId}`

Delete a service.

Access `any`: any API key, or a console session. App tokens are refused.

## client.services.get

Python:
```python
client.services.get(service_id: str) -> models.ServiceDetail
```

Operation [`services.get`](https://doorman.fyi/docs/reference/passport.md#services-get): `GET /v1/services/{serviceId}`

Read a service.

Access `any`: any API key, or a console session. App tokens are refused.

## client.services.list

Python:
```python
client.services.list(*, inbox_id: str | None = None, status: Literal['pending', 'active', 'cancelled', 'archived'] | None = None, attention: bool | None = None, q: str | None = None, limit: int | None = None, offset: int | None = None) -> models.ServicePage
```

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

List services.

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

## client.services.iterate

Python:
```python
client.services.iterate(*, inbox_id: str | None = None, status: Literal['pending', 'active', 'cancelled', 'archived'] | None = None, attention: bool | None = None, q: str | None = None, limit: int | None = None, offset: int | None = None) -> Iterator[models.Service]
```

Every item of [`client.services.list`](https://doorman.fyi/docs/python/reference/passport.md#services-list), one page at a time: the next page is asked for when the loop reaches it. A page that does not advance raises `ApiError`.

## client.services.update

Python:
```python
client.services.update(service_id: str, body: models.UpdateService) -> models.Service
```

Operation [`services.update`](https://doorman.fyi/docs/reference/passport.md#services-update): `PATCH /v1/services/{serviceId}`

Update a service.

Access `any`: any API key, or a console session. App tokens are refused.
