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

# Make your first Linkvite API call

> Create an API key, save a bookmark and list your bookmarks with curl, JavaScript or Go.

**1. Create an API key**

In the web app, go to **Settings** → **Developers** and create an API key. Keys start with `link_`. API keys need [Linkvite Pro](https://docs.linkvite.io/guides/plans.md).

```bash theme={null}
export LINKVITE_API_KEY="link_..."
```

**2. Install an SDK (optional)**

```bash JavaScript theme={null}
npm install @linkvite/js
```

```bash Go theme={null}
go get github.com/linkvite/go/v2
```

**3. Save a bookmark**

```bash curl theme={null}
curl -X POST https://api.linkvite.io/v1/bookmarks \
  -H "x-api-key: $LINKVITE_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"url": "https://example.com", "tags": "reading"}'
```

```javascript JavaScript theme={null}
import {Linkvite} from '@linkvite/js';

const linkvite = new Linkvite(process.env.LINKVITE_API_KEY);
const bookmark = await linkvite.bookmarks.create({
	url: 'https://example.com',
	tags: 'reading',
});
console.log(bookmark.id);
```

```go Go theme={null}
client, err := linkvite.NewClient(os.Getenv("LINKVITE_API_KEY"))
if err != nil {
	log.Fatal(err)
}
b, err := client.Bookmarks.Create(ctx, &linkvite.CreateBookmarkRequest{
	URL:  "https://example.com",
	Tags: "reading",
})
```

The response wraps the new bookmark in `data` ([response format](https://docs.linkvite.io/developers/responses-and-errors.md)):

```json theme={null}
{
  "ok": true,
  "message": "Bookmark created!",
  "data": {
    "id": "bmk_...",
    "url": "https://example.com",
    "title": "Example Domain",
    "tags": "reading"
  }
}
```

**4. List your bookmarks**

```bash curl theme={null}
curl "https://api.linkvite.io/v1/bookmarks?limit=20&q=example" \
  -H "x-api-key: $LINKVITE_API_KEY"
```

```javascript JavaScript theme={null}
const {bookmarks, pagination} = await linkvite.bookmarks.getAll({limit: 20, q: 'example'});
```

```go Go theme={null}
page, err := client.Bookmarks.GetAll(ctx, &linkvite.BookmarksGetAllParams{
	Limit: linkvite.Ptr(20),
	Q:     linkvite.Ptr("example"),
})
```

Lists are paginated; see [pagination](https://docs.linkvite.io/developers/pagination.md).

> [!NOTE]
>
> The example response shows a few fields; the [API reference](https://docs.linkvite.io/api-reference) lists all of them.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.