# AnnotationsApi.list()

```ts
list(pageIndex: number): Promise<AnnotationInfo[]>
```

Every annotation on a page as `AnnotationInfo[]`. An `id` is the annotation's name — a UUID for one the SDK created — or `obj:<number>` for one the file carries without a name. Without the `extract` feature `contents`, `author` and a web link's `uri` are `''`. A link's `uri` is the address the viewer would follow (`http:`, `https:`, `mailto:`, `tel:`, as `create()` takes it — a bare host in the file reads with `https://` in front); a link with any other scheme has `uri` and `targetPage` both `null`. `created` and `modified` are `Date`s, `null` where a file from another producer says nothing or writes something that is not a PDF date. Needs no feature.

- Kind: method
- Since: 1.0.0

| Parameter | Type | Description |
| --- | --- | --- |
| `pageIndex` | `number` | Zero-based page index. |

Returns `Promise<AnnotationInfo[]>`: Each with `pageIndex`, `id`, `type`, `rect`, `contents`, `author`, `color`, `opacity`, `fillColor`, `created`, `modified`, `quads`, `inkList`, `vertices`, `line`, `lineEndings`, `strokeWidth`, `uri`, `targetPage`, `flags`, `inReplyTo` and `status`.

Throws:

- `INVALID_ARGUMENT` — a page index out of range.
- `DOCUMENT_CLOSED` — the document has been closed.

```ts
const links = (await doc.annotations.list(0)).filter((a) => a.type === 'link');
```

Part of [AnnotationsApi](https://kernstra.com/docs/web-sdk/api/doc-annotations) in the Kernstra Web SDK 1.0.0 API reference.

Web page: https://kernstra.com/docs/web-sdk/api/doc-annotations/list
