---
title: "Create Link Token"
method: POST
path: "/link/token"
tags: ["Auth"]
---

# Create Link Token

`POST /link/token`

Creates a temporary link token that is required to initiate the `react-trackstar-link` component.
See the [Getting Started guide](/how-to-guides/getting-started) for more details.

## Headers

- `x-trackstar-api-key` string, required

## Request body

- LinkTokenInputSchema
  - `connection_id` string — An optional existing connection ID. If provided, the connection is reinstalled instead of a new connection being created.

## Response `200`

Successful response

- LinkTokenResponseSchema
  - `link_token` string, required — The link token that is required to initiate the `react-trackstar-link` component.

## Other responses

- `422` — Validation error

---

[API](https://skmtc.net/trackstarhq/apis/trackstar-api.md) · [All operations](https://skmtc.net/trackstarhq/apis/trackstar-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/trackstarhq/trackstar-api/versions/4bc5c6e1a8bf/schema)
