---
sidebar:
  label: roboto.domain.tokens
  order: 13
title: roboto.domain.tokens
---
Personal access tokens: credentials that authenticate requests to Roboto as the user who owns them.

Use [`Token`](/docs/reference/python-sdk/roboto/domain/tokens#roboto.domain.tokens.Token) to create, list, disable, and delete personal access tokens.

## Submodules

- [roboto.domain.tokens.operations](/docs/reference/python-sdk/roboto/domain/tokens/operations)
- [roboto.domain.tokens.record](/docs/reference/python-sdk/roboto/domain/tokens/record)
- [roboto.domain.tokens.token](/docs/reference/python-sdk/roboto/domain/tokens/token)

## Package Contents

- [CreateCredentialRequest](/docs/reference/python-sdk/roboto/domain/tokens/operations#roboto.domain.tokens.operations.CreateCredentialRequest) (class): Request body for `POST /v1/tokens/requests`.

- [CreateCredentialRequestResult](/docs/reference/python-sdk/roboto/domain/tokens/operations#roboto.domain.tokens.operations.CreateCredentialRequestResult) (class): Response body of `POST /v1/tokens/requests`: a credential request that expires ten minutes after creation.

- [CreateTokenRequest](/docs/reference/python-sdk/roboto/domain/tokens/operations#roboto.domain.tokens.operations.CreateTokenRequest) (class): Request body to create an access token.

- [ExchangeCredentialRequestCode](/docs/reference/python-sdk/roboto/domain/tokens/operations#roboto.domain.tokens.operations.ExchangeCredentialRequestCode) (class): Request body for `POST /v1/tokens/requests/exchange`.

- [MAX_CREDENTIAL_REQUEST_TOKEN_EXPIRY_DAYS](/docs/reference/python-sdk/roboto/domain/tokens/operations#roboto.domain.tokens.operations.MAX_CREDENTIAL_REQUEST_TOKEN_EXPIRY_DAYS) (data): `MAX_CREDENTIAL_REQUEST_TOKEN_EXPIRY_DAYS = 365`. Maximum lifetime of the token a `CreateCredentialRequest` asks for, in days.

- [Token](/docs/reference/python-sdk/roboto/domain/tokens/token#roboto.domain.tokens.token.Token) (class): A personal access token: a credential that authenticates requests to Roboto as the user who owns it.

- [TokenContext](/docs/reference/python-sdk/roboto/domain/tokens/record#roboto.domain.tokens.record.TokenContext) (class): Details of a personal access token other than its secret and owner: its name, lifetime, scopes, and state.

- [TokenRecord](/docs/reference/python-sdk/roboto/domain/tokens/record#roboto.domain.tokens.record.TokenRecord) (class): Data record of a personal access token, as the Roboto API returns it.
