Create an OAuth connect URL
Initiates an OAuth connection flow and returns an authorization URL to redirect the user to. The OAuth state expires after 10 minutes. This endpoint requires a read-write API key.
For bluesky, the returned authUrl is a PostZen-hosted page where the user enters their Bluesky handle and app password (no developer app or OAuth redirect is required); the connection completes when they submit that form.
For telegram, the returned authUrl is a PostZen-hosted page that issues a short-lived access code (there is no OAuth grant and no Telegram authorization screen); the connection completes when the user adds @PostZenScheduleBot as an administrator of a channel or group and sends that code to the bot.
Authorization
bearerAuth PostZen API key.
In: header
Path Parameters
Social platform to connect. twitter is accepted as an alias for x.
Query Parameters
PostZen profile id to attach the connected account to.
Custom URL PostZen redirects to after the connection completes.
Response Body
application/json
application/json
application/json
application/json
application/json
application/json
application/json
curl -X GET "https://example.com/v1/connect/twitter?profileId=string"{ "authUrl": "https://www.linkedin.com/oauth/v2/authorization?response_type=code&client_id=86xk2ab9cdef01&state=3q2Xv8Zk1mR5tY7wA9bC4dE6&scope=openid%20profile%20w_member_social%20email", "state": "3q2Xv8Zk1mR5tY7wA9bC4dE6"}{ "error": "JSON body is required"}{ "error": "Unauthorized"}{ "error": "The Free plan includes 2 connected accounts. Upgrade your plan to connect more.", "code": "paymentRequired", "reason": "freeTierExceeded", "documentationUrl": "https://docs.postzen.dev/api-reference/connect/create-connect-url", "dashboardUrl": "https://app.postzen.dev/settings?tab=billing", "details": { "planId": "free", "includedAccounts": 2, "freeTierAccountLimit": 2, "currentAccountCount": 2, "hasPaymentMethod": false }}{ "error": "API key requires read_write permission"}{ "error": "Not found"}{ "error": "Failed to create post"}Select Pinterest board POST
Verifies and stores the default board for the Pinterest account created by the connect session. This endpoint requires a read-write API key.
Complete an OAuth connection POST
Exchanges an OAuth authorization code for tokens and connects the account to the specified profile. This endpoint requires a read-write API key.