# Retrieve a token using its ID

Retrieves a specific token using its ID.

Endpoint: GET /api/token/v2/{id}
Version: v2.0
Security: Bearer

## Path parameters:

  - `id` (string, required)
    The ID of the token to retrieve.

## Response 200 fields (application/json):

  - `id` (string)
    The unique identifier of the token.

  - `label` (string)
    The label of the token.

  - `description` (string)
    The description of the token.

  - `managePersistedQueries` (boolean)
    Gets or sets whether the token can manage persisted queries.

  - `expiration` (string)
    The expiration date and time of the token.

  - `restrictions` (object)
    Represents the restrictions associated with a token.
    Example: {"publishState":["Published"],"branches":["main"],"origins":["https://myapp.com"],"sourceIPs":["127.0.0.1"],"introspection":true}

  - `restrictions.publishState` (array)
    Gets or sets the publish states associated with the token.
    Enum: "Published", "Preview", "published", "preview"

  - `restrictions.branches` (array)
    Gets or sets the branches associated with the token. This can be an exact match with the branch ID or a prefix match.
    Example: ["main"]

  - `restrictions.sourceIPs` (array)
    Gets or sets the source IP addresses associated with the token.
    Example: ["127.0.0.1"]

  - `restrictions.origins` (array)
    Gets or sets the origins associated with the token.
    Example: ["https://myapp.com"]

  - `restrictions.introspection` (boolean)
    Gets or sets a value indicating whether introspection is allowed.
    Example: true

  - `lastUse` (string,null)
    The date and time when the token was last used.

  - `system` (object)
    Represents system metadata for a token.

  - `system.createdAt` (string)
    The date and time when the token was created.

  - `system.createdBy` (object)

  - `system.createdBy.type` (string)

  - `system.createdBy.relatedType` (string)

  - `system.createdBy.id` (string)

  - `system.createdBy.uri` (string)

  - `system.updatedAt` (string,null)
    The date and time when the token was last updated.

  - `system.updatedBy` (object)

## Response 400 fields (application/json):

  - `type` (string,null)

  - `title` (string,null)

  - `status` (integer,null)

  - `detail` (string,null)

  - `instance` (string,null)

  - `errors` (object)

## Response 401 fields (application/json):

  - `type` (string,null)

  - `title` (string,null)

  - `status` (integer,null)

  - `detail` (string,null)

  - `instance` (string,null)


