Skip to main content
RapidDev - Software Development Agency
bolt-ai-integrationsBolt Chat + API Route

How to Integrate Bolt.new with SocialBee

Connect SocialBee to Bolt.new by obtaining an API key from your SocialBee account settings, then building API routes that proxy requests to SocialBee's REST API for scheduling posts, managing content categories, and fetching analytics. SocialBee API access requires a higher-tier plan. Outbound API calls work in Bolt's WebContainer preview — incoming webhooks require a deployed URL on Netlify or Bolt Cloud.

What you'll learn

  • How to obtain a SocialBee API key and configure it in your Bolt.new project
  • How to schedule social media posts to SocialBee content categories via the REST API
  • How to build a social media calendar dashboard displaying scheduled posts
  • How to fetch post performance analytics from SocialBee's API
  • How to manage content categories and evergreen recycling queues programmatically
Book a free consultation
4.9Clutch rating
600+Happy partners
17+Countries served
190+Team members
Intermediate15 min read25 minutesMarketingApril 2026RapidDev Engineering Team
TL;DR

Connect SocialBee to Bolt.new by obtaining an API key from your SocialBee account settings, then building API routes that proxy requests to SocialBee's REST API for scheduling posts, managing content categories, and fetching analytics. SocialBee API access requires a higher-tier plan. Outbound API calls work in Bolt's WebContainer preview — incoming webhooks require a deployed URL on Netlify or Bolt Cloud.

Build a Social Media Scheduling Dashboard with SocialBee and Bolt.new

SocialBee's defining feature is content category recycling — rather than scheduling posts one-off, you assign content to categories (like 'Educational', 'Promotional', or 'Evergreen Tips') and SocialBee cycles through each category on a schedule. When a post has been published, it moves back to the queue to be published again in the future. This approach maintains consistent social media presence without requiring you to constantly create new content. Bolt.new lets you build custom interfaces on top of SocialBee's API to manage this content system programmatically.

The integration uses SocialBee's REST API, which requires an API key from your account settings. API access is available on higher-tier SocialBee plans (Pro and Agency levels). The API covers the core content management operations: creating and scheduling posts, managing category queues, and fetching performance analytics across connected social profiles. Building a Bolt app on top of the SocialBee API is valuable when you need to batch-import content, integrate with other tools in your marketing stack, or build a custom dashboard for your team that surfaces the specific metrics you care about.

For developers building content tools, SocialBee's category system is particularly interesting to work with programmatically — you can assign posts to the right category automatically based on content type, tag, or source. A Bolt app that pulls blog posts from your CMS, generates social-friendly excerpts, and adds them directly to the appropriate SocialBee category queue can save significant manual work for teams with high publishing frequency.

Integration method

Bolt Chat + API Route

Bolt.new connects to SocialBee through server-side API routes that proxy authenticated requests to SocialBee's REST API. The integration covers scheduling posts to content categories, fetching post analytics, and managing the content calendar. Because SocialBee's API key is sensitive, all requests flow through server-side routes that keep the key out of client-side code. Outbound SocialBee API calls work in Bolt's WebContainer preview during development.

Prerequisites

  • A SocialBee account on a plan that includes API access (Pro or Agency tier — check socialbee.com/pricing)
  • Your SocialBee API key from Account Settings → API (or request from SocialBee support if not visible)
  • At least one social profile connected in SocialBee with content categories configured
  • A Bolt.new project (Next.js or Vite)
  • Understanding of SocialBee's category-based scheduling model before building the integration

Step-by-step guide

1

Obtain Your SocialBee API Key and Understand the API Structure

SocialBee's REST API requires an API key for authentication. Log in to your SocialBee account and navigate to your account settings — look for an API or Integrations section. The API key is typically available on Pro and Agency plans; if you don't see it, contact SocialBee support or check your plan's features. Once you have the API key, store it in your Bolt project's .env file as SOCIALBEE_API_KEY. Before building any API routes, it's worth understanding SocialBee's core data model: Profiles (connected social media accounts — Facebook, Instagram, Twitter, LinkedIn, Pinterest, TikTok), Categories (content buckets that cycle through posting schedules), and Posts (individual pieces of content assigned to a category and profile combination). The API is organized around these entities. All API requests use Bearer token authentication with your API key in the Authorization header. SocialBee's API uses standard REST conventions with JSON request and response bodies. Rate limits depend on your plan — Pro plans typically allow several hundred requests per hour. Build token-efficient API routes that fetch only the data you need and cache responses where appropriate. The base API URL is typically https://app.socialbee.com/api/v1 — verify this in SocialBee's developer documentation or by contacting support, as API URLs can change.

