az apic environment
Note
This reference is part of the apic-extension extension for the Azure CLI (version 2.57.0 or higher). The extension will automatically install the first time you run an az apic environment command. Learn more about extensions.
Commands to manage environments in API Center.
Commands
Name | Description | Type | Status |
---|---|---|---|
az apic environment create |
Create a new environment or update an existing environment. |
Extension | GA |
az apic environment delete |
Delete the environment. |
Extension | GA |
az apic environment list |
List a collection of environments. |
Extension | GA |
az apic environment show |
Get details of the environment. |
Extension | GA |
az apic environment update |
Update existing environment. |
Extension | GA |
az apic environment create
Create a new environment or update an existing environment.
az apic environment create --environment-id
--resource-group
--service-name
--title
--type {development, production, staging, testing}
[--custom-properties]
[--description]
[--onboarding]
[--server]
Examples
Create environment
az apic environment create -g api-center-test -n contosoeuap --environment-id public --title "Public cloud" --type "development"
Required Parameters
The id of the environment.
Name of resource group. You can configure the default group using az configure --defaults group=<name>
.
The name of Azure API Center service.
Environment title.
Property | Value |
---|---|
Parameter group: | Properties Arguments |
Environment type.
Property | Value |
---|---|
Parameter group: | Properties Arguments |
Accepted values: | development, production, staging, testing |
Optional Parameters
The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.
The custom metadata defined for API catalog entities. Support shorthand-syntax, json-file and yaml-file. Try "??" to show more.
Property | Value |
---|---|
Parameter group: | Properties Arguments |
Environment description.
Property | Value |
---|---|
Parameter group: | Properties Arguments |
Provide onboarding documentation related to your environment, e.g. {developerPortalUri:['https://developer.contoso.com'],instructions:'instructions markdown'} Support shorthand-syntax, json-file and yaml-file. Try "??" to show more.
Property | Value |
---|---|
Parameter group: | Properties Arguments |
Server information of the environment. Support shorthand-syntax, json-file and yaml-file. Try "??" to show more.
Property | Value |
---|---|
Parameter group: | Properties Arguments |
Global Parameters
Increase logging verbosity to show all debug logs.
Property | Value |
---|---|
Default value: | False |
Show this help message and exit.
Only show errors, suppressing warnings.
Property | Value |
---|---|
Default value: | False |
Output format.
Property | Value |
---|---|
Default value: | json |
Accepted values: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath query string. See http://jmespath.org/ for more information and examples.
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID
.
Increase logging verbosity. Use --debug for full debug logs.
Property | Value |
---|---|
Default value: | False |
az apic environment delete
Delete the environment.
az apic environment delete [--environment-id]
[--ids]
[--resource-group]
[--service-name]
[--subscription]
[--yes]
Examples
Delete environment
az apic environment delete -g api-center-test -n contosoeuap --environment-id public
Optional Parameters
The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.
The id of the environment.
Property | Value |
---|---|
Parameter group: | Resource Id Arguments |
One or more resource IDs (space-delimited). It should be a complete resource ID containing all information of 'Resource Id' arguments. You should provide either --ids or other 'Resource Id' arguments.
Property | Value |
---|---|
Parameter group: | Resource Id Arguments |
Name of resource group. You can configure the default group using az configure --defaults group=<name>
.
Property | Value |
---|---|
Parameter group: | Resource Id Arguments |
The name of Azure API Center service.
Property | Value |
---|---|
Parameter group: | Resource Id Arguments |
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID
.
Property | Value |
---|---|
Parameter group: | Resource Id Arguments |
Do not prompt for confirmation.
Property | Value |
---|---|
Default value: | False |
Global Parameters
Increase logging verbosity to show all debug logs.
Property | Value |
---|---|
Default value: | False |
Show this help message and exit.
Only show errors, suppressing warnings.
Property | Value |
---|---|
Default value: | False |
Output format.
Property | Value |
---|---|
Default value: | json |
Accepted values: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath query string. See http://jmespath.org/ for more information and examples.
Increase logging verbosity. Use --debug for full debug logs.
Property | Value |
---|---|
Default value: | False |
az apic environment list
List a collection of environments.
az apic environment list --resource-group
--service-name
[--filter]
[--max-items]
[--next-token]
Examples
List environments
az apic environment list -g api-center-test -n contosoeuap
Required Parameters
Name of resource group. You can configure the default group using az configure --defaults group=<name>
.
The name of Azure API Center service.
Optional Parameters
The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.
OData filter parameter.
Total number of items to return in the command's output. If the total number of items available is more than the value specified, a token is provided in the command's output. To resume pagination, provide the token value in --next-token
argument of a subsequent command.
Property | Value |
---|---|
Parameter group: | Pagination Arguments |
Token to specify where to start paginating. This is the token value from a previously truncated response.
Property | Value |
---|---|
Parameter group: | Pagination Arguments |
Global Parameters
Increase logging verbosity to show all debug logs.
Property | Value |
---|---|
Default value: | False |
Show this help message and exit.
Only show errors, suppressing warnings.
Property | Value |
---|---|
Default value: | False |
Output format.
Property | Value |
---|---|
Default value: | json |
Accepted values: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath query string. See http://jmespath.org/ for more information and examples.
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID
.
Increase logging verbosity. Use --debug for full debug logs.
Property | Value |
---|---|
Default value: | False |
az apic environment show
Get details of the environment.
az apic environment show [--environment-id]
[--ids]
[--resource-group]
[--service-name]
[--subscription]
Examples
Show environment details
az apic environment show -g api-center-test -n contosoeuap --environment-id public
Optional Parameters
The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.
The id of the environment.
Property | Value |
---|---|
Parameter group: | Resource Id Arguments |
One or more resource IDs (space-delimited). It should be a complete resource ID containing all information of 'Resource Id' arguments. You should provide either --ids or other 'Resource Id' arguments.
Property | Value |
---|---|
Parameter group: | Resource Id Arguments |
Name of resource group. You can configure the default group using az configure --defaults group=<name>
.
Property | Value |
---|---|
Parameter group: | Resource Id Arguments |
The name of Azure API Center service.
Property | Value |
---|---|
Parameter group: | Resource Id Arguments |
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID
.
Property | Value |
---|---|
Parameter group: | Resource Id Arguments |
Global Parameters
Increase logging verbosity to show all debug logs.
Property | Value |
---|---|
Default value: | False |
Show this help message and exit.
Only show errors, suppressing warnings.
Property | Value |
---|---|
Default value: | False |
Output format.
Property | Value |
---|---|
Default value: | json |
Accepted values: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath query string. See http://jmespath.org/ for more information and examples.
Increase logging verbosity. Use --debug for full debug logs.
Property | Value |
---|---|
Default value: | False |
az apic environment update
Update existing environment.
az apic environment update [--add]
[--custom-properties]
[--description]
[--environment-id]
[--force-string {0, 1, f, false, n, no, t, true, y, yes}]
[--ids]
[--onboarding]
[--remove]
[--resource-group]
[--server]
[--service-name]
[--set]
[--subscription]
[--title]
[--type {development, production, staging, testing}]
Examples
Update environment
az apic environment update -g api-center-test -n contosoeuap --environment-id public --title "Public cloud"
Optional Parameters
The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.
Add an object to a list of objects by specifying a path and key value pairs. Example: --add property.listProperty <key=value, string or JSON string>
.
Property | Value |
---|---|
Parameter group: | Generic Update Arguments |
The custom metadata defined for API catalog entities. Support shorthand-syntax, json-file and yaml-file. Try "??" to show more.
Property | Value |
---|---|
Parameter group: | Properties Arguments |
Description.
Property | Value |
---|---|
Parameter group: | Properties Arguments |
The id of the environment.
Property | Value |
---|---|
Parameter group: | Resource Id Arguments |
When using 'set' or 'add', preserve string literals instead of attempting to convert to JSON.
Property | Value |
---|---|
Parameter group: | Generic Update Arguments |
Accepted values: | 0, 1, f, false, n, no, t, true, y, yes |
One or more resource IDs (space-delimited). It should be a complete resource ID containing all information of 'Resource Id' arguments. You should provide either --ids or other 'Resource Id' arguments.
Property | Value |
---|---|
Parameter group: | Resource Id Arguments |
{developerPortalUri:['https://developer.contoso.com'],instructions:'instructions markdown'} Support shorthand-syntax, json-file and yaml-file. Try "??" to show more.
Property | Value |
---|---|
Parameter group: | Properties Arguments |
Remove a property or an element from a list. Example: --remove property.list <indexToRemove>
OR --remove propertyToRemove
.
Property | Value |
---|---|
Parameter group: | Generic Update Arguments |
Name of resource group. You can configure the default group using az configure --defaults group=<name>
.
Property | Value |
---|---|
Parameter group: | Resource Id Arguments |
Server information of the environment. Support shorthand-syntax, json-file and yaml-file. Try "??" to show more.
Property | Value |
---|---|
Parameter group: | Properties Arguments |
The name of Azure API Center service.
Property | Value |
---|---|
Parameter group: | Resource Id Arguments |
Update an object by specifying a property path and value to set. Example: --set property1.property2=<value>
.
Property | Value |
---|---|
Parameter group: | Generic Update Arguments |
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID
.
Property | Value |
---|---|
Parameter group: | Resource Id Arguments |
Environment title.
Property | Value |
---|---|
Parameter group: | Properties Arguments |
Environment type.
Property | Value |
---|---|
Parameter group: | Properties Arguments |
Accepted values: | development, production, staging, testing |
Global Parameters
Increase logging verbosity to show all debug logs.
Property | Value |
---|---|
Default value: | False |
Show this help message and exit.
Only show errors, suppressing warnings.
Property | Value |
---|---|
Default value: | False |
Output format.
Property | Value |
---|---|
Default value: | json |
Accepted values: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath query string. See http://jmespath.org/ for more information and examples.
Increase logging verbosity. Use --debug for full debug logs.
Property | Value |
---|---|
Default value: | False |