---
title: View secret keys
description: View secret keys using the influx CLI or the InfluxDB API.
url: https://docs.influxdata.com/influxdb/v2/admin/secrets/view/
estimated_tokens: 411
product: InfluxDB OSS v2
version: v2
publisher: InfluxData
canonical: https://docs.influxdata.com/influxdb/v2/admin/secrets/view/
date: '2023-11-06T15:53:12-07:00'
lastmod: '2023-11-06T15:53:12-07:00'
---

This page documents an earlier version of InfluxDB OSS.[InfluxDB 3 Core](/influxdb3/core/) is the latest stable version.

#### API token hashing is enabled by default in InfluxDB OSS 2.9.0

Stronger token security: tokens are stored as hashes on disk, so a
copy of the database file doesn’t expose usable tokens. Existing
tokens are hashed on first startup and the original strings can’t
be recovered afterward — **capture any plaintext tokens you still
need before you upgrade**.

For more information, see [Token hashing](/influxdb/v2/admin/tokens/#token-hashing).

View secret keys using the `influx` command line interface (CLI) or the InfluxDB API.

* [View secret keys using the influx CLI](#view-secret-keys-using-the-influx-cli)
* [View secret keys using the InfluxDB API](#view-secret-keys-using-the-influxdb-api)

## View secret keys using the influx CLI

Use the [`influx secret list` command](/influxdb/v2/reference/cli/influx/secret/list/)to list your organization’s secret keys.

```sh
influx secret list
```

## View secret keys using the InfluxDB API

Use the `GET` request method and the InfluxDB `/orgs/{orgID}/secrets` API endpoint
to view your organization’s secrets keys.

**Include the following:**

* Your [organization ID](/influxdb/v2/admin/organizations/view-orgs/#view-your-organization-id) in the request URL
* Your [API token](/influxdb/v2/admin/tokens/view-tokens/) in the `Authorization` header

```sh
curl --request GET http://localhost:8086/api/v2/orgs/<org-id>/secrets \
  --header 'Authorization: Token YOURAUTHTOKEN'
```

[secrets](/influxdb/v2/tags/secrets/)[security](/influxdb/v2/tags/security/)