Bolt.new Prompt

Set up a SocialBee API integration for my Bolt app. Create a utility file lib/socialbee.ts that exports a socialBeeRequest(endpoint, method?, body?) function. It should: fetch from https://app.socialbee.com/api/v1/${endpoint}, add Authorization: Bearer ${process.env.SOCIALBEE_API_KEY} header, and return the parsed JSON response. Also export getProfiles(), getCategories(), and getPosts(status?, profileId?) helper functions. Add SOCIALBEE_API_KEY to the .env file as a placeholder. Create an API route GET /api/socialbee/profiles that returns all connected social profiles.

Paste this in Bolt.new chat

lib/socialbee.ts
1// lib/socialbee.ts
2const SOCIALBEE_BASE = 'https://app.socialbee.com/api/v1';
3
4async function socialBeeRequest<T>(
5 endpoint: string,
6 method: string = 'GET',
7 body?: Record<string, unknown>
8): Promise<T> {
9 const response = await fetch(`${SOCIALBEE_BASE}/${endpoint}`, {
10 method,
11 headers: {
12 Authorization: `Bearer ${process.env.SOCIALBEE_API_KEY}`,
13 'Content-Type': 'application/json',
14 },
15 ...(body ? { body: JSON.stringify(body) } : {}),
16 });
17
18 if (!response.ok) {
19 throw new Error(`SocialBee API error: ${response.status} ${response.statusText}`);
20 }
21
22 return response.json();
23}
24
25export const getProfiles = () => socialBeeRequest('profiles');
26export const getCategories = () => socialBeeRequest('categories');
27export const getPosts = (status?: string, profileId?: string) => {
28 const params = new URLSearchParams();
29 if (status) params.set('status', status);
30 if (profileId) params.set('profile_id', profileId);
31 const query = params.toString();
32 return socialBeeRequest(`posts${query ? '?' + query : ''}`);
33};
34
35export const createPost = (data: Record<string, unknown>) =>
36 socialBeeRequest('posts', 'POST', data);

Pro tip: SocialBee API access is plan-dependent. If you get a 403 Forbidden response with a valid API key, your current plan may not include API access — check socialbee.com/pricing or contact SocialBee support to confirm API availability on your plan.

Expected result: The SocialBee utility is set up and the /api/socialbee/profiles route returns your connected social profiles as JSON.

2

Build the Post Scheduling Interface

With the SocialBee API utility ready, build the core scheduling interface — a form where users can compose a post, select which content category to assign it to, choose target social profiles, optionally upload an image, and submit it to SocialBee. The SocialBee API accepts new posts via a POST request to the posts endpoint with the post content, category ID, and profile IDs. Fetch available categories and profiles on component mount so users can select from dropdowns populated with their actual SocialBee data. When a post is created via the API, SocialBee adds it to the selected category's queue. The post will be published according to the category's posting schedule — SocialBee manages the timing automatically based on your category schedule configuration. For image attachments, SocialBee's API typically accepts image URLs rather than file uploads — host images on a CDN or Supabase Storage and pass the URL in the API request. If your Bolt app uses Supabase, you can upload images to Supabase Storage and pass the resulting public URL to SocialBee. Implementing the scheduling form with proper error handling is important — SocialBee may reject posts that are too long for certain platforms (Twitter's 280 character limit vs. Facebook's longer limit), so add character count validation per platform. A character counter that shows remaining characters based on the most restrictive platform in the selected targets is a useful UX addition.

Bolt.new Prompt

Build a social media post composer form for SocialBee. On load, fetch categories from /api/socialbee/categories and profiles from /api/socialbee/profiles to populate the dropdowns. The form has: a textarea for the caption (show character count, max 280 for Twitter safety), an optional image URL input, a multi-select for profiles (checkboxes), and a category dropdown. On submit, POST to /api/socialbee/schedule with { caption, image_url, category_id, profile_ids }. The API route should call SocialBee's POST /posts endpoint. Show success with the post ID returned by SocialBee, or display the error message if the API rejects it.

Paste this in Bolt.new chat

app/api/socialbee/schedule/route.ts
1// app/api/socialbee/schedule/route.ts
2import { NextRequest, NextResponse } from 'next/server';
3import { createPost } from '@/lib/socialbee';
4
5export async function POST(request: NextRequest) {
6 const { caption, image_url, category_id, profile_ids } = await request.json();
7
8 if (!caption || !category_id || !profile_ids?.length) {
9 return NextResponse.json(
10 { error: 'caption, category_id, and profile_ids are required' },
11 { status: 400 }
12 );
13 }
14
15 if (caption.length > 2200) {
16 return NextResponse.json(
17 { error: 'Caption exceeds maximum length' },
18 { status: 400 }
19 );
20 }
21
22 try {
23 const result = await createPost({
24 content: caption,
25 ...(image_url ? { media: [{ url: image_url }] } : {}),
26 category_id,
27 profile_ids,
28 });
29
30 return NextResponse.json(result);
31 } catch (error) {
32 console.error('SocialBee post creation failed:', error);
33 return NextResponse.json(
34 { error: 'Failed to create post in SocialBee' },
35 { status: 500 }
36 );
37 }
38}

