If a user's request URL contains parameters that differ from what the origin server requires, you can use the parameter rewrite feature to modify the query parameters in the origin request. This feature lets you add, delete, modify, and reserve specific parameters, or ignore all parameters.
Background
The parameter rewrite feature modifies the query parameters of an origin request URL. You can configure multiple rewrite rules. The rules are applied in the following priority order: Add > Delete > Ignore Parameters and Reserve Only > Modify. If multiple rules target the same parameter, only the highest-priority rule is applied.
Ignore Parameters and Reserve Only are mutually exclusive. Do not configure both parameters at the same time.

Conflicts
The parameter rewrite feature can conflict with the enhance break rule of the URI rewrite feature and the parameter filtering feature. Avoid creating conflicting configurations. If a conflict occurs, the last configured feature takes precedence.
DCDN processes parameter rewrite rules at the origin POP. This does not affect the internal request flow or the cache key.
DCDN processes parameter filtering rules at the edge POP. This affects the internal request flow and changes the cache key.
Procedure
-
Log on to the DCDN console.
-
In the left-side navigation pane, click Domain Names.
-
On the Domain Names page, find the domain name that you want to manage and click Configure in the Actions column.
In the domain's left-side navigation pane, click Origin Fetch.
Click the Parameter Rewrite tab.
On the Parameter Rewrite tab, enable Use Parameter Rewrite.
Configure your rewrite rules.
Configure rules based on your business needs. For details, see Configuration examples.

Click OK to apply the configuration.
You can also click Modify Configuration on the Parameter Rewrite page to change existing rules.

Note: If you use this feature as an action within the Rules Engine, the rule priority set in the Rules Engine overrides this feature's internal operation priority.
Configuration examples
Example 1: Ignore all parameters.

Parameter
Example
Ignore Parameters
Enabled
Add
None
Delete
None
Reserve Only
None
Modify
None
Expected result
Original request:
http://example.com/index.html?code1=1&code2=2&code3=3Rewritten origin request:
http://example.com/index.htmlExample 2: Reserve a specific parameter.

Parameter
Example
Ignore Parameters
None
Add
None
Delete
None
Reserve Only
code2
Modify
None
Expected result
Original request:
http://example.com/index.html?code1=1&code2=2&code3=3Rewritten origin request:
http://example.com/index.html?code2=2Example 3: Add, delete, and modify parameters.

Parameter
Example
Ignore Parameters
None
Add
code4=4
Delete
code2
Reserve Only
None
Modify
code3=0
Expected result
Original request:
http://example.com/index.html?code1=1&code2=2&code3=3Rewritten origin request:
http://example.com/index.html?code1=1&code3=0&code4=4