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

# List Links

> Retrieve a paginated list of links with optional filtering

Retrieve all links with pagination and filtering options.

**Request:**

```bash cURL theme={null}
curl -X GET 'https://api.taap.it/v1/links?archived=false&sort_by=created_at&sort_order=desc&page=1&page_size=20&cursor=eyJpZCI6ImxpbmtfOTg3NjU0MzIxIn0=' \
  -H 'Authorization: Bearer taapit_your_api_key_here'
```

**Response:**

```json theme={null}
{
  "items": [
    {
      "id": "link_987654321",
      "original_url": "https://example.com/very-long-url-that-needs-shortening",
      "short_url": "https://taap.it/my-custom-link",
      "code": "my-custom-link",
      "created_at": "2024-01-15T10:30:00Z",
      "click_count": 42,
      "is_active": true,
      "is_archived": false
    }
  ],
  "page": 1,
  "page_size": 10,
  "has_next": true,
  "has_prev": false,
  "next_cursor": "eyJpZCI6ImxpbmtfOTg3NjU0MzIxIn0=",
  "prev_cursor": null
}
```

## Authorization

<ParamField header="Authorization" type="string" required>
  Bearer token for API authentication. Format: `Bearer YOUR_API_KEY`
</ParamField>

## Query Parameters

### Pagination Parameters

<ParamField query="cursor" type="string">
  Cursor for pagination (use for efficient pagination)
</ParamField>

<ParamField query="page" type="integer" default="1">
  Page number (starts from 1)
</ParamField>

<ParamField query="page_size" type="integer" default="20">
  Number of items per page (maximum 100)
</ParamField>

### Sorting Parameters

<ParamField query="sort_by" type="string">
  Field to sort by (e.g., "created\_at", "updated\_at", "clicks", "code")
</ParamField>

<ParamField query="sort_order" type="string" default="desc">
  Sort order: "asc" for ascending or "desc" for descending
</ParamField>

### Filtering Parameters

<ParamField query="archived" type="boolean">
  Filter by archived status (true for archived links, false for active links)
</ParamField>
