---
title: "List organization secrets"
method: GET
path: "/orgs/{org}/codespaces/secrets"
tags: ["codespaces"]
---

# List organization secrets

`GET /orgs/{org}/codespaces/secrets`

Lists all Codespaces development environment secrets available at the organization-level without revealing their encrypted
values.

OAuth app tokens and personal access tokens (classic) need the `admin:org` scope to use this endpoint.

## Path parameters

- `org` string, required

## Query parameters

- `per_page` integer
- `page` integer

## Response `200`

Response

- object
  - `total_count` integer, required
  - `secrets` CodespacesOrgSecret[], required
    - `name` string, required — The name of the secret
    - `created_at` string, date-time, required — The date and time at which the secret was created, in ISO 8601 format':' YYYY-MM-DDTHH:MM:SSZ.
    - `updated_at` string, date-time, required — The date and time at which the secret was created, in ISO 8601 format':' YYYY-MM-DDTHH:MM:SSZ.
    - `visibility` 'all' | 'private' | 'selected', required — The type of repositories in the organization that the secret is visible to
    - `selected_repositories_url` string, uri — The API URL at which the list of repositories this secret is visible to can be retrieved

---

[API](https://skmtc.net/github/apis/github-v3-rest-api-2.md) · [All operations](https://skmtc.net/github/apis/github-v3-rest-api-2/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/github/github-v3-rest-api-2/versions/8ae6d0c8716e/schema)
