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

# Get an environment API key

> Retrieve an Environment API key, including its secret.

<Info>
  Requires an [Account API key](/docs/reference/backend/http-api/api-keys#account-api-keys) with the `account:environments:api_keys:read` scope.
</Info>

Retrieves an Environment API key, including its secret.

<ResponseExample>
  ```json Example Response theme={null}
  {
    "data": {
      "id": 456,
      "uuid": "123e4567-e89b-12d3-a456-426614174001",
      "display_name": "provisioned-ci",
      "scopes": ["environment:*"],
      "secret": "<YOUR-ENVIRONMENT-API-KEY>",
      "last_used_at": null,
      "created_at": "2026-08-18T12:00:00.000Z"
    }
  }
  ```
</ResponseExample>


## OpenAPI

````yaml GET /environments/{environmentUuid}/api-keys/{keyUuid}
openapi: 3.1.0
info:
  title: Nango API
  description: Nango API specs used to authorize & sync data with external APIs.
  version: 1.0.0
servers:
  - url: https://api.nango.dev
    description: Production server
  - url: http://localhost:3003
    description: Local server
security:
  - bearerAuth: []
externalDocs:
  url: https://nango.dev/docs/reference/backend/http-api/authentication
paths:
  /environments/{environmentUuid}/api-keys/{keyUuid}:
    get:
      summary: Get an environment API key
      description: Retrieve an Environment API key, including its secret.
      parameters:
        - name: environmentUuid
          in: path
          required: true
          description: Environment UUID that owns the key.
          schema:
            type: string
            format: uuid
          example: 123e4567-e89b-12d3-a456-426614174000
        - name: keyUuid
          in: path
          required: true
          description: API-key UUID.
          schema:
            type: string
            format: uuid
          example: 123e4567-e89b-12d3-a456-426614174001
      responses:
        '200':
          description: Successfully retrieved the Environment API key
          content:
            application/json:
              schema:
                type: object
                required:
                  - data
                properties:
                  data:
                    type: object
                    required:
                      - id
                      - uuid
                      - display_name
                      - scopes
                      - secret
                      - last_used_at
                      - created_at
                    properties:
                      id:
                        type: integer
                        example: 456
                      uuid:
                        type: string
                        format: uuid
                        example: 123e4567-e89b-12d3-a456-426614174001
                      display_name:
                        type: string
                        example: provisioned-ci
                      scopes:
                        type: array
                        items:
                          type: string
                      secret:
                        type: string
                        description: The Environment API-key secret.
                      last_used_at:
                        type:
                          - string
                          - 'null'
                        format: date-time
                      created_at:
                        type: string
                        format: date-time
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          $ref: '#/components/responses/Forbidden'
        '404':
          $ref: '#/components/responses/NotFound'
        '500':
          $ref: '#/components/responses/ServerError'
components:
  responses:
    BadRequest:
      description: Bad request
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/StdError'
    Unauthorized:
      description: Unauthorized
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/StdError'
    Forbidden:
      description: Forbidden
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/StdError'
    NotFound:
      description: Not Found
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/StdError'
    ServerError:
      description: Server error
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/StdError'
  schemas:
    StdError:
      type: object
      additionalProperties: false
      properties:
        error:
          type: object
          additionalProperties: false
          required:
            - code
          properties:
            code:
              type: string
            message:
              type: string
            errors:
              type: array
              items:
                type: object
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: >-
        An Environment API key from your Nango environment, or an Account API
        key for account-level endpoints.

````