---
title: "Create a connect link"
method: POST
path: "/v1/connect-links"
---

# Create a connect link

`POST /v1/connect-links`

## Request

- Base URL: `https://api.breakreach.com`
- URL: `https://api.breakreach.com/v1/connect-links`
- Auth: HTTP bearer

Creates a hosted page where someone without a Breakreach login (your end user, your client) connects social accounts into a workspace. Send them the url; they pick a network, authorize it, and come back to the page, then to redirectUrl when they click Done, with ?connected=<platforms>&workspace=<slug> appended. Accounts connected this way fire the account.connected webhook and count toward your plan. Only the workspace owner can create links.

## Headers

- `Idempotency-Key` string

## Request body

- object
  - `workspace` string: Workspace slug (optional, defaults to your first workspace)
  - `platforms` string[]: Networks offered on the page (default: all)
  - `redirectUrl` string, uri: Where the Done button sends them: https, or http on localhost
  - `expiresInHours` integer: How long the link works (default 24)

## Response `200`

Created

- object
  - `connectLink` ConnectLink, required
    - `id` string, required
    - `url` string, uri: The page to send, only returned at creation
    - `workspace` string, required: Workspace slug
    - `platforms` string[], required
    - `redirectUrl` string, nullable, required
    - `expiresAt` string, date-time, required
    - `status` 'active' | 'expired' | 'revoked', required
    - `connected` object[], required
      - `accountId` string, required
      - `platform` string, required
      - `displayName` string, required
      - `connectedAt` string, date-time, required

## Other responses

- `400`: Unknown platform, invalid redirectUrl or expiresInHours
- `401`: Missing, invalid or expired API key
- `402`: No active Breakreach subscription or trial
- `403`: Not a member of the requested workspace
- `404`: Workspace not found
- `409`: A request with this Idempotency-Key is still running: retry after Retry-After seconds to get its response
- `422`: This Idempotency-Key was already used with a different request in the last 24 hours

---

[API](https://skmtc.dev/breakreach/apis/breakreach-api.md) · [All operations](https://skmtc.dev/breakreach/apis/breakreach-api/llms.txt) · [OpenAPI document](https://skmtc.dev/breakreach/apis/breakreach-api/revisions/290d285f8d73?raw)
