---
title: "Get by id"
---

> Documentation Index
> Fetch the complete documentation index at: https://docs.sureshake.com/llms.txt
> Use this file to discover all available pages before exploring further.

Path: Sureshake API › api-keys

`GET /v2/api-keys/{id}`

## Path parameters

- `id` (`api-key-get-by-id.path.id`; string, required)
  - minLength 1

## Code samples

### cURL

```bash
curl --request GET \
  --url 'https://api.sureshake.com/v2/api-keys/<id>'
```

### TypeScript

```typescript
const url = 'https://api.sureshake.com/v2/api-keys/<id>';
const options = {method: 'GET'};

fetch(url, options)
  .then(res => res.json())
  .then(json => console.log(json))
  .catch(err => console.error(err));
```

### Python

```python
import requests

url = "https://api.sureshake.com/v2/api-keys/<id>"

response = requests.get(url)

print(response.text)
```

## Responses

### 200

Default Response

#### Example

```json
{
  "data": {
    "id": "string",
    "name": "string",
    "description": "string",
    "prefix": "string",
    "lastUsedAt": "2019-08-24T14:15:22Z",
    "expiresAt": "2019-08-24T14:15:22Z",
    "permissions": [
      "read"
    ],
    "capabilities": [],
    "rateLimit": 0,
    "usageCount": 0,
    "createdAt": "2019-08-24T14:15:22Z",
    "status": "string"
  },
  "meta": {
    "timestamp": "2019-08-24T14:15:22Z"
  }
}
```

- `data` (`api-key-get-by-id.response.200.data`; object, required)
  - `id` (`api-key-get-by-id.response.200.data.id`; string, required)
    - minLength 1
  - `name` (`api-key-get-by-id.response.200.data.name`; string, required)
  - `prefix` (`api-key-get-by-id.response.200.data.prefix`; string, required)
  - `permissions` (`api-key-get-by-id.response.200.data.permissions`; array<string>, required)
    - one of `"read"`, `"write"`, `"admin"`
  - `usageCount` (`api-key-get-by-id.response.200.data.usageCount`; number, required)
    - min 0
  - `createdAt` (`api-key-get-by-id.response.200.data.createdAt`; string, required)
    - format `date-time`
  - `status` (`api-key-get-by-id.response.200.data.status`; string, required)
  - `description` (`api-key-get-by-id.response.200.data.description`; string, optional, nullable)
  - `lastUsedAt` (`api-key-get-by-id.response.200.data.lastUsedAt`; string, optional, nullable)
    - format `date-time`
  - `expiresAt` (`api-key-get-by-id.response.200.data.expiresAt`; string, optional, nullable)
    - format `date-time`
  - `capabilities` (`api-key-get-by-id.response.200.data.capabilities`; array<string>, optional)
    - one of `"entities.ingest"`, `"entities.enrich"`, `"entities.profile.read"`, `"entities.profile.propose"`, `"entities.profile.review"`, `"entities.identity.resolve"`, `"portfolio.links.read"`, `"portfolio.links.review"`, `"entities.publish"`, `"prospecting.observations.submit"`, `"prospecting.observations.read"`, `"prospecting.contacts.read"`, `"prospecting.drafts.write"`, `"attestations.events.submit"`, `"attestations.sow.submit"`, `"attestations.nda.submit"`, `"attestations.documents.sign"`, `"attestations.links.propose"`, `"admin.mcp"`; default `[]`
  - `rateLimit` (`api-key-get-by-id.response.200.data.rateLimit`; number, optional, nullable)
- `meta` (`api-key-get-by-id.response.200.meta`; object, optional)
  - `timestamp` (`api-key-get-by-id.response.200.meta.timestamp`; string, required)
    - format `date-time`

### 400

Default Response

#### Example

```json
{
  "error": {
    "code": "string",
    "message": "string",
    "details": null,
    "traceId": "string"
  }
}
```