Pro tip: SocialBee's content categories have their own posting schedules. When you add a post via the API, SocialBee queues it to publish based on the category's next available slot — you don't need to specify a publish time unless you want to pin it to a specific date.

Expected result: Submitting the compose form creates a new post in SocialBee and adds it to the selected category queue. Verify in your SocialBee dashboard that the post appears in the category.

3

Build the Content Calendar Dashboard

The content calendar view is the centerpiece of most social media management dashboards — it shows all scheduled posts in a visual grid so your team can spot gaps in coverage, check the content mix across categories, and plan ahead. Build the calendar using scheduled post data from the SocialBee API combined with React state management. Fetch scheduled posts for the current month on load. Each post has metadata including the content, category, target profiles, and the scheduled publication time (which SocialBee calculates based on the category schedule). Group posts by day and display them in a monthly grid layout. Use category colors to visually distinguish content types — assign a color to each category name in your app's configuration. A useful addition is a category distribution bar or pie chart showing the current month's post count per category — teams managing content for multiple brands or products benefit from seeing whether categories are balanced. For the calendar itself, you can build a simple grid with CSS grid or use a React calendar library. Each day cell shows the post count and category badges. Clicking a day expands a detail panel showing all posts for that day with edit or delete options. Real-time updates (polling every few minutes) keep the calendar current if multiple team members are adding content. Important: the SocialBee API call to fetch posts works in Bolt's WebContainer preview since it's an outbound HTTP call — no deployment needed to build and test the dashboard.

Bolt.new Prompt

Build a monthly content calendar for SocialBee. Fetch scheduled posts from /api/socialbee/posts with status=scheduled. Display a 5x7 grid for the current month (use date-fns for date manipulation). Each day shows colored dots for posts, with category name as the dot color legend. Include a sidebar listing all posts for the selected day when a date is clicked. Add a month navigation (Previous/Next buttons). Show a mini analytics panel below the calendar with: total posts scheduled this month, posts per platform (horizontal bar chart), and most active day of week. Use the profiles and categories from /api/socialbee/profiles and /api/socialbee/categories.

Paste this in Bolt.new chat

app/api/socialbee/posts/route.ts
1// app/api/socialbee/posts/route.ts
2import { NextRequest, NextResponse } from 'next/server';
3import { getPosts } from '@/lib/socialbee';
4
5export async function GET(request: NextRequest) {
6 const { searchParams } = new URL(request.url);
7 const status = searchParams.get('status') || undefined;
8 const profileId = searchParams.get('profile_id') || undefined;
9
10 try {
11 const data = await getPosts(status, profileId);
12 return NextResponse.json(data);
13 } catch (error) {
14 console.error('SocialBee posts fetch failed:', error);
15 return NextResponse.json({ error: 'Failed to fetch posts' }, { status: 500 });
16 }
17}
18
19// app/api/socialbee/categories/route.ts
20import { NextResponse } from 'next/server';
21import { getCategories } from '@/lib/socialbee';
22
23export async function GET() {
24 try {
25 const data = await getCategories();
26 return NextResponse.json(data);
27 } catch (error) {
28 return NextResponse.json({ error: 'Failed to fetch categories' }, { status: 500 });
29 }
30}

Pro tip: SocialBee's scheduled post times are calculated by the platform based on your category's posting schedule. Display these times in the user's local timezone using Intl.DateTimeFormat rather than hardcoding a timezone offset.

Expected result: The dashboard displays a monthly calendar showing all SocialBee scheduled posts with category color coding. Clicking a date shows the day's posts in a detail sidebar.

4

Deploy and Configure Webhooks for Real-Time Updates

