<!-- https://developers.silktide.com/v1/presence/sources/get-cited-pages | Presence / Citations -->

# List the pages assistants cite

`GET /v1/results/accounts/presence/source-pages/table`

Lists the pages that answers cite, with how often each was cited over some dates. A page is counted each time an answer cites it.

Pages are sorted by `citations`, most first. `search` matches the address. To see which answers cite a page, send its `url` to [List answers](https://developers.silktide.com/v1/presence/answers/get-responses.md).

## Request

### Query parameters

- `workspaceId` (integer, required, at least 1): Where the account's markets live. [Get the workspace](https://developers.silktide.com/v1/presence/setup/get-workspace.md) answers with it.
- `marketId` (integer, optional, at least 1): Only this market: the number after `/presence/` in the market's address in Silktide. Left out, every market the API key's user can see.
- `from` (integer, optional): Only answers asked for at or after this time, in Unix seconds. Defaults to 30 days before `to`.
- `to` (integer, optional): Only answers asked for at or before this time, in Unix seconds. Defaults to now.
- `platforms` (string, optional): Only these assistants, by id, comma-separated, such as `chatgpt,gemini`. Left out, all of them. An unknown id matches nothing.
- `excludePlatforms` (string, optional): Leave out these assistants, by id, comma-separated, such as `google-search,bing-search`.
- `topics` (string, optional): Only these topics, by id, comma-separated. Left out, all of them.
- `brands` (string, optional): Only answers that name at least one of these brands, by id, comma-separated. Ids of brands the account does not track are ignored.
- `arena` (string, optional): Which prompts' answers to read: `market` for prompts about a subject, `reputation` for prompts about a brand itself, or `all`. Defaults to `all`. Any other value answers with an error. One of: `all`, `market`, `reputation`.
- `url` (string, optional): Only this page.
- `host` (string, optional): Only pages on this host, exactly.
- `domain` (string, optional): Only pages on this domain or any host under it, such as `fakewinebarrel.com`.
- `owner` (string, optional): Only what these brands own: brand ids, comma-separated, `tracked` for any brand you track, or `untracked` for none of them.
- `columns` (string, optional): The columns to return, comma-separated, such as `url,pageViews`. Left out, the table's default columns. Send a string even in a JSON body: an array is ignored.
- `sort` (string, optional): The column to sort by, then `:a` for ascending or `:d` for descending, such as `pageViews:d`. Left out, the table's own order.
- `search` (string, optional): Only rows matching this text. What it searches depends on the table, most often the URL or title.
- `page` (integer, optional, at least 1): The page of rows to return, from `1`. Defaults to `1`.
- `rowsPerPage` (integer, optional, at least 1): How many rows a page holds. Defaults to `100`.

## Response

Status `200`.

- `result` (object, required): The answer.
  - `page` (integer, required, at least 1): The page returned. Not always the page asked for, when that was out of range.
  - `minPage` (integer, required, at least 1): The first page. Always `1`.
  - `maxPage` (integer, required): The last page at this `rowsPerPage`. With no rows, `0` or `1` depending on the table.
  - `numRows` (integer, required): How many rows there are across every page.
  - `rowsPerPage` (integer, required, at least 1): How many rows a page holds.
  - `rows` (list of objects, required): The rows on this page.
    - `urlKey` (string, required): The row's id: its `url`.
    - `url` (string, required): The page, as the assistant cited it. One page cited under two addresses is two rows.
    - `title` (string, required): The page's title, as the assistant gave it. Empty when it gave none.
    - `citations` (integer, required): How many times answers cited it.
    - `host` (string, optional): The page's host. Only when `columns` names it, and not with `host`.
    - `ownership` (string, required): Whose it is: `mine` for one of your own brands, `rival` for any other brand you track, or `none`. It follows your brands' web addresses as they are now, for older answers too. One of: `mine`, `rival`, `none`.
    - `ownerBrandId` (integer, required, can be null, at least 1): The tracked brand it belongs to. Null when it belongs to none.
    - `ownerName` (string, required, can be null): That brand's name. Null when it belongs to none.
- `selector` (string, required): The query that answered, as its path: `/v1/results/scores`.
- `duration` (number, required): Seconds Silktide took to answer.

## Errors

| Status | Type | When |
| --- | --- | --- |
| 200 | `EditionNotAvailable` | The account does not have Silktide 5. Its `status` is `403`. The body is an error despite the status. |
| 200 | `Runtime` | No `workspaceId` was sent, or `arena` is not one of its values. Its `status` is `500`, and its message does not say why. The body is an error despite the status. |
| 200 | `AccessDenied` | No such workspace or market exists in the account, or the API key's user cannot see it. Its `status` is `403`. The body is an error despite the status. |
| 401 | `NotLoggedIn` | No API key was sent, or it is not a key for this region. |
| 429 | `TooManyRequests` | Too many requests to this path in five seconds. Retry after the number of seconds in the `Retry-After` header, which `properties.retryAfter` repeats. |
| 503 | - | Silktide is busy. Retry after the number of seconds in the `Retry-After` header. |

## Access

- Permission: Can see this market
- Plan feature: none
- Edition: Silktide 5 only
- Cost: free
- Stability: stable, since 1.2.0

## Example: Your own pages that were cited, with their hosts

```bash
curl "https://api.eu.silktide.com/v1/results/accounts/presence/source-pages/table?workspaceId=1&owner=4&columns=url%2Chost%2Ccitations&sort=citations%3Ad&rowsPerPage=2" \
  -H "Authorization: silktide token=$SILKTIDE_API_KEY"
```

Response:

```json
{
  "result": {
    "page": 1,
    "minPage": 1,
    "maxPage": 11,
    "numRows": 21,
    "rowsPerPage": 2,
    "rows": [
      {
        "urlKey": "https://fakewinebarrel.com/barrels/used",
        "url": "https://fakewinebarrel.com/barrels/used",
        "title": "Used oak barrels",
        "citations": 174,
        "host": "fakewinebarrel.com",
        "ownership": "mine",
        "ownerBrandId": 4,
        "ownerName": "Fake Wine Barrel"
      },
      {
        "urlKey": "https://fakewinebarrel.com/",
        "url": "https://fakewinebarrel.com/",
        "title": "",
        "citations": 96,
        "host": "fakewinebarrel.com",
        "ownership": "mine",
        "ownerBrandId": 4,
        "ownerName": "Fake Wine Barrel"
      }
    ]
  },
  "selector": "/v1/results/accounts/presence/source-pages/table",
  "duration": 0.9
}
```
