Need help with your APIs? I offer API discovery, governance & evangelism services. Explore services →
API Evangelist API Evangelist
Discovery
Learnings
Guidance
Toolbox
Alignment
API Evangelist LLC

Unleash Environments API

Create, update, delete, enable or disable [environments](https://docs.getunleash.io/concepts/environments) for this Unleash instance.

Unleash Environments API is one of 36 APIs that Unleash publishes on the APIs.io network, described by a machine-readable OpenAPI specification.

Tagged areas include Environments. The published artifact set on APIs.io includes an OpenAPI specification and API documentation.

This API exposes 11 operations across 9 paths, and defines 13 schemas. It is described by OpenAPI 3.0.3, at version 7.4.1.

Requests are made against a single base URL, https://app.unleash-instance.example.com.

11 operations 9 paths 13 schemas 1 DELETE3 GET5 POST2 PUT

Metadata

The identity and technical contract details declared by the specification.

Specification
OpenAPI 3.0.3
API Version
7.4.1
Base URL
https://app.unleash-instance.example.com
Authentication
API Key, HTTP Bearer
Resource Areas
1

Authentication & Security 2

Unleash Environments API declares 2 security schemes for authenticating requests. An API key is passed in the header as Authorization (apiKey). It accepts HTTP bearer tokens (bearerToken). By default, every request must be authenticated.

  • apiKey — API key needed to access this API
  • bearerToken — API key needed to access this API, in Bearer token format

Paths & Operations 11

Across 9 paths, the API surfaces 11 operations — 1 DELETE, 3 GET, 5 POST, 2 PUT. Each is listed below with its method, path, parameters, and response codes.

Environments 11

Create, update, delete, enable or disable [environments](https://docs.getunleash.io/concepts/environments) for this Unleash instance.

POST
/api/admin/environments
Creates a New Environment
createEnvironment body → 201400401
GET
/api/admin/environments
Get All Environments
getAllEnvironments → 200401403
POST
/api/admin/environments/validate
Validates If an Environment Name Exists
validateEnvironmentName body → 200400401
PUT
/api/admin/environments/update/{name}
Updates an Environment by Name
updateEnvironment 1 param body → 200400401
DELETE
/api/admin/environments/{name}
Deletes an Environment by Name
removeEnvironment 1 param → 200400401
GET
/api/admin/environments/{name}
Get the Environment With name
getEnvironment 1 param → 200401403404
POST
/api/admin/environments/{name}/clone
Clones an Environment
cloneEnvironment 1 param body → 200400401
GET
/api/admin/environments/project/{projectId}
Get the Environments Available to a Project
getProjectEnvironments 1 param → 200401403404
PUT
/api/admin/environments/sort-order
Update Environment Sort Orders
updateSortOrder body → 200401403404
POST
/api/admin/environments/{name}/on
Toggle the Environment With name on
toggleEnvironmentOn 1 param → 204401403404
POST
/api/admin/environments/{name}/off
Toggle the Environment With name Off
toggleEnvironmentOff 1 param → 204401403404

Schemas 13

The contract defines 13 schemas that model the data the API accepts and returns. The most detailed are featureStrategySchema (10 properties), environmentProjectSchema (10 properties), environmentSchema (9 properties), constraintSchema (6 properties). Each schema is shown below with its type and property counts.

constraintSchema
object
A strategy constraint. For more information, refer to [the strategy constraint reference documentation](https://docs.getunleash.io/concepts/activation-strategi…
6 properties 2 required
sortOrderSchema
object
A map of object IDs and their corresponding sort orders.
environmentSchema
object
A definition of the project environment
9 properties 5 required
parametersSchema
object
A list of parameters for a strategy
nameSchema
object
An object with a name
1 property 1 required
updateEnvironmentSchema
object
Data used to update an [environment](https://docs.getunleash.io/concepts/environments).
3 properties
strategyVariantSchema
object
This is an experimental property. It may change or be removed as we work on it. Please don't depend on it yet. A strategy variant allows you to attach any data…
5 properties 4 required
featureStrategySchema
object
A single activation strategy configuration schema for a feature
10 properties 1 required
environmentsSchema
object
A versioned list of environments
2 properties 2 required
cloneEnvironmentSchema
object
Data used to clone an environment.
4 properties 2 required
environmentProjectSchema
object
Describes a project's configuration in a given environment.
10 properties 5 required
createEnvironmentSchema
object
Data required to create a new [environment](https://docs.getunleash.io/concepts/environments)
5 properties 2 required
environmentsProjectSchema
object
Environments defined for a given project
2 properties 2 required

Specification

The full machine-readable OpenAPI contract behind this narrative.

Source

unleash-environments-api-openapi.yml Raw ↑

Other APIs Unleash publishes across the network.

Unleash Client API
Unleash Addons API
Unleash Admin UI API
Unleash API tokens API
Unleash Archive API
Unleash Auth API
Unleash Banners API
Unleash Change Requests API
Unleash Context API
Unleash Dependencies API
Unleash Events API
Unleash Feature Types API