Publishing
Create a media container
Create a container for an image, reel, story, or carousel.
POST
Create a media container
Step 1 of the publish flow. Creates a media container from a public HTTPS media URL.
Poll the returned container ID until
See media requirements for size, format, and quota limits.
Containers expire after 24 hours.
Poll the returned container ID until
status_code is FINISHED, then publish it.
Authentication
Use thehmat_ channel token from GET /meta/channels/{id}/token or hookmyapp channels env <channel>. Do not use an hmok_ API key for this call.
Path parameters
string
required
The connected Instagram account ID.
Request body
string
Public HTTPS URL of a JPEG image. Required for images; either this or
video_url for stories.string
Public HTTPS URL of a video. Required for reels; either this or
image_url for stories.string
REELS, STORIES, or CAROUSEL. Omit for a feed image.string
Post caption.
boolean
Set
true when creating a child container for a carousel. Child containers take image_url (or video_url with media_type=VIDEO) and no caption.string
For the carousel parent (
media_type=CAROUSEL): the child container IDs created with is_carousel_item=true, as a comma-separated string (for example "17890000000000001,17890000000000002"). 2–10 items.string
Cover image URL for reels.
string
Alt text for an image post, up to 1000 characters. Single images and carousel image children only.
array
Tag public accounts:
[{"username":"someuser","x":0.5,"y":0.8}]. x/y position the tag on images. Images, videos, stories, and carousel children.array
Invite accounts to collaborate:
["username1","username2"]. Each gets an invite, and once they accept, the post also shows on their profile. Images, reels, and the carousel parent (not carousel children).string
Facebook Page ID of a place to tag. The Page must have location data. Feed posts and reels.
number
Cover frame for videos and reels, in milliseconds from the start. Ignored when
cover_url is set.string
Name of the reel’s audio. Can only be set once.
object
Reels only: publish as a trial reel.
{"graduation_strategy":"MANUAL"} or "SS_PERFORMANCE".