Modifies a delivery channel.

In this example, the status of the delivery channel whose ID is cdc-8e45ff4e06a3a8**** is changed to 0, which indicates that the delivery channel is disabled. After the delivery channel is disabled, Cloud Config retains the last delivery configuration and stops resource data delivery.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer. OpenAPI Explorer dynamically generates the sample code of the operation for different SDKs.

Request parameters

Parameter Type Required Example Description
Action String Yes UpdateDeliveryChannel

The operation that you want to perform. Set the value to UpdateDeliveryChannel.

DeliveryChannelName String No testoss

The name of the delivery channel.

Note If you do not set this parameter, this parameter is empty.
DeliveryChannelTargetArn String No acs:oss:cn-shanghai:100931896542****:new-bucket

The Alibaba Cloud Resource Name (ARN) of the delivery destination. Specify the ARN in one of the following formats:

  • acs:oss:{RegionId}:{accountId}:{bucketName} if your delivery destination is an Object Storage Service (OSS) bucket. Example: acs:oss:cn-shanghai:100931896542****:new-bucket.
  • acs:mns:{RegionId}:{accountId}:/topics/{topicName} if your delivery destination is a Message Service (MNS) topic. Example: acs:mns:cn-shanghai:100931896542****:/topics/topic1.
  • acs:log:{RegionId}:{accountId}:project/{projectName}/logstore/{logstoreName} if your delivery destination is a Log Service Logstore. Example: acs:log:cn-shanghai:100931896542****:project/project1/logstore/logstore1.
DeliveryChannelAssumeRoleArn String No acs:ram::100931896542****:role/aliyunserviceroleforconfig

The ARN of the role to be assumed by the delivery channel. Specify the ARN in the following format: acs:ram::{accountId}:role/aliyunserviceroleforconfig.

DeliveryChannelCondition String No [{"filterType":"ResourceType","values":["ACS::ActionTrail::Trail","ACS::CBWP::CommonBandwidthPackage","ACS::CDN::Domain","ACS::CEN::CenBandwidthPackage","ACS::CEN::CenInstance","ACS::CEN::Flowlog","ACS::DdosCoo::Instance"],"multiple":true}]

The rule to be attached to the delivery channel. This parameter is applicable only to delivery channels of the MNS type.

This parameter allows you to specify the lowest risk level for the events to subscribe to and the resource types for which you want to subscribe to events.

  • Specify the lowest risk level for the events to subscribe to in the following format: {"filterType":"RuleRiskLevel","value":"1","multiple":false}. The value field specifies the lowest risk level for the events to subscribe to. Valid values: 1, 2, and 3. A value of 1 indicates the high risk level. A value of 2 indicates the medium risk level. A value of 3 indicates the low risk level.
  • Specify the resource types for which you want to subscribe to events in the following format: {"filterType":"ResourceType","values":["ACS::ACK::Cluster","ACS::ActionTrail::Trail","ACS::CBWP::CommonBandwidthPackage"],"multiple":true}. The values field specifies the resource types for which you want to subscribe to events. Its value is a JSON array.

    Example: [{"filterType":"ResourceType","values":["ACS::ActionTrail::Trail","ACS::CBWP::CommonBandwidthPackage","ACS::CDN::Domain","ACS::CEN::CenBandwidthPackage","ACS::CEN::CenInstance","ACS::CEN::Flowlog","ACS::DdosCoo::Instance"],"multiple":true}].

Description String No My OSS delivery.

The description of the delivery channel.

ClientToken String No 1594295238-f9361358-5843-4294-8d30-b5183fac****

The client token that is used to ensure the idempotence of the request. You can use the client to generate the value, but you must make sure that the value is unique among different requests.

The client token can contain only ASCII characters. It cannot exceed 64 characters in length. For more information, see How to ensure idempotence.

ConfigurationSnapshot Boolean No false

Specifies whether to receive scheduled resource snapshots. If you set this parameter to true, Cloud Config delivers scheduled resource snapshots to the specified OSS bucket at 00:00:00 and 12:00:00 every day. Default value: false. Valid values:

  • true
  • false
Note This parameter is applicable only to delivery channels of the OSS type.
ConfigurationItemChangeNotification Boolean No false

Specifies whether to receive the configuration change history of the resources. If you set this parameter to true, Cloud Config delivers the configuration change history of the resources to OSS, Log Service, or MNS when the configurations of the resources change. Default value: false. Valid values:

  • true
  • false
