curl -X POST https://api.infinipost.co/v1/posts/slideshow \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"accountIds": ["acc_123", "acc_456"],
"contentUrls": [
"https://example.com/slide1.jpg",
"https://example.com/slide2.jpg",
"https://example.com/slide3.jpg"
],
"caption": "Swipe for more! π",
"soundId": "sound_abc123",
"markAI": false,
"slideDuration": 6,
"renderAsVideo": false,
"scheduledTime": "2024-04-22T14:00",
"timezone": "America/New_York"
}'
const response = await fetch('https://api.infinipost.co/v1/posts/slideshow', {
method: 'POST',
headers: {
'Authorization': 'Bearer YOUR_API_KEY',
'Content-Type': 'application/json'
},
body: JSON.stringify({
accountIds: ['acc_123', 'acc_456'],
contentUrls: [
'https://example.com/slide1.jpg',
'https://example.com/slide2.jpg',
'https://example.com/slide3.jpg'
],
caption: 'Swipe for more! π',
soundId: 'sound_abc123',
markAI: false,
slideDuration: 6,
renderAsVideo: false,
scheduledTime: '2024-04-22T14:00',
timezone: 'America/New_York'
})
});
const data = await response.json();
import requests
response = requests.post(
'https://api.infinipost.co/v1/posts/slideshow',
headers={
'Authorization': 'Bearer YOUR_API_KEY',
'Content-Type': 'application/json'
},
json={
'accountIds': ['acc_123', 'acc_456'],
'contentUrls': [
'https://example.com/slide1.jpg',
'https://example.com/slide2.jpg',
'https://example.com/slide3.jpg'
],
'caption': 'Swipe for more! π',
'soundId': 'sound_abc123',
'markAI': False,
'slideDuration': 6,
'renderAsVideo': False,
'scheduledTime': '2024-04-22T14:00',
'timezone': 'America/New_York'
}
)
print(response.json())
{
"posts": [
{
"postId": "post_abc123",
"accountId": "acc_123",
"platform": "tiktok",
"status": "scheduled",
"scheduledTime": "2024-04-22T14:00",
"timezone": "America/New_York",
"renderAsVideo": false,
"createdAt": "2024-04-21T20:15:00Z"
},
{
"postId": "post_def456",
"accountId": "acc_456",
"platform": "instagram",
"status": "scheduled",
"scheduledTime": "2024-04-22T14:00",
"timezone": "America/New_York",
"renderAsVideo": false,
"createdAt": "2024-04-21T20:15:00Z"
}
]
}
Posts
Create Slideshow Post
Create and schedule a slideshow post to one or more accounts
POST
/
v1
/
posts
/
slideshow
curl -X POST https://api.infinipost.co/v1/posts/slideshow \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"accountIds": ["acc_123", "acc_456"],
"contentUrls": [
"https://example.com/slide1.jpg",
"https://example.com/slide2.jpg",
"https://example.com/slide3.jpg"
],
"caption": "Swipe for more! π",
"soundId": "sound_abc123",
"markAI": false,
"slideDuration": 6,
"renderAsVideo": false,
"scheduledTime": "2024-04-22T14:00",
"timezone": "America/New_York"
}'
const response = await fetch('https://api.infinipost.co/v1/posts/slideshow', {
method: 'POST',
headers: {
'Authorization': 'Bearer YOUR_API_KEY',
'Content-Type': 'application/json'
},
body: JSON.stringify({
accountIds: ['acc_123', 'acc_456'],
contentUrls: [
'https://example.com/slide1.jpg',
'https://example.com/slide2.jpg',
'https://example.com/slide3.jpg'
],
caption: 'Swipe for more! π',
soundId: 'sound_abc123',
markAI: false,
slideDuration: 6,
renderAsVideo: false,
scheduledTime: '2024-04-22T14:00',
timezone: 'America/New_York'
})
});
const data = await response.json();
import requests
response = requests.post(
'https://api.infinipost.co/v1/posts/slideshow',
headers={
'Authorization': 'Bearer YOUR_API_KEY',
'Content-Type': 'application/json'
},
json={
'accountIds': ['acc_123', 'acc_456'],
'contentUrls': [
'https://example.com/slide1.jpg',
'https://example.com/slide2.jpg',
'https://example.com/slide3.jpg'
],
'caption': 'Swipe for more! π',
'soundId': 'sound_abc123',
'markAI': False,
'slideDuration': 6,
'renderAsVideo': False,
'scheduledTime': '2024-04-22T14:00',
'timezone': 'America/New_York'
}
)
print(response.json())
{
"posts": [
{
"postId": "post_abc123",
"accountId": "acc_123",
"platform": "tiktok",
"status": "scheduled",
"scheduledTime": "2024-04-22T14:00",
"timezone": "America/New_York",
"renderAsVideo": false,
"createdAt": "2024-04-21T20:15:00Z"
},
{
"postId": "post_def456",
"accountId": "acc_456",
"platform": "instagram",
"status": "scheduled",
"scheduledTime": "2024-04-22T14:00",
"timezone": "America/New_York",
"renderAsVideo": false,
"createdAt": "2024-04-21T20:15:00Z"
}
]
}
Request Body
array
required
Array of account IDs to post to (e.g.,
["acc_123", "acc_456"]).array
required
Array of image URLs for the slideshow (e.g.,
["https://example.com/slide1.jpg", "https://example.com/slide2.jpg"]).string
Post caption/description.
string
ID of a TikTok sound to attach to the post.Platform Support:
- TikTok: Supported
- Instagram: Not supported
boolean
default:"false"
When
true, adds an AI-generated content label to the post.string
Local time to post, in
YYYY-MM-DDTHH:MM format (e.g. "2024-04-22T14:00"). If not provided, posts immediately.Interpreted in the timezone specified by the timezone parameter.string
default:"America/New_York"
IANA timezone for interpreting
scheduledTime. Supported values:| Value | Label |
|---|---|
America/New_York | Eastern (ET) |
America/Chicago | Central (CT) |
America/Denver | Mountain (MT) |
America/Los_Angeles | Pacific (PT) |
America/Anchorage | Alaska (AKT) |
Pacific/Honolulu | Hawaii (HST) |
Europe/London | London (GMT) |
Europe/Paris | Paris (CET) |
Asia/Tokyo | Tokyo (JST) |
Asia/Singapore | Singapore (SGT) |
Australia/Sydney | Sydney (AEDT) |
number
default:"4"
Duration per slide in seconds. Options:
4, 6, or 8. Only applies when renderAsVideo is true.boolean
default:"false"
When
true, the slideshow images are rendered into a single video file (at the specified slideDuration per slide) before posting. When false (default), images are posted as a native slideshow directly on each platform.Platform behavior:- TikTok: Native slideshow posts as an image carousel. Set
renderAsVideo: trueto post as a video instead. - Instagram: Native slideshow posts as a Reels carousel. Set
renderAsVideo: trueto post as a Reel video instead.
renderAsVideo: true:- You want to attach a
soundIdto an Instagram post (native slideshows donβt support sound on Instagram) - You need guaranteed video format for downstream analytics or repurposing
When
renderAsVideo is true, posts will show a pending_render status while the video is being rendered in the background. Once rendering is complete the status moves to scheduled, at which point the post will go live at the specified scheduledTime.Response
array
Array of created post objects (one per account).
Show properties
Show properties
string
Unique identifier for the post.
string
Account ID this post belongs to.
string
Platform:
tiktok or instagram.string
Post status:
scheduled, processing, posted, or failed.string
When the post is scheduled to go live.
boolean
Whether the slideshow will be rendered to video before posting.
string
ISO 8601 timestamp of when the post was created.
curl -X POST https://api.infinipost.co/v1/posts/slideshow \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"accountIds": ["acc_123", "acc_456"],
"contentUrls": [
"https://example.com/slide1.jpg",
"https://example.com/slide2.jpg",
"https://example.com/slide3.jpg"
],
"caption": "Swipe for more! π",
"soundId": "sound_abc123",
"markAI": false,
"slideDuration": 6,
"renderAsVideo": false,
"scheduledTime": "2024-04-22T14:00",
"timezone": "America/New_York"
}'
const response = await fetch('https://api.infinipost.co/v1/posts/slideshow', {
method: 'POST',
headers: {
'Authorization': 'Bearer YOUR_API_KEY',
'Content-Type': 'application/json'
},
body: JSON.stringify({
accountIds: ['acc_123', 'acc_456'],
contentUrls: [
'https://example.com/slide1.jpg',
'https://example.com/slide2.jpg',
'https://example.com/slide3.jpg'
],
caption: 'Swipe for more! π',
soundId: 'sound_abc123',
markAI: false,
slideDuration: 6,
renderAsVideo: false,
scheduledTime: '2024-04-22T14:00',
timezone: 'America/New_York'
})
});
const data = await response.json();
import requests
response = requests.post(
'https://api.infinipost.co/v1/posts/slideshow',
headers={
'Authorization': 'Bearer YOUR_API_KEY',
'Content-Type': 'application/json'
},
json={
'accountIds': ['acc_123', 'acc_456'],
'contentUrls': [
'https://example.com/slide1.jpg',
'https://example.com/slide2.jpg',
'https://example.com/slide3.jpg'
],
'caption': 'Swipe for more! π',
'soundId': 'sound_abc123',
'markAI': False,
'slideDuration': 6,
'renderAsVideo': False,
'scheduledTime': '2024-04-22T14:00',
'timezone': 'America/New_York'
}
)
print(response.json())
{
"posts": [
{
"postId": "post_abc123",
"accountId": "acc_123",
"platform": "tiktok",
"status": "scheduled",
"scheduledTime": "2024-04-22T14:00",
"timezone": "America/New_York",
"renderAsVideo": false,
"createdAt": "2024-04-21T20:15:00Z"
},
{
"postId": "post_def456",
"accountId": "acc_456",
"platform": "instagram",
"status": "scheduled",
"scheduledTime": "2024-04-22T14:00",
"timezone": "America/New_York",
"renderAsVideo": false,
"createdAt": "2024-04-21T20:15:00Z"
}
]
}
Slideshow ProcessingBy default, slideshows are posted as native image carousels on both TikTok and Instagram. Set
renderAsVideo: true to render them into a video first β useful when you want to attach a sound to an Instagram post or ensure video format. Video rendering happens in the background; posts will show a pending_render status until rendering is complete, then move to scheduled.Error Responses
Unauthorized
{
"error": {
"code": "unauthenticated",
"message": "Invalid or missing API key"
}
}
Missing Required Fields
{
"error": {
"code": "missing_required_fields",
"message": "contentUrls array is required and cannot be empty"
}
}
Invalid Slide Duration
{
"error": {
"code": "invalid_parameter",
"message": "slideDuration must be 4, 6, or 8 seconds"
}
}
Account Not Found
{
"error": {
"code": "not_found",
"message": "Account(s) not found: acc_1a2b3c4d5e"
}
}
Invalid Scheduled Time
{
"error": {
"code": "invalid_parameter",
"message": "scheduledTime must be a valid ISO 8601 timestamp"
}
}
Server Error
{
"error": {
"code": "internal",
"message": "An unexpected error occurred"
}
}