Setup Guide
Follow these steps to configure Facebook and Instagram API access for your application
This guide is for developers who want to set up their own instance of the application. If you're just using the app, you can skip this and go directly to the dashboard.
Step 1: Create Facebook App
Set up a Facebook Developer account and create an app
- Go to Facebook Developers
- Click "My Apps" and then "Create App"
- Select "Consumer" as the app type
- Enter your app name and contact email
- Click "Create App"
Required for both Facebook and Instagram access
Step 2: Configure Facebook Login
Enable Facebook Login for your application
- In your Facebook App dashboard, click "Add Product"
- Select "Facebook Login" and choose "Web"
- Enter your website URL:
instabook.yggbranch.dev - In Facebook Login settings, add this OAuth redirect URI:
instabook.yggbranch.dev/api/auth/callback/facebook - Request these permissions:
- public_profile
- user_photos
- user_videos
Step 3: Configure Instagram Basic Display
Enable Instagram access for your application
- In your Facebook App dashboard, click "Add Product"
- Select "Instagram Basic Display"
- Add this OAuth redirect URI:
instabook.yggbranch.dev/api/auth/callback/instagram - Under "User Token Generator," add Instagram test users
- Request these permissions:
- user_profile
- user_media
Instagram Basic Display API requires your app to be in "Live" mode for public use. During development, you can only test with accounts that are added as test users.
Step 4: Environment Variables
Configure your application with the API credentials
Copy your App ID and App Secret from your Facebook App dashboard and set these environment variables:
NEXTAUTH_URL=instabook.yggbranch.dev
NEXTAUTH_SECRET=your-nextauth-secret
FACEBOOK_CLIENT_ID=your-facebook-app-id
FACEBOOK_CLIENT_SECRET=your-facebook-app-secret
INSTAGRAM_CLIENT_ID=your-instagram-app-id
INSTAGRAM_CLIENT_SECRET=your-instagram-app-secret
For Instagram, use the same App ID and App Secret from your Facebook App. Instagram Basic Display is a product within your Facebook App.