Quickstart Mode
Create an API key, create a profile, connect your first social account, and publish your first post.
Prerequisite
Create an API key in the dashboard and store it in UNIPOST_API_KEY. The SDKs read it automatically.
- Open Dashboard → API Keys
- Click Create API Key
- Save it as
UNIPOST_API_KEYin your environment
The four steps
POST /v1/profiles and keep the returned profile_id.auth_url in a browser.account_id.At a glance
| Question | Answer |
|---|---|
| Account owner | You or your team — not your customers |
| OAuth style | Self-owned account connection via auth_url |
| What you get back | A profile_id, then an auth_url, then one or more account IDs |
| Best for | Prototypes, internal tools, your own brand accounts |
| Need customer onboarding? | Use White-label / Connect Sessions instead |
Install and initialize
Initialize the client
1. Create a profile
Profiles are the container for connected accounts. Every new API-first integration should create one deliberately instead of relying on the dashboard default.
Full schema: POST/v1/profiles.
2. Connect an account
For OAuth platforms like LinkedIn, X, YouTube, Instagram, Threads, TikTok, Pinterest, and Facebook Page, call the connect URL API. It returns an auth_url. Open that URL in a browser and complete OAuth there.
- Call
POST /v1/oauth/connect - Read
data.auth_urlfrom the response - Open it in a browser
- Complete OAuth in the browser
You can optionally add redirect_url in the request body if you want OAuth to land on your own app afterward, but Quickstart leaves it out to keep the first connection as simple as possible. Endpoint reference: POST/v1/oauth/connect.
Bluesky is the exception. It uses an app password, not OAuth, so connect it through POST/v1/accounts/connect instead.
3. Get your connected account
List accounts for the profile you created and keep the returned UniPost account_id.
Reference: GET/v1/accounts.
4. Schedule your first post
You can publish immediately or schedule for later. You can also target one platform or multiple platforms in the same request.
| Pattern | How it works |
|---|---|
| Immediate, single-platform | One entry in platform_posts and no publishAt |
| Immediate, multi-platform | Multiple entries in platform_posts with different accountId / caption values |
| Scheduled, single-platform | Set publishAt and include one account |
| Scheduled, multi-platform | Set publishAt and include multiple accounts in platform_posts |
Reference: POST/v1/posts.
Publishing to Instagram from a local image or video file has one extra media step: reserve an upload, PUT the bytes, poll until the media row is uploaded, then create the post with media_ids. See the Instagram local file flow.
What this quickstart is not
| Flow | Use this page? | Where to go instead |
|---|---|---|
| Connect your own accounts with OAuth auth_url | ✓ | This page |
| Connect customer-owned accounts | X | White-label / Connect Sessions |
| Connect Bluesky with app password | Partially | POST /v1/accounts/connect |