Note This parameter is applicable to delivery channels of the OSS, SLS, or MNS type.
NonCompliantNotification Boolean No false

Specifies whether to receive resource non-compliance events. If you set this parameter to true, Cloud Config delivers resource non-compliance events to Log Service or MNS when resources are non-compliant. Default value: false. Valid values:

  • true
  • false
Note This parameter is applicable only to delivery channels of the SLS or MNS type.
OversizedDataOSSTargetArn String No acs:oss:cn-shanghai:100931896542****:new-bucket

The ARN of the OSS bucket to which the data to be delivered is transferred if the size of the data exceeds the upper limit of the delivery channel. Specify the ARN in the following format: acs:oss:{RegionId}:{accountId}:{bucketName}.

If you do not set this parameter, Cloud Config delivers only summary information when the size of the data to be delivered exceeds the upper limit of the delivery channel.

Note This parameter is applicable only to delivery channels of the SLS or MNS type. The upper limit on the storage size of delivery channels of the SLS type is 1 MB, and that of delivery channels of the MNS type is 64 KB.
DeliveryChannelId String Yes cdc-8e45ff4e06a3a8****

The ID of the delivery channel.

For more information about how to obtain the ID of the delivery channel, see DescribeDeliveryChannels.

Status Long No 0

The status of the delivery channel. Valid values:

  • 0: The delivery channel is disabled. Cloud Config retains the last delivery configuration and stops resource data delivery.
  • 1: The delivery channel is enabled. This is the default value.

For more information about common request parameters, see the "Common request parameters" section of the Common parameters topic.

Response parameters

Parameter Type Example Description
RequestId String A7A0FFF8-0B44-40C6-8BBF-3A185EFDERTHG

The ID of the request.

DeliveryChannelId String cdc-8e45ff4e06a3a8****

The ID of the delivery channel.

Examples

Sample requests

http(s)://[Endpoint]/?Action=UpdateDeliveryChannel
&DeliveryChannelId=cdc-8e45ff4e06a3a8****
&Status=0
&<Common request parameters>

Sample success responses

XML format

HTTP/1.1 200 OK
Content-Type:application/xml

<UpdateDeliveryChannelResponse>
    <RequestId>A7A0FFF8-0B44-40C6-8BBF-3A185EFDERTHG</RequestId>
    <DeliveryChannelId>cdc-8e45ff4e06a3a8****</DeliveryChannelId>
</UpdateDeliveryChannelResponse>

JSON format

HTTP/1.1 200 OK
Content-Type:application/json

{
  "RequestId" : "A7A0FFF8-0B44-40C6-8BBF-3A185EFDERTHG",
  "DeliveryChannelId" : "cdc-8e45ff4e06a3a8****"
}

Error codes

HTTP status code Error code Error message Description
400 DeliveryChannelNotExists The delivery channel does not exist. The error message returned because the specified delivery channel does not exist.
400 Invalid.DeliveryChannelAssumeRoleArn.Format The specified format of DeliveryChannelAssumeRoleArn is invalid. The error message returned because the value of the DeliveryChannelAssumeRoleArn parameter is specified in an invalid format.
400 Invalid.DeliveryChannelTargetArn.Format The specified format of DeliveryChannelTargetArn is invalid. The error message returned because the value of the DeliveryChannelTargetArn parameter is specified in an invalid format.
400 Invalid.DeliveryChannelCondition.Format The specified format of DeliveryChannelCondition is invalid. The error message returned because the value of the DeliveryChannelCondition parameter is specified in an invalid format.
400 MemberNotBelongToMaster The specified member does not belong to your organization. The error message returned because the specified member account does not belong to your resource directory.
400 DeliveryChannelAccountNotSupport Cross-account delivery that is not in the RD is not supported. The error message returned because Cloud Config does not support event delivery across accounts that are in different resource directories.
400 DeliveryChannelMnsUnreachable The MNS topic is unreachable. The error message returned because the delivery request to the specified MNS topic failed.
400 DeliveryChannelOssUnreachable The OSS bucket is unreachable. The error message returned because the delivery request to the specified OSS bucket failed.
400 DeliveryChannelSlsUnreachable SLS logstore is unreachable. The error message returned because the delivery request to the specified Log Service Logstore failed.
404 AccountNotExisted Your account does not exist. The error message returned because your account does not exist.

For a list of error codes, visit the API Error Center.