UpdateService

Updated at:

Upgrades a service.

Operation description

A service to be published must be approved.

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

The table below describes the authorization required to call this API. You can define it in a Resource Access Management (RAM) policy. The table's columns are detailed below:

  • Action: The actions can be used in the Action element of RAM permission policy statements to grant permissions to perform the operation.

  • API: The API that you can call to perform the action.

  • Access level: The predefined level of access granted for each API. Valid values: create, list, get, update, and delete.

  • Resource type: The type of the resource that supports authorization to perform the action. It indicates if the action supports resource-level permission. The specified resource must be compatible with the action. Otherwise, the policy will be ineffective.

    • For APIs with resource-level permissions, required resource types are marked with an asterisk (*). Specify the corresponding Alibaba Cloud Resource Name (ARN) in the Resource element of the policy.

    • For APIs without resource-level permissions, it is shown as All Resources. Use an asterisk (*) in the Resource element of the policy.

  • Condition key: The condition keys defined by the service. The key allows for granular control, applying to either actions alone or actions associated with specific resources. In addition to service-specific condition keys, Alibaba Cloud provides a set of common condition keys applicable across all RAM-supported services.

  • Dependent action: The dependent actions required to run the action. To complete the action, the RAM user or the RAM role must have the permissions to perform all dependent actions.

Action

Access level

Resource type

Condition key

Dependent action

computenestsupplier:UpdateService

update

*Service