- `error` (`api-key-get-by-id.response.400.error`; object, required)
  - `code` (`api-key-get-by-id.response.400.error.code`; string, required) — Machine-readable error code (e.g., NOT_FOUND)
  - `message` (`api-key-get-by-id.response.400.error.message`; string, required) — Human-readable error message
  - `details` (`api-key-get-by-id.response.400.error.details`; unknown, optional) — Optional structured error details
  - `traceId` (`api-key-get-by-id.response.400.error.traceId`; string, optional) — Unique ID for log correlation

### 401

Default Response

#### Example

```json
{
  "error": {
    "code": "string",
    "message": "string",
    "details": null,
    "traceId": "string"
  }
}
```

- `error` (`api-key-get-by-id.response.401.error`; object, required)
  - `code` (`api-key-get-by-id.response.401.error.code`; string, required) — Machine-readable error code (e.g., NOT_FOUND)
  - `message` (`api-key-get-by-id.response.401.error.message`; string, required) — Human-readable error message
  - `details` (`api-key-get-by-id.response.401.error.details`; unknown, optional) — Optional structured error details
  - `traceId` (`api-key-get-by-id.response.401.error.traceId`; string, optional) — Unique ID for log correlation

### 403

Default Response

#### Example

```json
{
  "error": {
    "code": "string",
    "message": "string",
    "details": null,
    "traceId": "string"
  }
}
```

- `error` (`api-key-get-by-id.response.403.error`; object, required)
  - `code` (`api-key-get-by-id.response.403.error.code`; string, required) — Machine-readable error code (e.g., NOT_FOUND)
  - `message` (`api-key-get-by-id.response.403.error.message`; string, required) — Human-readable error message
  - `details` (`api-key-get-by-id.response.403.error.details`; unknown, optional) — Optional structured error details
  - `traceId` (`api-key-get-by-id.response.403.error.traceId`; string, optional) — Unique ID for log correlation

### 404

Default Response

#### Example

```json
{
  "error": {
    "code": "string",
    "message": "string",
    "details": null,
    "traceId": "string"
  }
}
```

- `error` (`api-key-get-by-id.response.404.error`; object, required)
  - `code` (`api-key-get-by-id.response.404.error.code`; string, required) — Machine-readable error code (e.g., NOT_FOUND)
  - `message` (`api-key-get-by-id.response.404.error.message`; string, required) — Human-readable error message
  - `details` (`api-key-get-by-id.response.404.error.details`; unknown, optional) — Optional structured error details
  - `traceId` (`api-key-get-by-id.response.404.error.traceId`; string, optional) — Unique ID for log correlation

### 409

Default Response

#### Example

```json
{
  "error": {
    "code": "string",
    "message": "string",
    "details": null,
    "traceId": "string"
  }
}
```

- `error` (`api-key-get-by-id.response.409.error`; object, required)
  - `code` (`api-key-get-by-id.response.409.error.code`; string, required) — Machine-readable error code (e.g., NOT_FOUND)
  - `message` (`api-key-get-by-id.response.409.error.message`; string, required) — Human-readable error message
  - `details` (`api-key-get-by-id.response.409.error.details`; unknown, optional) — Optional structured error details
  - `traceId` (`api-key-get-by-id.response.409.error.traceId`; string, optional) — Unique ID for log correlation

### 500

Default Response

#### Example

```json
{
  "error": {
    "code": "string",
    "message": "string",
    "details": null,
    "traceId": "string"
  }
}
```

- `error` (`api-key-get-by-id.response.500.error`; object, required)
  - `code` (`api-key-get-by-id.response.500.error.code`; string, required) — Machine-readable error code (e.g., NOT_FOUND)
  - `message` (`api-key-get-by-id.response.500.error.message`; string, required) — Human-readable error message
  - `details` (`api-key-get-by-id.response.500.error.details`; unknown, optional) — Optional structured error details
  - `traceId` (`api-key-get-by-id.response.500.error.traceId`; string, optional) — Unique ID for log correlation


Source: https://docs.sureshake.com/reference/api-keys/retrieve/index.md
