Skip to main content
PUT
/
distributions
/
{distributionID}
/
access-rules
/
{accessRuleID}
Update Access Rule
curl --request PUT \
  --url https://api.tenbyte.com/v1/distributions/{distributionID}/access-rules/{accessRuleID} \
  --header 'Content-Type: application/json' \
  --header 'X-API-Key: <api-key>' \
  --data '
{
  "name": "dcfdv",
  "match_type": "regex",
  "match_pattern": "/",
  "config": {
    "country_access": {
      "enabled": true,
      "values": [
        "CN",
        "JP"
      ],
      "action": "allow"
    },
    "ip_access": {
      "enabled": false,
      "values": [],
      "action": "deny"
    },
    "referrer_access": {
      "enabled": false,
      "values": [],
      "action": "allow"
    },
    "token_access": {
      "enabled": false,
      "values": []
    }
  }
}
'
{}

Authorizations

X-API-Key
string
header
required

Path Parameters

distributionID
string
required
accessRuleID
string
required

Body

application/json

The body is of type object.

Response

200 - application/json

The response is of type object.