After deploying your Bolt app to Netlify or Bolt Cloud, you can configure SocialBee webhooks to receive real-time notifications when posts are published, content categories are updated, or team members make changes. This enables your dashboard to show live status updates without polling. Deploy your Bolt app using Bolt's built-in publish feature (click Publish → Bolt Cloud) or by connecting your GitHub repository to Netlify. Once deployed, you'll have a stable public URL like https://your-app.netlify.app or https://your-project.bolt.host. In your Bolt project settings or Netlify's environment variables panel, add SOCIALBEE_API_KEY to the production environment. In SocialBee's account settings, find the Webhooks section and register your deployed URL as the webhook endpoint (e.g., https://your-app.netlify.app/api/socialbee/webhook). SocialBee will send POST requests to this URL whenever configured events occur. The webhook handler should parse the incoming payload, identify the event type, and update your Bolt app's state accordingly — for example, marking a post as published in your calendar view or triggering a re-fetch of the post list. During Bolt development in the WebContainer, incoming webhooks from SocialBee cannot reach the preview URL because WebContainers have no public-facing port. This is a fundamental constraint of the browser-based runtime. Your outbound API calls to SocialBee work fine in development, but webhook receipt requires a deployed environment.

Bolt.new Prompt

Create a SocialBee webhook handler at /api/socialbee/webhook. It should accept POST requests from SocialBee, parse the JSON payload, and handle these event types: 'post.published' (log the post ID and update a posts cache), 'post.failed' (log the error), and 'category.updated' (log the category change). Add basic validation to confirm the request includes expected SocialBee payload fields. Add SOCIALBEE_WEBHOOK_SECRET to .env for future signature verification. Return 200 OK for all handled events.

Paste this in Bolt.new chat

app/api/socialbee/webhook/route.ts
1// app/api/socialbee/webhook/route.ts
2import { NextRequest, NextResponse } from 'next/server';
3
4export async function POST(request: NextRequest) {
5 let payload: Record<string, unknown>;
6
7 try {
8 payload = await request.json();
9 } catch {
10 return NextResponse.json({ error: 'Invalid JSON' }, { status: 400 });
11 }
12
13 const { event, data } = payload as { event: string; data: Record<string, unknown> };
14
15 switch (event) {
16 case 'post.published':
17 console.log('SocialBee post published:', data?.post_id);
18 // Optionally: invalidate cache, send notification, update DB
19 break;
20 case 'post.failed':
21 console.error('SocialBee post failed:', data?.post_id, data?.error);
22 break;
23 case 'category.updated':
24 console.log('SocialBee category updated:', data?.category_id);
25 break;
26 default:
27 console.log('Unhandled SocialBee webhook event:', event);
28 }
29
30 return NextResponse.json({ received: true });
31}

Pro tip: SocialBee webhooks require a deployed URL — the WebContainer preview has no stable public URL for SocialBee to send events to. Build and test your core scheduling features in the preview, then configure webhooks after deploying to Netlify or Bolt Cloud.

Expected result: After deployment, SocialBee sends webhook notifications to your app when posts are published. The dashboard reflects real-time post status changes.

Common use cases

Batch Social Post Import from CSV or CMS

Upload a CSV of social media posts (caption, image URL, category, platform targets) and have them automatically added to the correct SocialBee content categories. This replaces manual copy-paste for content teams that prepare posts in spreadsheets or content management systems.

Bolt.new Prompt

Build a CSV import tool for SocialBee. Create a file upload component that accepts a CSV with columns: caption, image_url, category_name, platforms (comma-separated). On upload, parse the CSV and for each row, call POST /api/socialbee/posts to create a post in SocialBee's API, assigning it to the matching category by name. Show a progress bar and a results table with status (created/failed) for each row. Use the SOCIALBEE_API_KEY env var for authentication.

Copy this prompt to try it in Bolt.new

Content Calendar Dashboard

Build a visual content calendar that shows all posts scheduled across your SocialBee categories for the next 30 days. The calendar displays posts grouped by day, shows which social networks each post targets, and includes category color-coding so your team can see the content mix at a glance.

Bolt.new Prompt

Create a monthly content calendar dashboard for SocialBee. Fetch scheduled posts from GET /api/socialbee/posts?status=scheduled using the SocialBee REST API. Display them in a calendar grid layout (month view) with colored badges per category. Each post cell shows the caption preview and which platforms it targets (Instagram, Facebook, Twitter). Add a filter dropdown to show posts from a specific SocialBee profile or category. Use Recharts to show a bar chart of posts per day for the current week.

Copy this prompt to try it in Bolt.new

Category Queue Analytics

Monitor how content categories are performing across social platforms — posts per category, average engagement per category, and which categories drive the most clicks or reach. This helps teams optimize their content mix and identify underperforming categories to refresh.

Bolt.new Prompt

Build a SocialBee analytics dashboard showing category performance. Fetch all content categories from the SocialBee API and for each, fetch recent post analytics. Display a comparison table with columns: Category Name, Posts This Month, Avg Likes, Avg Comments, Avg Reach, Top Post. Add a pie chart showing what percentage of total posts comes from each category. Use the SOCIALBEE_API_KEY env var and proxy all requests through /api/socialbee/ routes.

