# Return cPanel API tokens

This function returns a list of a cPanel account's API tokens.

Endpoint: GET /Tokens/list
Version: 11.138.0.19
Security: BasicAuth

## Response 200 fields (application/json):

  - `apiversion` (integer)
    The version of the API.
    Example: 3

  - `func` (string)
    The name of the method called.
    Example: "list"

  - `module` (string)
    The name of the module called.
    Example: "Tokens"

  - `result` (object)

  - `result.data` (array)
    An array of objects containing the account's API tokens.

  - `result.data.create_time` (integer)
    The API token's creation date and time.
    Example: 1549471343

  - `result.data.expires_at` (integer,null)
    The API token's expiration time.

* null — The API token does not expire.
    Example: 1609372800

  - `result.data.features` (array)
    The account features that the API token has access to.

* An empty array — The API token has full access.
    Example: []

  - `result.data.has_full_access` (integer)
    Whether the API token has full access to the account's features.

* 1 — The API token has full access to the account's features.
* 0 — The API token does not have full access to the
account's features.
    Enum: 1, 0

  - `result.data.name` (string)
    The API token's name.
    Example: "exampletoken"

  - `result.data.readonly` (integer)
    Whether the API token is restricted to read-only operations.

* 1 — The API token may only call operations classified
read-only; write operations are rejected server-side.
* 0 — The API token may perform write operations.

This property is present and 1 only for read-only tokens;
otherwise it is absent or 0. It is orthogonal to
has_full_access, which describes feature access rather than
read/write ability.
    Enum: 1, 0

  - `result.errors` (array,null)
    List of errors if the API failed.

  - `result.messages` (array,null)
    List of messages generated by the API.

  - `result.metadata` (object)

  - `result.metadata.transformed` (integer)
    Post-processing may have transformed the data.
    Enum: 1

  - `result.status` (integer)
    * 1 — Success.
* 0 — Failed. Check the errors field for more details.
    Enum: 1, 0

  - `result.warnings` (array,null)
    List of warnings generated by the API. Warnings describe non-critical failures or other problematic conditions noted while running a API.


