---
title: "Get Redis connection credentials"
method: GET
path: "/api/v1/redis-databases/{databaseId}/connection"
tags: ["Redis Databases"]
---

# Get Redis connection credentials

`GET /api/v1/redis-databases/{databaseId}/connection`

## Request

- Base URL: `https://app.khotan.com`
- URL: `https://app.khotan.com/api/v1/redis-databases/{databaseId}/connection`
- Auth: one of:
  - HTTP bearer
  - API key in header `x-api-key`

Returns the rediss:// URI plus the REST URL and read/write and read-only REST tokens for a ready Redis database. These credentials grant access to the database; treat them as secrets. Responds 404 until the database is ready.

## Path parameters

- `databaseId` string, required

## Response `200`

The Redis connection credentials for the ready database.

- object
  - `restUrl` string, uri, required
  - `restToken` string, required
  - `readOnlyRestToken` string, required
  - `redisUrl` string, uri, required

## Other responses

- `401`: Authentication is missing or invalid.
- `404`: The resource was not found.
- `429`: Too many requests; retry after the indicated delay.

---

[API](https://skmtc.dev/khotan/apis/khotan-api.md) - [All operations](https://skmtc.dev/khotan/apis/khotan-api/llms.txt) - [OpenAPI document](https://skmtc.dev/khotan/apis/khotan-api/revisions/90b512a53e42?raw)
