---
title: "List the organization's API keys in the credential's mode, newest first, revoked ones included. The secret is never shown again"
method: GET
path: "/v1/api-keys"
---

# List the organization's API keys in the credential's mode, newest first, revoked ones included. The secret is never shown again

`GET /v1/api-keys`

## Request

- Base URL: `https://api.evictionsapi.com`
- URL: `https://api.evictionsapi.com/v1/api-keys`
- Auth: one of:
  - HTTP bearer
  - HTTP bearer

## Response `200`

The keys, each with the last four characters of its secret (null for a key created before they were recorded) and when it was revoked, if it was.

- object
  - `items` object[], required
    - `id` string, required
    - `mode` 'test' | 'live', required
    - `name` string, nullable, required: What the key is for, as named when it was created; null without a name.
    - `createdAt` string, date-time, required
    - `lastFour` string, nullable, required
    - `revokedAt` string, date-time, nullable, required

## Other responses

- `400`: The request is invalid.
- `401`: The credential is missing or invalid.
- `403`: The credential is not allowed to do this (`forbidden`). For a signed-in session: `permission_denied`, the person's role in the organization lacks the permission this needs (ask an owner); `no_organization`, the person belongs to no organization yet (start one with `POST /v1/me/organizations` or accept an invitation).
- `404`: Not found.
- `409`: The request conflicts with the current state: for a case, it is not in a state that allows this, or its details were erased (`erased`); for an API key, a limit or the key in use.
- `422`: The case did not pass a check.

---

[API](https://skmtc.dev/evictionsapi/apis/evictions-api.md) · [All operations](https://skmtc.dev/evictionsapi/apis/evictions-api/llms.txt) · [OpenAPI document](https://skmtc.dev/evictionsapi/apis/evictions-api/revisions/28459213a1a3?raw)
