---
title: "Connect Platform"
method: POST
path: "/v1/platforms/connect"
tags: ["platforms"]
---

# Connect Platform

`POST /v1/platforms/connect`

## Request

- Base URL: `https://api.theagentc.io` (the document declares no server; this is the origin it was published from)
- URL: `https://api.theagentc.io/v1/platforms/connect`
- Auth: HTTP bearer

Initiate OAuth flow for connecting a social platform.

Returns an authorization_url that the frontend should redirect
the user to. After the user authorizes, the platform redirects
back to the specified redirect_uri with a code and state.

## Request body

- ConnectRequest: Request to initiate OAuth flow for a platform.
  - `brand_id` string, uuid, required: Brand to connect the platform to
  - `platform` string, required: Platform to connect: x, youtube, pinterest
  - `redirect_uri` string, required: Frontend URL to redirect after OAuth completes

## Response `200`

Successful Response

- ConnectResponse: OAuth redirect URL for the user to authorize.
  - `authorization_url` string, required
  - `state` string, required

## Other responses

- `422`: Validation Error

---

[API](https://skmtc.dev/theagentc/apis/the-agent-c-api.md) · [All operations](https://skmtc.dev/theagentc/apis/the-agent-c-api/llms.txt) · [OpenAPI document](https://skmtc.dev/theagentc/apis/the-agent-c-api/revisions/1c9868b44584?raw)