Copy this prompt to try it in Bolt.new

Troubleshooting

SocialBee API returns 403 Forbidden even with the correct API key

Cause: API access is not included in your current SocialBee plan, or the API key has been revoked or regenerated.

Solution: Verify API access is included in your SocialBee plan (Pro or Agency level required). Check your current plan at socialbee.com/account/billing. If you recently upgraded, regenerate the API key in account settings. Contact SocialBee support to confirm API access on your plan level.

Posts are being created via the API but not appearing in SocialBee's category queues

Cause: The category_id or profile_ids in the API request don't match existing SocialBee categories or profiles, or the post content violates a platform character limit.

Solution: Fetch categories and profiles from the API first and log their IDs to confirm you're using the correct values. Check that the caption length doesn't exceed the most restrictive platform limit (280 characters for Twitter). Review the full API response for error details — SocialBee typically returns a descriptive error message in the response body.

SocialBee API calls work in development but fail after deploying to Netlify

Cause: The SOCIALBEE_API_KEY environment variable is not set in the Netlify production environment.

Solution: In Netlify, go to Site Configuration → Environment Variables and add SOCIALBEE_API_KEY. Trigger a new deployment after adding the variable. Netlify does not automatically pick up .env file values — all production environment variables must be set explicitly in the Netlify dashboard.

Best practices

  • Never expose your SocialBee API key in client-side code or Vite's VITE_ prefixed environment variables — always proxy SocialBee API calls through server-side API routes
  • Fetch categories and profiles once on app load and cache them in React state rather than re-fetching on every post creation — these rarely change
  • Add character count validation per social platform before submitting posts to the API — SocialBee will reject posts that exceed platform-specific character limits
  • Use SocialBee's content category system as designed — assign posts to categories programmatically based on content type rather than creating one-off posts, to benefit from the evergreen recycling feature
  • Implement pagination for post list API routes — accounts with large content libraries can have hundreds of scheduled posts, and fetching all at once can be slow
  • Test all outbound SocialBee API calls in Bolt's WebContainer preview during development — they work fine. Configure webhooks only after deploying to a stable public URL.
  • Cache analytics responses for at least 15 minutes — SocialBee analytics data doesn't update in real-time and frequent polling wastes API quota

Alternatives

Frequently asked questions

Does SocialBee's API work in Bolt.new's WebContainer preview?

Outbound API calls to SocialBee work fine in the preview — you can fetch posts, categories, and profiles, and create new posts during development. The limitation is incoming traffic: SocialBee webhooks cannot reach the preview's dynamic URL. Deploy to Netlify or Bolt Cloud before configuring webhooks for real-time updates.

What SocialBee plan is needed for API access?

API access is generally available on SocialBee's Pro and Agency plans. The free and basic plans typically do not include API access. Check your current plan features at socialbee.com/account or contact SocialBee support to confirm whether your plan includes API access before building the integration.

How does SocialBee's content category recycling work via the API?

When you create a post via the API and assign it to a category, SocialBee adds it to that category's queue. Once published, the post is moved to the back of the queue to be published again in the future — this is the evergreen recycling feature. If you want a post to publish only once, SocialBee provides an 'expire after publishing' option in the post creation API. Categories each have their own posting schedule that determines how frequently they publish.

Can I use SocialBee to post on behalf of my users' social accounts?

No — SocialBee's API connects to social accounts that are manually connected in your SocialBee account's settings by you or your team. There is no OAuth flow to connect end users' personal social accounts through the API. For apps where users connect their own social accounts, use the native social platform APIs (Facebook Graph API, Twitter API v2) or a platform like Buffer that supports OAuth-based user account connections.

How do I handle SocialBee API rate limits in my Bolt app?

SocialBee's rate limits depend on your plan level. Implement response caching for frequently accessed data (categories, profiles) and use pagination to fetch posts in smaller batches. If you receive a 429 Too Many Requests response, implement exponential backoff retry logic in your API routes. For dashboard use cases, caching categories and profiles for 10-15 minutes significantly reduces API calls.

RapidDev

Talk to an Expert

Our team has built 600+ apps. Get personalized help with your project.

Book a free consultation

Need help with your project?

Our experts have built 600+ apps and can accelerate your development. Book a free consultation — no strings attached.

Book a free consultation

We put the rapid in RapidDev

Need a dedicated strategic tech and growth partner? Discover what RapidDev can do for your business! Book a call with our team to schedule a free, no-obligation consultation. We'll discuss your project and provide a custom quote at no cost.