All Products
Document Center

Create throttling policies

Last Updated: Dec 22, 2017


For creating custom throttling policies.

  • This function is intended for API activators.
  • Throttling policies are meaningless if they are not bound to APIs. After the policies are bound to APIs, they take effect for the APIs instantly.
  • This API can call up to 50 QPS for a single user.

Request parameters

Name Type Required? Description
Action String Yes Operation interface name, which is a required parameter; value: CreateTrafficControl.
TrafficControlName String Yes Throttling policy name, which contains 4–50 characters including English letters (upper and lower cases), Chinese characters, numbers, and underscores. The policy name must not start with an underscore.
TrafficControlUnit String Yes Throttling policy unit; values:
  • MINUTE: Minute
  • HOUR: Hour
  • DAY: Day
ApiDefault Integer Yes Default throttling value for each API.
UserDefault Integer No Default throttling value for each user.
AppDefault Integer No Default throttling value for each app.
Description String No Throttling policy description.

Return parameters

Name Type Description
RequestId String ID of the current request.
TrafficControlId String Unique throttling policy ID.


Request example

  2. &TrafficControlName=throttling test
  3. &TrafficControlUnit=MINUTE
  4. &ApiDefault=10000
  5. &UserDefault=10000
  6. &AppDefault=10000
  7. &Description=throttling test description
  8. &<Public request parameters>

Response example

XML format

  1. <CreateTrafficControlResponse>
  2. <RequestId>CEF72CEB-54B6-4AE8-B225-F876FF7BZ004</RequestId>
  3. <TrafficControlId>tf123456</TrafficControlId>
  4. </CreateTrafficControlResponse>

JSON format

  1. {
  2. "RequestId":"CEF72CEB-54B6-4AE8-B225-F876FF7BZ004",
  3. "TrafficControlId":"tf123456"
  4. }