Skip to main content
GET /v1/environments Lists environments under the current account with cursor pagination. Archived environments are excluded by default.

Headers

HeaderRequiredDescription
AuthorizationYesBearer <PAT>

Query parameters

ParameterTypeRequiredDefaultDescription
limitintegerNo20Items per page. Must be positive; values above 100 are capped at 100
after_idstringNo-Cursor; returns records after this ID in the current descending ID order. Do not combine with before_id
before_idstringNo-Cursor; returns records before this ID in the current descending ID order. Do not combine with after_id
include_archivedbooleanNofalseSet to true to include archived environments
created_at[gte]stringNo-Include environments created at or after this RFC 3339 timestamp
created_at[lte]stringNo-Include environments created at or before this RFC 3339 timestamp
See Pagination for cursor semantics.

Example request

curl -s -X GET 'https://api.qoder.com/api/v1/cloud/environments' \
  -H "Authorization: Bearer $QODER_PAT"

Example response

HTTP 200 OK
{
  "data": [
    {
      "id": "env_019e3bb39b6774d8878cd0b9d237574b",
      "type": "environment",
      "name": "doc-test-env",
      "description": "",
      "status": "ready",
      "config": {
        "type": "cloud",
        "networking": {
          "type": "limited"
        },
        "packages": {
          "apt": [
            "curl"
          ]
        }
      },
      "metadata": {},
      "archived": false,
      "archived_at": null,
      "created_at": "2026-05-18T15:28:07.017808Z",
      "updated_at": "2026-05-18T15:28:07.017808Z"
    },
    {
      "id": "env_019e2590d33f711fabf42f2857cecd8a",
      "type": "environment",
      "name": "default",
      "description": "",
      "status": "ready",
      "config": {
        "type": "cloud",
        "networking": {
          "type": "limited"
        },
        "packages": {}
      },
      "metadata": {},
      "archived": false,
      "archived_at": null,
      "created_at": "2026-05-14T08:18:28.800813Z",
      "updated_at": "2026-05-14T08:18:28.800813Z"
    }
  ],
  "first_id": "env_019e3bb39b6774d8878cd0b9d237574b",
  "has_more": false,
  "last_id": "env_019e2590d33f711fabf42f2857cecd8a"
}

Response fields

FieldTypeDescription
dataarray of Environment objectEnvironments on the current page
first_idstringID of the first record on this page
last_idstringID of the last record on this page
has_morebooleanWhether more records remain

Errors

HTTPTypeTrigger
400invalid_request_errorlimit is not a positive integer
400invalid_request_errorBoth before_id and after_id were provided
400invalid_request_errorcreated_at[gte] or created_at[lte] is not RFC 3339
401authentication_errorPAT invalid or expired
403permission_errorNot authorized for this resource
See Errors for the full error envelope.

Notes

  • Records are returned in descending ID order by default.
  • Archived environments do not appear in the default listing. Pass include_archived=true to include them.
  • Pagination is cursor-based; offset-based pagination is not supported.

Cloud environment setup

Choose the container, network, and dependencies your agent runs in.