Create a Post
Publish to Facebook, Instagram, YouTube, Pinterest, LinkedIn, and TikTok with Postifys API examples in cURL, JavaScript, and Python.
Quick answer: Send JSON to a platform endpoint such as
POST /api/instagram/post with your API key. Include media/caption fields required by that network, and pass the connected account id when you manage more than one destination.Publish endpoints
POST /api/facebook/postPOST /api/instagram/postPOST /api/youtube/postPOST /api/pinterest/postPOST /api/linkedin/postPOST /api/tiktok/post
Full field lists live in the API reference. Below are the most common first-publish examples.
Facebook Page example
curl -X POST https://postifys.com/api/facebook/post \
-H "Content-Type: application/json" \
-H "Authorization: Bearer YOUR_API_KEY" \
-d '{
"text": "New image from Postifys API",
"type": "IMAGE",
"mediaUrls": ["https://example.com/image.jpg"],
"pageId": "FACEBOOK_PAGE_ID"
}'Use type values such as IMAGE, REEL, or FEED. pageId is optional when a default Page is configured.
Instagram professional example
curl -X POST https://postifys.com/api/instagram/post \
-H "Content-Type: application/json" \
-H "Authorization: Bearer YOUR_API_KEY" \
-d '{
"type": "IMAGE",
"mediaUrls": ["https://example.com/post-image.jpg"],
"text": "Published by Postifys",
"instagramAccountId": "INSTAGRAM_ACCOUNT_ID"
}'For Reels/videos, set type to REEL or VIDEO. Google Drive links should use proxyDownload: true and be shared as Anyone with the link.
const response = await fetch("https://postifys.com/api/instagram/post", {
method: "POST",
headers: {
"Content-Type": "application/json",
"Authorization": "Bearer YOUR_API_KEY"
},
body: JSON.stringify({
type: "REEL",
mediaUrls: ["https://example.com/reel.mp4"],
text: "New reel",
instagramAccountId: "INSTAGRAM_ACCOUNT_ID"
})
});
const data = await response.json();
console.log(data);YouTube example
curl -X POST https://postifys.com/api/youtube/post \
-H "Content-Type: application/json" \
-H "Authorization: Bearer YOUR_API_KEY" \
-d '{
"title": "Product walkthrough",
"description": "Published via Postifys",
"videoUrl": "https://example.com/walkthrough.mp4",
"privacyStatus": "private"
}'TikTok example (inbox)
Limitation: Current production delivery uploads eligible videos to the TikTok creator inbox. The creator completes publishing inside TikTok. Do not assume Direct Post to a public profile unless that approval exists.
curl -X POST https://postifys.com/api/tiktok/post \
-H "Content-Type: application/json" \
-H "Authorization: Bearer YOUR_API_KEY" \
-d '{
"tiktokAccountId": "OPEN_ID_FROM_CONNECTIONS",
"videoUrl": "https://example.com/video.mp4",
"caption": "Draft for creator review"
}'Python example
import requests
resp = requests.post(
"https://postifys.com/api/facebook/post",
headers={
"Authorization": "Bearer YOUR_API_KEY",
"Content-Type": "application/json",
},
json={
"text": "Hello from Python",
"type": "FEED",
},
timeout=60,
)
print(resp.status_code, resp.text)Check results
- Dashboard Post History for human review
- API history/status routes documented in the API reference
- Status + /health when diagnosing platform vs Postifys availability