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

# Connect a social account

Connect accounts with a profile key from your own app. A profile key can hold
multiple platform accounts, and post creation can target one account or every
connected account for a platform inside that key.

## Start OAuth

```bash theme={null}
kavenio connect begin \
  --profile-id customer_user_123 \
  --platform linkedin \
  --return-to https://app.example.com/accounts
```

The response includes an `authorizationUrl`. Open that URL for the user. After
the provider redirects back, Kavenio stores encrypted credentials and returns to
the `returnTo` URL with account identifiers in the query string.

Mastodon also requires an instance domain:

```bash theme={null}
kavenio connect begin \
  --profile-id customer_user_123 \
  --platform mastodon \
  --mastodon-instance mastodon.social \
  --return-to https://app.example.com/accounts
```

When using the API directly, pass `mastodonInstance` in the begin-connect body.
Kavenio handles the provider callback URL and code exchange; `returnTo` is only
the browser destination after Kavenio completes the connection. Mastodon app
registrations are cached per instance/callback/scope set, so normal repeat
connects do not re-register an app with the Mastodon instance.

## Provider discovery

Only show providers returned as configured from:

```http theme={null}
GET /v1/connect/providers
Authorization: Bearer kvn_...
```

This keeps dashboard connection cards aligned with the API environment.

## Platform selection steps

Some platforms require choosing a destination after OAuth:

* Facebook: select a Page.
* Instagram: direct Instagram Login connects the Business or Creator account.
  Meta-linked credentials can require selecting an Instagram account connected
  to a Facebook Page.
* LinkedIn: the authenticated member's personal profile is the destination;
  company Page selection is not currently supported.
* Pinterest: select a board.
* Reddit: select subreddit and flair when relevant.
* YouTube: select a channel.
* Google Business: select a business location.

Bluesky does not use OAuth in Kavenio. Connect it with a Bluesky identifier and
App Password:

```bash theme={null}
kavenio connect bluesky \
  --profile-id customer_user_123 \
  --identifier name.bsky.social \
  --app-password xxxx-xxxx-xxxx-xxxx
```

The App Password is encrypted and used for publishing, account health checks,
post analytics/comments, and text-only DM actions.

Google Business uses:

```bash theme={null}
kavenio connect googlebusiness-locations --account-id acc_123
kavenio connect googlebusiness-select-location \
  --account-id acc_123 \
  --profile-id customer_user_123 \
  --location-id 9281089117903930794
```

## Health

Use account health before publishing or management actions:

```bash theme={null}
kavenio accounts health --account-id acc_123
```

Health reports reconnect needs, missing scopes, missing permissions, and
destination setup issues such as a missing Google Business location.

## Related docs

<CardGroup cols={2}>
  <Card title="Google Business" icon="building-storefront" href="/docs/platforms/google-business">
    Connect and manage Google Business locations.
  </Card>

  <Card title="Bluesky" icon="hashtag" href="/docs/platforms/bluesky">
    Connect with App Password credentials and publish posts.
  </Card>

  <Card title="Connected accounts" icon="plug" href="/docs/api/connected-accounts">
    Account routes, health, reviews, and analytics.
  </Card>
</CardGroup>
