Environments - Get Environment Definition

Get an environment definition from a catalog.

GET {endpoint}/projects/{projectName}/catalogs/{catalogName}/environmentDefinitions/{definitionName}?api-version=2025-02-01

URI Parameters

Name In Required Type Description
catalogName
path True

string

Name of the catalog.

Regex pattern: ^[a-zA-Z0-9][a-zA-Z0-9-_.]{2,62}$

definitionName
path True

string

Name of the environment definition.

Regex pattern: ^[a-zA-Z0-9][a-zA-Z0-9-_.]{2,62}$

endpoint
path True

string

uri

The DevCenter-specific URI to operate on.

projectName
path True

string

Name of the project.

Regex pattern: ^[a-zA-Z0-9][a-zA-Z0-9-_.]{2,62}$

api-version
query True

string

The API version to use for this operation.

Responses

Name Type Description
200 OK

EnvironmentDefinition

The request has succeeded.

Other Status Codes

Azure.Core.Foundations.ErrorResponse

An unexpected error response.

Headers

x-ms-error-code: string

Security

OAuth2Auth

Type: oauth2
Flow: implicit
Authorization URL: https://login.microsoftonline.com/common/oauth2/authorize

Scopes

Name Description
https://devcenter.azure.com/.default

Examples

Get an environment definition from a catalog.

Sample request

GET https://8a40af38-3b4c-4672-a6a4-5e964b1870ed-contosodevcenter.centralus.devcenter.azure.com/projects/myProject/catalogs/myCatalog/environmentDefinitions/foo?api-version=2025-02-01

Sample response

{
  "uri": "https://8a40af38-3b4c-4672-a6a4-5e964b1870ed-contosodevcenter.centralus.devcenter.azure.com/projects/myProject/catalogs/myCatalog/environmentDefinitions/foo",
  "id": "/projects/myProject/catalogs/myCatalog/environmentDefinitions/foo",
  "name": "foo",
  "catalogName": "myCatalog",
  "description": "This environment definition is just for example purposes.",
  "parameters": [
    {
      "id": "functionAppRuntime",
      "name": "Function App Runtime",
      "type": "string",
      "required": true,
      "default": "dotnet",
      "allowed": [
        "node",
        "dotnet",
        "java"
      ]
    },
    {
      "id": "storageAccountType",
      "name": "Storage Account Type",
      "type": "string",
      "required": true,
      "default": "Standard_LRS",
      "allowed": [
        "Standard_LRS",
        "Standard_GRS",
        "Standard_RAGRS"
      ]
    },
    {
      "id": "httpsOnly",
      "name": "HTTPS only",
      "type": "boolean",
      "default": "true",
      "readOnly": true,
      "required": true
    }
  ],
  "parametersSchema": "{\"type\":\"object\",\"properties\":{\"functionAppRuntime\":{\"$id\":\"functionAppRuntime\",\"value\":\"dotnet\",\"displayName\":\"Function App Runtime\",\"type\":\"string\",\"enum\":[\"node\",\"dotnet\",\"java\"]},\"storageAccountType\":{\"$id\":\"storageAccountType\",\"value\":\"Standard_LRS\",\"displayName\":\"Storage Account Type\",\"type\":\"string\",\"enum\":[\"Standard_LRS\",\"Standard_GRS\",\"Standard_RAGRS\"]},\"httpsOnly\":{\"$id\":\"httpsOnly\",\"value\":true,\"displayName\":\"HTTPS only\",\"type\":\"boolean\"}},\"required\":[\"functionAppRuntime\",\"storageAccountType\"]}",
  "templatePath": "azuredeploy.json"
}

Definitions

Name Description
Azure.Core.Foundations.Error

The error object.

Azure.Core.Foundations.ErrorResponse

A response containing error details.

Azure.Core.Foundations.InnerError

An object containing more specific information about the error. As per Microsoft One API guidelines - https://github.com/Microsoft/api-guidelines/blob/vNext/Guidelines.md#7102-error-condition-responses.

EnvironmentDefinition

An environment definition.

EnvironmentDefinitionParameter

Properties of an Environment Definition parameter

ParameterType

The type of data a parameter accepts.

Azure.Core.Foundations.Error

The error object.

Name Type Description
code

string

One of a server-defined set of error codes.

details

Azure.Core.Foundations.Error[]

An array of details about specific errors that led to this reported error.

innererror

Azure.Core.Foundations.InnerError

An object containing more specific information than the current object about the error.

message

string

A human-readable representation of the error.

target

string

The target of the error.

Azure.Core.Foundations.ErrorResponse

A response containing error details.

Name Type Description
error

Azure.Core.Foundations.Error

The error object.

Azure.Core.Foundations.InnerError

An object containing more specific information about the error. As per Microsoft One API guidelines - https://github.com/Microsoft/api-guidelines/blob/vNext/Guidelines.md#7102-error-condition-responses.

Name Type Description
code

string

One of a server-defined set of error codes.

innererror

Azure.Core.Foundations.InnerError

Inner error.

EnvironmentDefinition

An environment definition.

Name Type Description
catalogName

string

Name of the catalog.

description

string

A short description of the environment definition.

id

string

The ID of the environment definition.

name

string

Name of the environment definition.

parameters

EnvironmentDefinitionParameter[]

Input parameters passed to an environment.

parametersSchema

string

JSON schema defining the parameters object passed to an environment.

templatePath

string

Path to the Environment Definition entrypoint file.

uri

string

The unique URI of the environment definition.

EnvironmentDefinitionParameter

Properties of an Environment Definition parameter

Name Type Description
allowed

string[]

An array of allowed values.

default

string

Default value of the parameter.

description

string

Description of the parameter.

id

string

Unique ID of the parameter.

name

string

Display name of the parameter.

readOnly

boolean

Whether or not this parameter is read-only. If true, default should have a value.

required

boolean

Whether or not this parameter is required.

type

ParameterType

A string of one of the basic JSON types (number, integer, array, object, boolean, string).

ParameterType

The type of data a parameter accepts.

Value Description
array

The parameter accepts an array of values.

boolean

The parameter accepts a boolean value.

integer

The parameter accepts an integer value.

number

The parameter accepts a number value.

object

The parameter accepts an object value.

string

The parameter accepts a string value.