All Products
Search
Document Center

Edge Security Acceleration:UpdateEnvironment

Last Updated:Jul 16, 2026

Updates an environment.

Try it now

Try this API in OpenAPI Explorer, no manual signing needed. Successful calls auto-generate SDK code matching your parameters. Download it with built-in credential security for local usage.

Test

RAM authorization

No authorization for this operation. If you encounter issues with this operation, contact technical support.

Request parameters

Parameter

Type

Required

Description

Example

SiteId

integer

Yes

The site ID. You can call the ListSites operation to obtain the site ID.

33993121955****

EnvironmentName

string

Yes

The environment name.

默认环境

Rule

string

Yes

The Wireshark rule.

(http.host eq "duduko5.top")

ReadOnly

boolean

Yes

Specifies whether the environment is read-only.

1

NewName

string

No

The new environment name.

环境A

SiteVersion

integer

No

The new site version number. Only the environment with the highest priority can be modified.

10

Response elements

Element

Type

Description

Example

object

RequestId

string

The request ID.

52DD50C2-C381-13BD-A269-5FAEEB848ACD

Examples

Success response

JSON format

{
  "RequestId": "52DD50C2-C381-13BD-A269-5FAEEB848ACD"
}

Error codes

HTTP status code

Error code

Error message

Description

400 InvalidParameter.InvalidSiteEnvironmentName The specified site environment name is invalid. The specified site environment name is invalid.
400 OperationDenied.DefaultSiteEnvironmentUneditable The rule of the default environment is not allowed to be modified. The rule of the default environment is not allowed to be modified.
400 InvalidParameter.SiteEnvironmentRuleDuplicate The specified site environment rule is the same as an existing environment. The specified site environment rule is the same as an existing environment.
400 ServiceInvokeFailed The call to the internal service failed. The engineer is resolving the problem. Please wait a moment before trying, or contact customer service for details. Failed to call the service. Please try again later or contact customer service for details.
400 CompileRuleError Rule compilation failed, please check the rule information passed in to ensure that the rule is written according to the syntax described in the document. Rule compilation failed. Check the incoming rule configuration. For details, see the rule configuration format described in the interface document.
400 InternalException Failed to call the service. Try again later or contact technical support. Failed to call the service. Try again later or contact technical support.
400 Site.ServiceBusy This website is being configured. Try again later. This website is being configured. Try again later.
400 SiteVersion.Configuring The version is being configured. Try again later. The version is being configured. Try again later.
400 SiteVersion.NotExist The specified version is invalid or version management is not enabled for your website.Make sure that you specify a valid version and version management is enabled. Then, try again. The specified version is invalid or version management is not enabled for your website.Make sure that you specify a valid version and version management is enabled. Then, try again.
400 SiteEnvironment.Conflict The environment name or rule conflicts with an existing environment. Try again with a different environment name or rule. The environment name or rule conflicts with an existing environment. Try again with a different environment name or rule.
400 SiteEnvironment.NotExist The specified environment is invalid or version management is not enabled for your website. Make sure that you specify a valid environment name and version management is enabled. Then, try again. You have entered an invalid site version environment, or the site does not have version management enabled. Please confirm that your version environment settings are correct, and activate the version management function if necessary, and then try again.
400 SiteEnvironment.UpdateDenied Failed to promote a version for the environment. Check whether the current environment has the highest rank and whether the current environment and the next higher-ranked environment have the same version deployed. Failed to promote a version for the environment. Check whether the current environment has the highest rank and whether the current environment and the next higher-ranked environment have the same version deployed.
400 InvalidParameter.ArgValue Invalid parameter value. Check whether the value format and length meet the requirements. Invalid parameter value. Check whether the value format and length meet the requirements.

See Error Codes for a complete list.

Release notes

See Release Notes for a complete list.