acs:computenestsupplier:{#regionId}:{#accountId}:service/{#ServiceId}

None None

Request parameters

Parameter

Type

Required

Description

Example

RegionId

string

Yes

The region ID.

cn-hangzhou

DeployType

string

No

The deployment type. Valid values:

  • ros: Deployed through ROS.

  • terraform: Deployed through Terraform.

  • spi: Invoke the SPI to deploy.

  • operation: Deployed by using Alibaba Cloud Managed Services.

  • container: Deployed by using containers.

  • pkg: Package service.

ros

DeployMetadata

string

No

The deployment configuration information of the storage service. The stored information varies based on the deployment type. Because different deployment types use different data formats, the data is stored as a JSON string.

{\"EstimateTime\":null,\"SupplierDeployMetadata\":{\"DeployTimeout\":7200},\"EnableVnc\":false}

AlarmMetadata

string

No

The alert configuration for the service.

Note

This configuration takes effect only after an alert access policy is configured in PolicyNames.

{\"CmsTemplateId\":1162921,\"TemplateUrl\":\"https://service-info-private.oss-cn-hangzhou.aliyuncs.com/1760465342xxxxxx/template/c072ef50-6c03-4d9c-8f0e-d1c440xxxxxx.json\"}

ClientToken

string

No

The client token that ensures the idempotence of the request. Generate the value on your client to ensure that the value is unique across different requests. ClientToken supports only ASCII characters and can be up to 64 characters in length.

788E7CP0EN9D51P

ServiceId

string

Yes

The service ID.

service-1dda29c3eca648xxxxxx

ServiceType

string

No

The service type. Valid values:

  • private: Service instances for deployment in the user account.

  • managed: Service instances managed in the service provider account.

  • operation: Alibaba Cloud Managed Services instances.

  • poc: Trial service instances.

private

ServiceInfo

array<object>

No

The service details.

array<object>

No

The service details.

Locale

string

No

The service language. Valid values:

  • zh-CN: Chinese.

  • en-US: English.

zh-CN

ShortDescription

string

No

The service overview.

B is an open source distributed relational database independently designed and developed by Company A

Image

string

No

The URL of the service icon.

http://img.tidb.oss.url

Name

string

No

The service name.

Database B

LongDescriptionUrl

string

No

The URL of the detailed service description.

http://description.tidb.oss.url

Agreements

array<object>

No

The information about the service agreement documents.

object

No

The information about the service agreement documents.

Name

string

No

The name of the agreement document.

Name

Url

string

No

The URL of the agreement.

https://aliyun.com/xxxxxxxx.html

Softwares

array<object>

No

The information about the software used in the service.

object

No

The information about the software used in the service.

Name

string

No

The software name.

MySQL

Version

string

No

The software version.

5.7

IsSupportOperated

boolean

No

Specifies whether to enable managed O&M. Default value: false. Valid values:

  • true: Enabled.

  • false: Disabled.

Note

You must specify this parameter when ServiceType is set to private.

false

PolicyNames

string

No

The policy names. A single policy name can be up to 128 characters in length. Separate multiple policy names with commas (,). Currently, only managed O&M-related parameter policies are supported.

policyName1, policyName2

Duration

integer

No

The managed O&M duration. Unit: seconds.

259200

VersionName

string

No

The version name.

Draft

UpgradeMetadata

string

No

The upgrade metadata.

{\"Description\":\"xxx\",\"SupportRollback\":true,\"SupportUpgradeFromVersions\":[],\"UpgradeComponents\":[\"Configuration\"]}

TrialDuration

integer

No

The trial duration. Unit: days. The maximum trial duration is 30 days.

7

ServiceVersion

string

No

The service version.

1

TenantType

string

No

The tenant type. Valid values:

  • SingleTenant: Single tenant.

  • MultiTenant: Multi-tenant.

SingleTenant

LicenseMetadata

string

No

The license metadata.

{\"PayType\":\"CustomFixTime\",\"DefaultLicenseDays\":7,\"CustomMetadata\":[{\"TemplateName\":\"Template 1\",\"SpecificationName\":\"bandwith-0\",\"CustomData\":\"1\"}]}

OperationMetadata

string

No

The managed O&M configuration.

{\"PrometheusConfigMap\":{\"Custom_Image_Ecs\":{\"EnablePrometheus\":false}}}

LogMetadata

string

No

The application log configuration.

{ "Logstores": [ { "LogstoreName": "access-log", "LogPath": "/home/admin/app/logs", # Not required for containers. Configure it in YAML. "FilePattern": "access.log*" # Not required for containers. Configure it in YAML. } ] }

Resellable

boolean

No

Specifies whether distribution is supported. Valid values:

  • false: Not supported.

  • true: Supported.

false

UpdateOption

object

No

The update options.

UpdateFrom

string

No

The update option. Valid values:

  • CODE: Code.

  • PARAMETERS: Parameters.

PARAMETERS

UpdateArtifact

boolean

No

Specifies whether to update the deployment artifact.

true

Commodity

object

No

The bound commodity information.

SpecificationMappings

array<object>

No

The mapping between commodity specifications and templates or plans. This parameter is used in the subscription scenario of Alibaba Cloud Marketplace.

object

No

The mapping between commodity specifications and templates or plans. This parameter is used in the subscription scenario of Alibaba Cloud Marketplace.

TemplateName

string

No

The template name.

Template 1

SpecificationName

string

No

The plan name.

Basic Edition

SpecificationCode

string

No

The specification code.

yuncode5767800001

MeteringEntityMappings

array<object>

No

The mapping between templates or plans and metering dimensions. This parameter is used in the pay-as-you-go scenario of Alibaba Cloud Marketplace.

object

No

The mapping between templates or plans and metering dimensions. This parameter is used in the pay-as-you-go scenario of Alibaba Cloud Marketplace.

TemplateName

string

No

The template name.

Template 1

SpecificationName

string

No

The plan name.

Basic Edition

EntityIds

array

No

The metering item IDs.

string

No

The metering item ID.

cmgj0006xxxx-Memory-1

MeteringEntityExtraInfos

array<object>

No

The configuration information of metering items. This parameter is used in the pay-as-you-go scenario of Alibaba Cloud Marketplace.

object

No

The configuration information of the metering item.

EntityId

string

No

The metering item ID.

cmgj0006xxxx-Memory-1

Type

string

No

The type. Reference values:

  • Custom

  • ComputeNestBill

  • ComputeNestPrometheus

  • ComputeNestTime

Custom

MetricName

string

No

The metric name. Specify this parameter when Type is set to ComputeNestBill or ComputeNestPrometheus.

VirtualCpu/ecs.InstanceType

Promql

string

No

The PromQL statement.

avg_over_time(sum(rate(container_cpu_usage_seconds_total{namespace=~"ALIYUN::StackName"}[2m]))[1h:10s])

ComponentsMappings

array<object>

No

This parameter is not publicly available.

array<object>

No

This parameter is not publicly available.

TemplateName

string

No

This parameter is not publicly available.

This parameter is not publicly available

Mappings

object

No

This parameter is not publicly available.

此参数不对外开放

string

No

This parameter is not publicly available.

This parameter is not publicly available

SaasBoostConfig

string

No

The SaaS Boost configuration information.

{}

ShareType

string

No

The sharing type. Valid values:

  • Public: Public. Both formal and trial deployments are unrestricted.

  • Restricted: Restricted. Both formal and trial deployments are restricted.

  • OnlyFormalRestricted: Only formal deployment is restricted.

  • OnlyTrailRestricted: Only trial deployment is restricted.

  • Hidden: Hidden. The service is invisible and you cannot apply for deployment permissions.

Public

ApprovalType

string

No

The approval type for service usage applications. Valid values:

  • Manual: Manual approval.

  • AutoPass: Automatic approval.

Manual

DryRun

boolean

No

Specifies whether to perform a dry run on the request, including permission and instance status checks. Valid values:

  • true: Sends the request without updating the service.

  • false: Sends the request and updates the service after the check passes.

false

ComplianceMetadata

object

No

The compliance check metadata.

CompliancePacks

array

No

The selected compliance packs.

string

No

The selected compliance packs.

VpcDataRisk

BuildParameters

string

No

The build service parameters.

{ "ServiceTemplateId": "st-xxxxx"}

ServiceLocaleConfigs

array<object>

No

The service locale configurations.

object

No

The service locale configurations.

OriginalValue

string

No

The original data value of the business information.

Service Name

ZhValue

string

No

The Chinese data value corresponding to the business information.

Service name

EnValue

string

No

The English data value corresponding to the business information.

Service Name

IsDefault

boolean

No

Specifies whether this is the default version.

true

Response elements

Element

Type

Description

Example

object

RequestId

string

The request ID.

DF0F666F-FBBC-55C3-A368-C955DE7B4839

DryRunResult

object

The validation result. This parameter is returned only when DryRun is set to true.

RolePolicy

object

The access policy of the deployment role.

Policy

string

The required access policy for the deployment role.

{ "Statement": [{ "Action": ["oos:CancelExecutions", "oos:DeleteExecutions", "oos:GetTemplate", "oos:ListExecutions", "oos:ListTemplates", "oos:NotifyExecution", "oos:StartExecution"], "Effect": "Allow", "Resource": "*" }, { "Action": ["ram:PassRole"], "Effect": "Allow", "Resource": "*" }, { "Action": ["ros:CreateStack", "ros:GetStack", "ros:UpdateStack", "ros:ListStackEvents", "ros:ListStackResources", "ros:ListStackResources", "ros:DeleteStack", "ram:GetRole"], "Effect": "Allow", "Resource": "*" }], "Version": "1" }

MissingPolicy

array<object>

The missing access policy for the deployment role.

object

The missing access policy for the deployment role.

ServiceName

string

The service name in the access policy.

ecs

Resource

string

The resource in the access policy.

*

Action

array

The action in the access policy.

string

The action in the access policy.

CreateStack

Examples

Success response

JSON format

{
  "RequestId": "DF0F666F-FBBC-55C3-A368-C955DE7B4839",
  "DryRunResult": {
    "RolePolicy": {
      "Policy": "{\n\t\"Statement\": [{\n\t\t\"Action\": [\"oos:CancelExecutions\", \"oos:DeleteExecutions\", \"oos:GetTemplate\", \"oos:ListExecutions\", \"oos:ListTemplates\", \"oos:NotifyExecution\", \"oos:StartExecution\"],\n\t\t\"Effect\": \"Allow\",\n\t\t\"Resource\": \"*\"\n\t}, {\n\t\t\"Action\": [\"ram:PassRole\"],\n\t\t\"Effect\": \"Allow\",\n\t\t\"Resource\": \"*\"\n\t}, {\n\t\t\"Action\": [\"ros:CreateStack\", \"ros:GetStack\", \"ros:UpdateStack\", \"ros:ListStackEvents\", \"ros:ListStackResources\", \"ros:ListStackResources\", \"ros:DeleteStack\", \"ram:GetRole\"],\n\t\t\"Effect\": \"Allow\",\n\t\t\"Resource\": \"*\"\n\t}],\n\t\"Version\": \"1\"\n}",
      "MissingPolicy": [
        {
          "ServiceName": "ecs",
          "Resource": "*",
          "Action": [
            "CreateStack"
          ]
        }
      ]
    }
  }
}

Error codes

See Error Codes for a complete list.

Release notes

See Release Notes for a complete list.