Chirio
Get Started
Introduction
Quickstart
How Chirio works
Authentication
Platforms
Overview
Instagram
Threads
X
LinkedIn
Guides
Connect accounts
Publish a post
Media requirements
Carousels
First comments
Idempotency and retries
Account lifecycle
Revocation and deletion
The dashboard
Billing
Plans
Metering
Quotas
Api Reference
Overview
Accounts
Posts
Errors
Changelog
Roadmap
TrademarkTrademark
Ctrl k
Search...
Sign up
Chirio
Get Started
Introduction
Quickstart
How Chirio works
Authentication
Platforms
Overview
Instagram
Threads
X
LinkedIn
Guides
Connect accounts
Publish a post
Media requirements
Carousels
First comments
Idempotency and retries
Account lifecycle
Revocation and deletion
The dashboard
Billing
Plans
Metering
Quotas
Api Reference
Overview
Accounts
Posts
Errors
Changelog
Roadmap
TrademarkTrademark© Dopler. All rights reserved.
Built with Aveiro
Guides

Connect accounts

The hosted OAuth flow end to end, plus listing, statuses and disconnecting.
Updated 2d ago
Publish a post
Chirio hosts the OAuth flow so your app never implements one — and so you never register a platform app of your own. You ask for an authorize URL, send your user to it, and they come back to a redirect you chose.

The flow

  • POST /api/v1/accounts/connect with the platform, and optionally a profileId and a redirectUrl.
  • Chirio returns the platform's authorize URL, valid for 10 minutes and usable once.
  • You send the user there. They approve on Instagram, Threads, X or LinkedIn.
  • Chirio exchanges the code, upgrades to a long-lived credential where the platform offers one, encrypts it, and stores the account.
  • The user is redirected to your redirectUrl with the outcome in the query string.
curl -X POST "https://chirio.dev/api/v1/accounts/connect" \
  -H "Authorization: Bearer $CHIRIO_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "platform": "linkedin",
    "profileId": "workspace_42",
    "redirectUrl": "https://yourapp.com/settings/social"
  }'
{ "authUrl": "https://www.linkedin.com/oauth/v2/authorization?..." }

Request fields

Field
Required
Notes
`platform`yes`instagram`, `threads`, `x` or `linkedin`
`profileId`noYour own grouping key, up to 255 chars. Filters `GET /accounts` later.
`redirectUrl`noWhere the user lands afterwards. Must be a valid URL.
profileId is opaque to Chirio — it is how you tie a connected account back to one of your users, workspaces or tenants without a second lookup table.

What comes back on the redirect

Success:
https://yourapp.com/settings/social?status=success&accountId=8f2c...&platform=linkedin&username=Ada
Failure:
https://yourapp.com/settings/social?status=error&reason=access_denied
Without a redirectUrl the user lands on Chirio's own confirmation page instead — fine for internal tools, not for a product flow.
One connect can create several accounts
LinkedIn returns the personal profile's accountId on the redirect, but the same authorisation can also create one account per company page the member administers. Call GET /api/v1/accounts afterwards to find them — their platformUserId reads organization:{id}.

What each platform requires of the user

Before sending someone through, check they can actually complete it:
Platform
Requirement
InstagramA **professional** account (Business or Creator)
ThreadsA Threads profile
XAny account
LinkedInAny member; company pages appear only for pages they administer
See Platforms for the full picture.

Listing accounts

Credentials are never included in any response.

Statuses

Status
Meaning
What to do
`active`Usable for publishingNothing
`expired`The credential lapsed and could not be refreshedSend the user through connect again
`revoked`The user removed Chirio from their platform settingsSend the user through connect again
Publishing to a non-active account fails that target with account_not_active. See Account lifecycle.

Disconnecting

The account and its stored credentials are removed. Deleting an account that does not belong to your project answers 404 not_found — the same as one that never existed.
Revocation can also arrive from the other direction, without you asking. See Revocation and deletion.

Reconnecting

Reconnecting is just running the flow again for the same platform. It is the remedy for an expired or revoked account, for a connection that predates a capability such as X media uploads or Instagram comments, and for a LinkedIn member who has since been made admin of a new company page.
curl "https://chirio.dev/api/v1/accounts?profileId=workspace_42" \
  -H "Authorization: Bearer $CHIRIO_API_KEY"
{
  "accounts": [
    {
      "id": "8f2c...",
      "platform": "linkedin",
      "profileId": "workspace_42",
      "platformUserId": "urn-member-id",
      "username": "Ada",
      "status": "active",
      "connectedAt": "2026-08-01T10:00:00.000Z"
    }
  ]
}
curl -X DELETE "https://chirio.dev/api/v1/accounts/8f2c..." \
  -H "Authorization: Bearer $CHIRIO_API_KEY"
{ "deleted": true }