
Product
Socket for Jira Is Now Available
Socket for Jira lets teams turn alerts into Jira tickets with manual creation, automated ticketing rules, and two-way sync.
upload-post
Advanced tools
Official client library for Upload-Post API - Cross-platform social media upload for TikTok, Instagram, YouTube, LinkedIn, Facebook, Pinterest, Threads, Reddit, Bluesky, and X (Twitter)
Official Node.js client for the Upload-Post API - Cross-platform social media upload.
Upload videos, photos, text posts, and documents to TikTok, Instagram, YouTube, LinkedIn, Facebook, Pinterest, Threads, Reddit, Bluesky, and X (Twitter) with a single API.
npm install upload-post
import { UploadPost } from 'upload-post';
const client = new UploadPost('YOUR_API_KEY');
// Upload a video to multiple platforms
const response = await client.upload('./video.mp4', {
title: 'Check out this awesome video! 🎬',
user: 'my-profile',
platforms: ['tiktok', 'instagram', 'youtube']
});
console.log(response);
const response = await client.upload('./video.mp4', {
title: 'My awesome video',
user: 'my-profile',
platforms: ['tiktok', 'instagram', 'youtube'],
// Optional: Schedule for later
scheduledDate: '2024-12-25T10:00:00Z',
timezone: 'Europe/Madrid',
// Optional: Add first comment
firstComment: 'Thanks for watching! 🙏',
// Optional: Platform-specific settings
tiktokPrivacyLevel: 'PUBLIC_TO_EVERYONE',
instagramMediaType: 'REELS',
youtubePrivacyStatus: 'public',
youtubeTags: ['tutorial', 'coding'],
});
// Upload single or multiple photos
const response = await client.uploadPhotos(
['./photo1.jpg', './photo2.jpg', 'https://example.com/photo3.jpg'],
{
title: 'Check out these photos! 📸',
user: 'my-profile',
platforms: ['instagram', 'facebook', 'x'],
// Optional: Add to queue instead of posting immediately
addToQueue: true,
// Platform-specific
instagramMediaType: 'IMAGE', // or 'STORIES'
facebookPageId: 'your-page-id',
}
);
const response = await client.uploadText({
title: 'Just shipped a new feature! 🚀 Check it out at example.com',
user: 'my-profile',
platforms: ['x', 'linkedin', 'threads'],
// Optional: Create a poll on X
xPollOptions: ['Option A', 'Option B', 'Option C'],
xPollDuration: 1440, // 24 hours in minutes
// Optional: Post to a LinkedIn company page
targetLinkedinPageId: 'company-page-id',
});
const response = await client.uploadDocument('./presentation.pdf', {
title: 'Q4 2024 Report',
user: 'my-profile',
description: 'Check out our latest quarterly results!',
linkedinVisibility: 'PUBLIC',
targetLinkedinPageId: 'company-page-id', // Optional: post to company page
});
For async uploads, check the status using the request_id:
const status = await client.getStatus('request_id_from_upload');
console.log(status);
For scheduled or queued posts, check the status using the job_id:
const status = await client.getJobStatus('job_id_from_scheduled_post');
console.log(status);
const history = await client.getHistory({ page: 1, limit: 20 });
console.log(history.uploads);
// List all scheduled posts
const scheduled = await client.listScheduled();
// Edit a scheduled post
await client.editScheduled('job-id', {
scheduledDate: '2024-12-26T15:00:00Z',
timezone: 'America/New_York',
});
// Cancel a scheduled post
await client.cancelScheduled('job-id');
// List all profiles
const users = await client.listUsers();
// Create a new profile
await client.createUser('new-profile');
// Delete a profile
await client.deleteUser('old-profile');
// Generate JWT for platform integration (white-label)
const jwt = await client.generateJwt('my-profile', {
redirectUrl: 'https://yourapp.com/callback',
platforms: ['tiktok', 'instagram'],
});
const analytics = await client.getAnalytics('my-profile', {
platforms: ['instagram', 'tiktok'],
});
console.log(analytics);
// Get Facebook pages for a profile
const fbPages = await client.getFacebookPages('my-profile');
// Get LinkedIn pages for a profile
const liPages = await client.getLinkedinPages('my-profile');
// Get Pinterest boards for a profile
const boards = await client.getPinterestBoards('my-profile');
tiktokPrivacyLevel - PUBLIC_TO_EVERYONE, MUTUAL_FOLLOW_FRIENDS, FOLLOWER_OF_CREATOR, SELF_ONLYtiktokDisableDuet - Disable duettiktokDisableComment - Disable commentstiktokDisableStitch - Disable stitchtiktokCoverTimestamp - Timestamp in ms for covertiktokIsAigc - AI-generated content flagtiktokPostMode - DIRECT_POST or MEDIA_UPLOADbrandContentToggle - Branded content togglebrandOrganicToggle - Brand organic toggletiktokAutoAddMusic - Auto add musictiktokPhotoCoverIndex - Index of photo for cover (0-based)tiktokDisableComment - Disable commentsinstagramMediaType - REELS, STORIES, IMAGEinstagramShareToFeed - Share to feed (for Reels/Stories)instagramCollaborators - Comma-separated collaborator usernamesinstagramCoverUrl - Custom cover URLinstagramAudioName - Audio track nameinstagramUserTags - Comma-separated user tagsinstagramLocationId - Location IDinstagramThumbOffset - Thumbnail offsetyoutubeTags - Array or comma-separated tagsyoutubeCategoryId - Category ID (default: "22" People & Blogs)youtubePrivacyStatus - public, unlisted, privateyoutubeEmbeddable - Allow embeddingyoutubeLicense - youtube, creativeCommonyoutubePublicStatsViewable - Show public statsyoutubeThumbnailUrl - Custom thumbnail URLyoutubeSelfDeclaredMadeForKids - Made for kids (COPPA)youtubeContainsSyntheticMedia - AI/synthetic content flagyoutubeDefaultLanguage - Title/description language (BCP-47)youtubeDefaultAudioLanguage - Audio language (BCP-47)youtubeAllowedCountries / youtubeBlockedCountries - Country restrictionsyoutubeHasPaidProductPlacement - Paid placement flagyoutubeRecordingDate - Recording date (ISO 8601)linkedinVisibility - PUBLIC, CONNECTIONS, LOGGED_IN, CONTAINERtargetLinkedinPageId - Page ID for organization postsfacebookPageId - Facebook Page ID (required)facebookVideoState - PUBLISHED, DRAFTfacebookMediaType - REELS, STORIES, VIDEO (VIDEO for normal page videos with no 9:16 restriction)thumbnailUrl - URL for custom video thumbnail (only when facebookMediaType is VIDEO)facebookLinkUrl - URL for text postspinterestBoardId - Board IDpinterestLink - Destination linkpinterestAltText - Alt text for photospinterestCoverImageUrl - Cover image URL (video)pinterestCoverImageKeyFrameTime - Key frame time in msxReplySettings - everyone, following, mentionedUsers, subscribers, verifiedxNullcast - Promoted-only postxTaggedUserIds - User IDs to tagxPlaceId / xGeoPlaceId - Location place IDxQuoteTweetId - Tweet ID to quotexPollOptions - Poll options (2-4)xPollDuration - Poll duration in minutes (5-10080)xForSuperFollowersOnly - Exclusive for super followersxCommunityId - Community IDxShareWithFollowers - Share community post with followersxCardUri - Card URI for Twitter CardsxLongTextAsPost - Post long text as single postxThreadImageLayout - Comma-separated image layout for thread (e.g. "4,4" or "2,3,1")threadsLongTextAsPost - Post long text as single post (vs thread)threadsThreadMediaLayout - Comma-separated list of how many media items to include in each Threads post. Each value must be 1-10, and the total must equal the number of files. Example: '5,5' splits 10 items into 2 posts with 5 each. If omitted and more than 10 items are provided, auto-chunks into groups of 10.threadsTopicTag - Topic tag for the Threads post (1-50 characters, no periods or ampersands). One tag per post. Helps increase reach.redditSubreddit - Subreddit name (without r/)redditFlairId - Flair template IDThese options work across all upload methods:
| Option | Description |
|---|---|
title | Post title/caption (required) |
user | Profile name (required) |
platforms | Target platforms array (required) |
firstComment | First comment to post |
altText | Alt text for accessibility |
scheduledDate | ISO date for scheduling |
timezone | Timezone for scheduled date |
addToQueue | Add to posting queue |
maxPostsPerSlot | Max posts per queue slot (overrides profile setting) |
asyncUpload | Process asynchronously (default: true) |
Full TypeScript support with comprehensive type definitions:
import { UploadPost, UploadVideoOptions, UploadResponse } from 'upload-post';
const client = new UploadPost('YOUR_API_KEY');
const options: UploadVideoOptions = {
title: 'My video',
user: 'my-profile',
platforms: ['tiktok', 'instagram'],
tiktokPrivacyLevel: 'PUBLIC_TO_EVERYONE',
};
const response: UploadResponse = await client.upload('./video.mp4', options);
try {
const response = await client.upload('./video.mp4', options);
console.log('Upload successful:', response);
} catch (error) {
console.error('Upload failed:', error.message);
}
MIT
FAQs
Official client library for Upload-Post API - Cross-platform social media upload for TikTok, Instagram, YouTube, LinkedIn, Facebook, Pinterest, Threads, Reddit, Bluesky, and X (Twitter)
The npm package upload-post receives a total of 790 weekly downloads. As such, upload-post popularity was classified as not popular.
We found that upload-post demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Product
Socket for Jira lets teams turn alerts into Jira tickets with manual creation, automated ticketing rules, and two-way sync.

Company News
Socket won two 2026 Reppy Awards from RepVue, ranking in the top 5% of all sales orgs. AE Alexandra Lister shares what it's like to grow a sales career here.

Security News
NIST will stop enriching most CVEs under a new risk-based model, narrowing the NVD's scope as vulnerability submissions continue to surge.