修改站点的重写URL配置。
调试
您可以在OpenAPI Explorer中直接运行该接口,免去您计算签名的困扰。运行成功后,OpenAPI Explorer可以自动生成SDK代码示例。
授权信息
当前API暂无授权信息透出。
请求参数
名称 | 类型 | 必填 | 描述 | 示例值 |
---|---|---|---|---|
SiteId | long | 是 | 站点 ID,可通过调用 ListSites 接口获取。 | 123456789**** |
ConfigId | long | 是 | 配置 ID。可通过调用 ListRewriteUrlRules 接口获取。 | 3528160969**** |
RuleName | string | 否 | 规则名称。 | example=123 |
RuleEnable | string | 否 | 规则开关。取值范围:
| on |
Rule | string | 否 | 规则内容。 | (http.host eq "video.example.com") |
RewriteUriType | string | 否 | 路径重写类型。取值范围:
| static |
Uri | string | 否 | 重写后的目标 URI。 | /image/example.jpg |
RewriteQueryStringType | string | 否 | 查询字符串重写类型。取值范围:
| static |
QueryString | string | 否 | 重写后的查询字符串。 | example=123 |
返回参数
示例
正常返回示例
JSON
格式
{
"RequestId": "156A6B-677B1A-4297B7-9187B7-2B44792"
}
错误码
HTTP status code | 错误码 | 错误信息 | 描述 |
---|---|---|---|
400 | ApplyVipError | Failed to apply for ip resources, please contact customer service. | 申请IP资源失败,请联系客服。 |
400 | CanNotSetSequence | Non-regular configuration, you cannot set Sequence parameters. | 全局配置中不允许设置Sequence参数。 |
400 | CacheReserveSiteExceedLimit | The number of binding sites of the cache reserve instance exceeds the limit. The number of binding sites of a single cache reserve instance is limited. Please see the document for the limit. | 缓存保持实例绑定的站点数量超过上限。 |
400 | CompileRuleError | Rule compilation failed, please check the rule information passed in to ensure that the rule is written according to the syntax described in the document. | 规则编译失败,请检查传入的规则配置,请参考接口文档中描述的规则配置格式。 |
400 | SiteConfigLengthExceedLimit | The overall configuration size of the site exceeds the limit, and the total size of all functional configurations of the site cannot exceed 512K. | 站点功能配置大小超出限制,总大小不能超过512K。 |
400 | ConfigConflicts | Configuration conflicts, usually when multiple configurations are configured under the same function of the same site, such as duplicate rule names between multiple configurations. | 参数唯一性校验失败,请检查重复的参数值。 |
400 | RuleRegexQuotaCheckFailed | When configuring rules, rules with regular expressions are not allowed in this plan. Please check the relevant documentation of the plan or upgrade the plan. | 当前套餐不支持配置带有正则的规则引擎,请查看套餐描述,并升级您的套餐。 |
400 | NestedRuleQuotaCheckFailed | The nesting level of rules allowed by the plan failed to be verified. Please modify the nesting level of rules or upgrade the plan. | 规则内嵌子条件数量超过套餐上限,请查看套餐描述,并升级您的套餐。 |
400 | ArgQuotaCheckFailed | The passed-in parameter value failed to verify the validity of the plan. Please check the plan document to obtain the range of parameters that can be configured for the site plan. | 当前套餐不支持配置受限参数,请检查输入的参数。 |
400 | ServiceInvokeFailed | The call to the internal service failed. The engineer is resolving the problem. Please wait a moment before trying, or contact customer service for details. | 调用服务失败,请稍后重试或联系客服咨询详情。 |
400 | FunctionConflict | The feature configuration conflicts. Sites with version management enabled cannot configure this feature. | 当前配置的功能与其它功能存在冲突,如需要配置请先删除冲突的功能配置。 |
400 | SpecifiedVersionReadOnly | The specified version number is read-only and cannot be modified. | 指定的版本号为只读版本, 无法修改版本配置。 |
400 | VersionNotValid | The site does not have version management enabled, or the version number passed in does not exist. | 站点没有开启版本管理功能,或者传入的版本号不存在。 |
400 | InternalException | Failed to call the service. Try again later or contact technical support. | 调用服务失败,请稍后重试或联系客服咨询详情。 |
400 | InvalidParameter.ArgName | Invalid ArgName. Check your website configuration parameters and make sure that they match the supported features and parameter names listed in the official documentation. | 传入的ArgName无效,请检查您提供的站点配置参数,确保它们与官方文档中列出的支持功能及参数名称相匹配。 |
400 | InvalidParameter.ArgValue | Invalid parameter value. Check whether the value format and length meet the requirements. | 参数值无效,请检查输入是否符合规定格式及长度限制。 |
400 | InvalidParameter.Configs | Invalid parameter configurations. Check whether your feature configurations are in the valid format and comply with relevant requirements. | 配置参数错误,请检查站点功能设置项是否遵循规定格式及要求。 |
400 | InvalidParameter.FunctionName | The specified feature does not exist. Specify a valid feature name based on the related documentation. | 您所输入的功能名称不存在,请参照功能配置文档选择正确的功能名进行操作。 |
400 | InstanceNotExist | The instance does not exist. Check whether the specified instance ID is correct or whether the instance belongs to your account. | 实例不存在,请检查提供的实例ID是否正确或该实例是否属于您的账户。 |
400 | LockFailed | The system is handling requests you previously submitted. Try again later. | 您有其他请求正在处理中,请稍后再进行重试。 |
400 | IllegalOperation.VersionManagement | The version management operation failed because incompatible features or environment settings are configured. Adjust your configurations and try again. | 当前进行版本管理操作时,存在与其互斥的功能或环境设置,请先调整相关配置后再尝试。 |
400 | QuotaCheckFailed.VersionManagement | Insufficient quota for version management. Contact technical support. | 当前套餐的版本管理配额不足,请联系客服咨询详情。 |
400 | InvalidConfigId | The input configuration ID: ConfigId it does not exist, query the existing configuration and its valid ConfigId through the ListSiteFunction. | 传入的ConfigId不存在。 |
400 | Instance.NotOnline | Your plan is unavailable due to an overdue payment. Complete the payment first. | 您的套餐实例因欠费当前处于非上线状态,请先完成续费操作以继续使用。 |
400 | CachceReserveInstanceCheckFalied | If the site uses the back-to-source whitelist node and the cache holding instance is not in the back-to-source whitelist, the cache holding instance cannot be associated with the site. If you want to use both functions at the same time, please contact customer service for details. | 站点使用了回源白名单节点,而缓存保持实例不在回源白名单中的情况下,无法为站点关联缓存保持实例。如果您希望同时使用两个功能,请联系客服咨询详情。 |
404 | SiteNotFound | The website does not exist or does not belong to you. | 站点不存在,或者不属于你。 |
访问错误中心查看更多错误码。