Supported Platforms
Postiz supports the following OAuth-based platforms:- X (Twitter) - Post tweets, threads, and retweets
- LinkedIn - Personal profiles and company pages
- Facebook - Facebook Pages posting
- Instagram - Through Facebook Graph API
- YouTube - Video uploads and community posts
- TikTok - Video content posting
- Reddit - Subreddit posting
- Pinterest - Pin and board management
- Threads - Meta’s text-based platform
- GitHub - Repository discussions
- Discord - Channel messaging
- Slack - Workspace messaging
- Dribbble - Design portfolio posts
- Mastodon - Federated social network
Environment Variables
Add the following environment variables to your.env file for the platforms you want to enable:
You only need to configure the platforms you plan to use. Missing credentials will simply disable that platform in the UI.
Platform Setup Guides
Create OAuth Application
Visit the developer portal for each platform you want to integrate:
- X: developer.twitter.com/apps
- LinkedIn: linkedin.com/developers/apps
- Facebook: developers.facebook.com/apps
- YouTube: console.cloud.google.com
- TikTok: developers.tiktok.com
- Reddit: reddit.com/prefs/apps
- GitHub: github.com/settings/developers
Configure Redirect URLs
Set the OAuth callback URL to:Replace
{platform} with the platform identifier:xfor X (Twitter)linkedinfor LinkedInfacebookfor Facebookyoutubefor YouTubetiktokfor TikTokredditfor Redditgithubfor GitHub- etc.
Configure Scopes
Each platform requires specific OAuth scopes. The application automatically requests the correct scopes:LinkedIn Scopes (from
linkedin.provider.ts:28-36):openidprofilew_member_socialr_basicprofilerw_organization_adminw_organization_socialr_organization_social
facebook.provider.ts:19-26):pages_show_listbusiness_managementpages_manage_postspages_manage_engagementpages_read_engagementread_insights
OAuth Flow Implementation
Postiz implements a standard OAuth 2.0 flow with refresh token support:Token Refresh
Most platforms support automatic token refresh. Example fromlinkedin.provider.ts:66-84:
Postiz automatically refreshes tokens when they expire, ensuring uninterrupted posting.
Platform-Specific Configuration
X (Twitter)
X requires elevated API access for posting. Apply for elevated access at developer.twitter.com.Facebook & Instagram
Facebook uses a two-step OAuth flow (isBetweenSteps = true) where users first authenticate with Facebook, then select which Pages to manage.
Instagram posting is handled through the Facebook Graph API using the same credentials.
Discord
Discord requires both OAuth credentials and a bot token:Slack
Slack requires an additional signing secret for webhook verification:Mastodon
Mastodon is federated, so you can configure a custom instance URL:Testing OAuth Integration
Troubleshooting
Redirect URI mismatch error
Redirect URI mismatch error
Ensure your OAuth app’s redirect URI exactly matches:Check that
NEXT_PUBLIC_BACKEND_URL in your .env file is correct and accessible.Access token expired errors
Access token expired errors
Postiz automatically refreshes tokens for most platforms. If you see persistent token errors:
- Disconnect and reconnect the account
- Verify your OAuth app has the
offline_accessscope (if applicable) - Check that your Client Secret is correct
Platform not appearing in UI
Platform not appearing in UI
If a platform doesn’t appear in the integrations list:
- Verify the environment variables are set correctly
- Restart the backend service:
docker compose restart backend - Check backend logs for initialization errors
Rate limit errors
Rate limit errors
Each platform has different rate limits. Postiz respects these through the
maxConcurrentJob setting:- X: 1 concurrent job (strict limits)
- LinkedIn: 2 concurrent jobs
- Facebook: 100 concurrent jobs
Newsletter Platforms
Some platforms use API keys instead of OAuth:Chrome Extension for Cookie-Based Platforms
Some platforms (like Skool) require cookie-based authentication via the Chrome extension:Security Best Practices
- Store OAuth secrets in environment variables, never in code
- Use HTTPS for production deployments
- Regularly rotate OAuth client secrets
- Monitor OAuth app permissions and revoke unused access
- Implement proper access controls for your Postiz instance
Next Steps
After configuring OAuth apps:- Email Setup - Configure transactional emails
- AI Integration - Enable AI-powered post generation
- Billing Configuration - Set up Stripe for payments