Connect a channel
Authorize a new YouTube channel or Facebook page so it can publish.
User intents
"Connect my YouTube channel to Pharlo." "I want to add my Facebook page."
Required information
- The
platform:youtubeorfacebook. - (Optional) the organization to associate the connection with.
Preconditions
- The user can complete an OAuth consent flow in a browser.
Tool sequence
Generate the consent URL
get_oauth_connect_url with platform. It returns a url and a ticketId (valid 15 minutes).
Hand the URL to the user
Ask the user to open the url and complete authorization in their browser.
Poll for completion
check_oauth_status with the ticketId: pending (keep waiting), success (done), failed, or expired.
Confirm the channel
list_connections — verify the new channel now appears with a valid token.
REST alternative
The OAuth start/callback routes — see the OAuth reference.
Recovery paths
check_oauth_statusreturnsexpired— callget_oauth_connect_urlagain for a fresh ticket.failed— surface the returned error detail; the user likely denied consent or the platform rejected scopes.- Re-authorizing an existing channel (token expired) — call
get_oauth_connect_urlwith the existingconnectionId.
Example prompt → result
"Add my YouTube channel."
Result: the agent returns a consent link; after the user finishes, check_oauth_status reports success and the channel is listed.
Live platforms are YouTube and Facebook. Other platforms may appear in listings but are not yet publishable.
Common mistakes
- Forgetting to poll
check_oauth_statusand assuming the connection succeeded. - Letting the 15-minute ticket expire before the user finishes.
Related docs
Connecting Channels guide · Tool reference · Check connection health