Rules define conditional routing for a link. Instead of always sending every visitor to the same destination, a link with rules evaluates each rule in order and redirects to the first one whose conditions all match. If no rule matches, the link falls back to its default destination. Rules are managed as an ordered list on a specific link — there is no standalone rules resource. All rules endpoints require a valid API key sent asDocumentation Index
Fetch the complete documentation index at: https://mintlify.com/org-quicko/linq/llms.txt
Use this file to discover all available pages before exploring further.
Authorization: Bearer <key> or X-Api-Key: <key>.
How rule evaluation works
When a visitor hits a short link, the redirect handler evaluates the link’s rules in ascendingposition order. Each rule carries one or more conditions, all of which must hold simultaneously (they are AND-ed together). The first rule whose entire condition set matches wins, and the visitor is sent to that rule’s destination. If no rule matches — or the link has no rules — the visitor goes to the link’s default destination. A link can carry up to 50 rules; each rule can carry up to 10 conditions.
GET /api/v1/links//rules
Retrieve the ordered rules list for a link. Returns rules sorted byposition ascending, which is the order they are evaluated at redirect time. If the link exists but has no rules, returns an empty array. If the link does not exist, returns 404.
Minimum role: viewer
Path parameters
UUID of the link whose rules you want to read.
Response — 200
An array of Rule objects, ordered byposition ascending.
PUT /api/v1/links//rules
Replace the entire rules list for a link in a single atomic transaction. The server assignsposition values from the array order (index 0 becomes position 0, and so on) — you do not send positions. To remove all rules, send an empty array [].
PUT replaces all rules atomically. To delete a single rule, omit it from the array and send the remaining rules in your desired order. To reorder rules, send the full list in the new order. The old rules are deleted and the new ones are inserted in one transaction — the link is never left with a partial set.
editor
Path parameters
UUID of the link whose rules you want to replace.
Request body
An ordered JSON array of rule input objects (maximum 50 items). Each object must have adestination and at least one condition. A rule with zero conditions is rejected (400).
The URL to redirect to when this rule matches. Must be a valid URL.
One to 10 condition objects, all of which must match for this rule to fire. See Condition object below.
Response — 200
The stored rules in their new order, as an array of Rule objects. Full example — iOS to App Store, Android to Play Store:utm_source query param:
Rule object
The full Rule response shape returned by both rules endpoints.UUID (v7) of the rule. Server-assigned.
UUID of the link this rule belongs to.
Zero-based evaluation order. The lowest matching position wins. Server-owned — set from array index on PUT, never sent by the caller.
The URL visitors are sent to when this rule’s conditions all match.
Condition object
A condition is one predicate inside a rule. Two types are supported, discriminated by thetype field.
Platform condition
Matches visitors based on their detected platform (derived from theUser-Agent header).
Always
"platform".One of
"android", "ios", or "desktop".Query param condition
Matches visitors based on a query parameter present in the incoming URL. Ifvalue is omitted, the condition matches whenever the parameter key is present with any value (including an empty string).
Always
"query_param".The query parameter name to check. 1–64 characters.
Optional. The exact value the parameter must equal. Max 512 characters. When absent, the condition matches if the key is present with any value.