Start
Guides
Concepts
API endpoints
PUT
Update redirect rule
https://linkshift.app/api/v1/redirect-rules/{id}Updates a redirect rule and re-runs backend validation constraints.
Operation ID:
updateRedirectRuleTags: Redirect RulesSecurity
- ApiKeyAuth: apiKey | header:X-API-Key | API key generated in LinkShift dashboard (`Organization -> Manage API keys`).
Parameters
Path parameters
idrequired
Type: stringDescription: Resource identifier.
Request body schema
requestBodyobjectrequired
Payload for updating a redirect rule.
destinationstring | nullnullable
Static destination URL. Keep null when using `linkMapId`.
linkMapIdstring | nullnullable
Optional link-map ID for key-based destinations.
matchMethodarray of string
Allowed request methods. Empty array means all methods.
pathMatchstring
Path matching strategy.
priorityinteger
Rule priority (higher first).
queryMatchstring
Query-string matching strategy.
sourcestring
Source matcher expression.
statusCodeinteger
HTTP redirect status used for rule matches.
Response schema
Updated redirect rule
Content type:
application/jsonresponse 200objectrequired
Redirect rule resolved during request matching.
blockedAtstring | nullnullable
Timestamp when the rule was blocked.
createdAtstringrequired
Creation timestamp (UTC).
deletedAtstring | nullnullable
Soft-delete timestamp in UTC when deleted.
destinationstring | nullnullable
Static redirect destination URL. Null when dynamic destination is used via link map.
domainGroupIdstringrequired
Parent domain-group ID.
idstringrequired
Redirect-rule ID.
isBlockedboolean
Whether the rule is currently blocked from execution.
linkMapIdstring | nullnullable
Optional linked map used for key-based destinations.
matchMethodarray of stringrequired
Allowed request methods. Empty array means all methods.
pathMatchstringrequired
Path matching strategy.
priorityintegerrequired
Rule priority (higher first).
queryMatchstringrequired
Query-string matching strategy.
sourcestringrequired
Source matcher expression.
statusCodeintegerrequired
HTTP redirect status returned for matches.
updatedAtstringrequired
Last update timestamp (UTC).
