# List personal access tokens

From **GitHub v3 REST API**.

`GET /admin/tokens`

Lists personal access tokens for all users, including admin users.

## Parameters

### `per_page`

- Location: query
- Required: false
- Type: `integer`
- Default: `30`

Results per page (max 100)

### `page`

- Location: query
- Required: false
- Type: `integer`
- Default: `1`

Page number of the results to fetch.

## Responses

### `200`

Response

#### Headers

##### `Link`

- Type: `string`

- Example: `<https://api.github.com/resource?page=2>; rel="next", <https://api.github.com/resource?page=5>; rel="last"`

### `application/json`

- Type: `array`

```json
[
  {
    "app": {
      "client_id": "00000000000000000000",
      "name": "My personal access token",
      "url": "https://docs.github.com/enterprise/rest/reference/enterprise-admin#list-personal-access-tokens"
    },
    "created_at": "2019-04-24T21:49:02Z",
    "fingerprint": null,
    "hashed_token": "23cffb2fab1b0a62747863eba88cb9327e561f2f7a0c8661c0d9b83146cb8d45",
    "id": 2,
    "note": "My personal access token",
    "note_url": null,
    "scopes": [
      "admin:business",
      "admin:gpg_key",
      "admin:org",
      "admin:org_hook",
      "admin:pre_receive_hook",
      "admin:public_key",
      "admin:repo_hook",
      "delete_repo",
      "gist",
      "notifications",
      "repo",
      "user",
      "write:discussion"
    ],
    "token": "ghp_16C7e42F292c6912E7710c838347Ae178B4a",
    "token_last_eight": "Ae178B4a",
    "updated_at": "2019-04-24T21:49:02Z",
    "url": "https://enterprise.octocat.com/api/v3/authorizations/2"
  }
]
```

```json
{"items":{"$ref":"#/components/schemas/authorization"},"type":"array"}
```

## Request examples

### cURL

```shell
curl --request GET \
  --url {protocol}://{hostname}/api/v3/admin/tokens
```
