> ## Documentation Index
> Fetch the complete documentation index at: https://docs.linquid.io/llms.txt
> Use this file to discover all available pages before exploring further.

# List Rules

> List routing rules in a workspace, with optional link and standalone filters

## Query Parameters

<ParamField query="linkId" type="string">
  Optional: return rules attached to one link
</ParamField>

<ParamField query="standalone" type="boolean" default="false">
  If `true`, return only rules not attached to links
</ParamField>

## Access

* Permission: `rules:read`

Behavior:

* Excludes soft-deleted rules.
* Adds `usageCount` per rule based on link attachments.

<RequestExample>
  ```bash cURL theme={null}
  curl -X GET "https://api.linquid.io/api/rules?standalone=true" \
    -H "Authorization: Bearer <token>"
  ```
</RequestExample>

<ResponseExample>
  ```json Response theme={null}
  {
    "success": true,
    "data": [
      {
        "id": "rule_def456",
        "campaignId": "campaign_123",
        "name": "Mobile Traffic",
        "type": "device",
        "priority": 1,
        "enabled": true,
        "usageCount": 3
      }
    ]
  }
  ```
</ResponseExample>
