Posting Media

Posting media is simple whether using your own hosted files or our free storage solution.

When creating posts with Post for Me, attaching images or video is straightforward. Ultimately, the API just requires a valid media URL to fetch your content. You can provide this URL in two ways: using your own hosting or utilizing our temporary storage.

Here is a breakdown of how to handle media assets for your posts.

Bring Your Own Storage

If your media is already hosted online, you can use it directly without any additional API calls.

How it works

Simply pass a publicly accessible URL (e.g., from an AWS S3 bucket, Cloudinary, or your own server) into the media array when creating a post. This URL should return the actual binary data of the file and not an html page, video player, etc.. The Post for Me API will fetch the asset from this URL during the publishing process. Similarly a separate thumbnail URL can be provided if you have a dedicated image to use for the thumbnail of your video.

Note: thumbnail URLs are only supported for Facebook, Instagram, TikTok Business, and YouTube accounts.

Requirements

The URL must be publicly accessible so our servers can retrieve the file at the time of posting and must and image or video file.

Temporary Storage

If your application does not host media files, you can use our temporary storage to stage your assets before publishing.

How it works

This involves a simple three-step sequence:

  1. Generate URLs: Make a POST request to the /v1/media/create-upload-url endpoint. This returns two values: a signed upload_url (for uploading the file) and a public media_url (for referencing the file).

  2. Upload the File: Upload your file binary directly to the upload_url using a PUT request.

  3. Create the Post: Use the media_url returned in step 1 when calling the post creation endpoint.

Note: The upload_url is a signed URL valid for a short time, so files should be uploaded immediately after generating the URL.

Repeat the above process for any media you wish to include in a post, including thumbnail URLs where applicable.

Media Lifecycle

Our storage system is designed to be ephemeral. It holds your assets only as long as necessary to complete the publishing process.

Automatic Cleanup

Media assets stored in our system are automatically deleted in the following scenarios:

  • Immediately when the associated post is published.

  • When a scheduled post containing the media is deleted.

  • After 24 hours if the uploaded media has not been attached to any post.

Media Processing

Media is only processed if the attached file does not meet the platform’s requirements to be posted. For example if an image or video file is too large then we will compress it down to the largest allowed size in order for it to be successfully published.

We will never water mark or alter the content in any way other then the minimum processing required to publish the content

Note: By default our media pipelines are engineered for short form content, if you are intending to post very large long form files through our API please contact us so we can better accommodate your use case.