All Products
Search
Document Center

CloudOps Orchestration Service:Configure ROA-style API by using the OOS custom template

Last Updated:Mar 25, 2025

When using Object Storage Service (OSS), features such as creating and setting bucket properties are commonly needed. Additionally, configuring the bucket transfer acceleration is necessary for long-distance data transfers. This topic describes how to quickly and easily use CloudOps Orchestration Service (OOS) custom templates to call ROA-style API for configuring OSS bucket and its transfer acceleration feature.

Background information

Calling ROA-style API for certain Alibaba Cloud services often requires configuring complex parameters like Body, Headers, Method, and URI. OOS simplifies this process through the console, automatically filling in complex parameter values. The console prompts guide you in configuring various invocation parameters for the ROA-style API.

This tutorial focuses on configuring OSS buckets and its transfer acceleration feature by calling ROA-style API with OOS custom templates. For configurations of other cloud services, refer to the procedures in this topic.

The types of cloud services that OOS supports for configuring ROA-style API include the following:

Note

For details on cloud products that OOS supports for API CALLING, refer to the supported cloud product list. If the cloud product whose API you want to call is not included in the list, join the DingTalk group (group number: 23330931).

Procedure

Note

If you are using a RAM user, make sure that the Alibaba Cloud account has granted the RAM user the AliyunOOSFullAccess and AliyunOSSFullAccess policies.

  1. Navigate to the OOS console > Custom Task Template page, and click Create Template.

  2. Select Create Template Based on Samples, select ACS-OOS-ExampleExecuteECSDescribeRegions for Select Template , and click Next Step.

    Basic Sample Template

  3. Configure the OSS bucket and its transfer acceleration feature by invoking ROA-style API through OOS.

    This example shows how to use the flow configuration editor to quickly call ROA-style API and configure the OSS bucket and its transfer acceleration feature. If you have a YAML command ready, you can also configure these features directly using the YAML method.

    Expand to view: YAML command template example

    FormatVersion: OOS-2019-06-01
    Description: Execute a single API
    Tasks:
      - Name: PutBucket
        Action: ACS::ExecuteApi
        Description: ''
        Properties:
          Service: oss
          API: PutBucket
          Parameters:
            bucket: '{{ bucket }}'
          Headers:
            x-oss-acl: private
          Body:
            CreateBucketConfiguration:
              StorageClass: Standard
              DataRedundancyType: LRS
      - Action: ACS::ExecuteApi
        Name: ExecuteApi1
        Description: ''
        Properties:
          Service: oss
          API: PutBucketTransferAcceleration
          Parameters:
            bucket: '{{ bucket }}'
          Headers: {}
          Body:
            TransferAccelerationConfiguration:
              Enabled: 'true'
    Parameters:
      bucket:
        Type: String
    1. On the Process Configuration tab, click Add Template Parameters on the right.

    2. In the pop-up Parameter panel, you can set the Parameter Name (for example, Bucket-example), set Parameter Type to String, and click screenshot_2025-03-06_13-50-28 to close the panel.

    3. On the Process Configuration tab, in the ExecuteApi section, you can configure task-related parameters.

      1. In the Task Input section, select both the service name and the API name.

        Service Name

      2. Set the corresponding parameters for the ROA-style API.

        • Required Parameters: For the bucket parameter, select Reference Parameter/Task Output and then choose the pre-configured template parameter (Bucket-example).

          API Parameter Style

        • Other Parameters: For Headers or Body parameters, select as needed. If there are no special requirements, no configuration is needed.

          Note

          To gain a detailed understanding of specific parameters, you can hover over the screenshot_2025-03-06_15-59-08 to view the associated prompts.

    4. At the bottom of the page, you can click Add New Task, and on the pop-up Quick Selection page, select ACS::ExecuteApi.

      Add New Task

    5. In the ExecuteApi1 section, configure the relevant task parameters.

      1. In the Task Input section, select the service name and API name.

        Service Name

      2. Set the corresponding parameters for the ROA-style API.

        API Parameter Style

        • Required Parameters: For the bucket parameter, select Reference Parameter/Task Output and then choose the pre-configured template parameter (Bucket-example).

        • Body: Selecting true indicates that the bucket enables the transfer acceleration feature.

          Note

          To gain a detailed understanding of the parameters, hover over the adjacent prompts next to the parameter, as shown by screenshot_2025-03-06_15-59-08.

  4. Click Create Template, input the template name in the pop-up dialog box, and then click OK.

  5. Locate the custom task template you created, click Create Execution in the corresponding Actions column, and then click Next Step: Parameter Settings .

  6. Enter the custom bucket name, such as test-by-oos, for the Bucket-example parameter, click Next Step: Confirm, and then click Create.

Verification results

  1. Visit the OOS console > Buckets page, and click on the newly created bucket name (e.g., test-by-oos).

  2. In the left-side navigation pane, select Bucket Configuration > Transfer Acceleration, and ensure the transfer acceleration feature is enabled by default.

    Transfer Acceleration

    This demonstrates that by using the OOS custom template to invoke the ROA-style API, you can efficiently create a bucket and enable the transfer acceleration feature.