WSO2 · JSON Structure

Devportal Api Throttling Policy Structure

ThrottlingPolicy schema from WSO2 API Manager

Type: object Properties: 15 Required: 5
API ManagementGatewaysOpen SourceAPI LifecycleGraphQLSOAPREST

Throttling Policy is a JSON Structure definition published by WSO2, describing 15 properties, of which 5 are required. It conforms to the https://json-structure.org/meta/core/v0/# meta-schema.

Properties

name description policyLevel attributes requestCount dataUnit unitTime timeUnit rateLimitCount rateLimitTimeUnit quotaPolicyType tierPlan stopOnQuotaReach monetizationAttributes throttlingPolicyPermissions

Meta-schema: https://json-structure.org/meta/core/v0/#

JSON Structure

Raw ↑
{
  "$schema": "https://json-structure.org/meta/core/v0/#",
  "$id": "https://raw.githubusercontent.com/api-evangelist/wso2/refs/heads/main/json-structure/devportal-api-throttling-policy-structure.json",
  "name": "Throttling Policy",
  "description": "ThrottlingPolicy schema from WSO2 API Manager",
  "required": [
    "name",
    "requestCount",
    "stopOnQuotaReach",
    "tierPlan",
    "unitTime"
  ],
  "type": "object",
  "properties": {
    "name": {
      "type": "string",
      "example": "Platinum"
    },
    "description": {
      "type": "string",
      "example": "Allows 50 request(s) per minute."
    },
    "policyLevel": {
      "type": "string",
      "example": "subscription",
      "enum": [
        "application",
        "subscription"
      ]
    },
    "attributes": {
      "type": "object",
      "additionalProperties": {
        "type": "string"
      },
      "description": "Custom attributes added to the throttling policy\n",
      "example": {}
    },
    "requestCount": {
      "type": "int64",
      "description": "Maximum number of requests which can be sent within a provided unit time\n",
      "example": 50
    },
    "dataUnit": {
      "description": "Unit of data allowed to be transfered. Allowed values are \"KB\", \"MB\" and \"GB\"\n",
      "type": "string",
      "example": "KB"
    },
    "unitTime": {
      "type": "int64",
      "example": 60000
    },
    "timeUnit": {
      "type": "string",
      "example": "min"
    },
    "rateLimitCount": {
      "type": "int32",
      "default": 0,
      "description": "Burst control request count",
      "example": 10
    },
    "rateLimitTimeUnit": {
      "type": "string",
      "description": "Burst control time unit",
      "example": "min"
    },
    "quotaPolicyType": {
      "type": "string",
      "description": "Default quota limit type",
      "enum": [
        "REQUESTCOUNT",
        "BANDWIDTHVOLUME"
      ],
      "example": "REQUESTCOUNT"
    },
    "tierPlan": {
      "type": "string",
      "description": "This attribute declares whether this tier is available under commercial or free\n",
      "example": "FREE",
      "enum": [
        "FREE",
        "COMMERCIAL"
      ]
    },
    "stopOnQuotaReach": {
      "type": "boolean",
      "description": "If this attribute is set to false, you are capabale of sending requests\neven if the request count exceeded within a unit time\n",
      "example": true
    },
    "monetizationAttributes": {
      "$ref": "#/components/schemas/MonetizationInfo"
    },
    "throttlingPolicyPermissions": {
      "$ref": "#/components/schemas/ThrottlingPolicyPermissionInfo"
    }
  }
}