# Fetch the list of environments for release

Api to fetch the list of environments for release

Endpoint: GET /rmg/api/release/{releaseId}/environments
Version: 1.0
Security: x-api-key

## Path parameters:

  - `releaseId` (string, required)

## Header parameters:

  - `Harness-Account` (string, required)
    Account Identifier

## Query parameters:

  - `cursor` (string)
    Next token for fetching the environment

  - `limit` (number)
    The number of records expected

  - `searchTerm` (string)
    Optional variable to filter environments based on the given prefix

## Response 200 fields (application/json):

  - `environments` (array, required)

  - `environments.identifier` (string, required)

  - `environments.orgIdentifier` (string)

  - `environments.projectIdentifier` (string)

  - `nextRequest` (object)

  - `nextRequest.cursor` (string)

  - `nextRequest.limit` (integer)

  - `last` (boolean, required)

## Response 400 fields (application/json):

  - `message` (string, required)
    error message detail

  - `code` (string)
    canonical error code name
    Enum: "BAD_REQUEST", "UNAUTHORIZED", "FORBIDDEN", "NOT_FOUND", "INTERNAL_SERVER_ERROR"


