Upload media
postfjord_upload_mediaUpload a picture or video to the media library and get its ID for use in Postfjord drafts or posts. Send a public URL or local file path; scheduling waits until processing is ready.
Instructions
Adds a picture or video to the media library and returns its id, to use in mediaIds of postfjord_create_draft or postfjord_update_post. Send url (a public https address Postfjord downloads) or path (a file on this computer, at most 30 MB; send a bigger video as a url). JPEG, PNG, WebP, GIF, MP4 or MOV; a picture at most 50 MB, a video at most 500 MB, within the plan's storage. The file is processed after it arrives: status is processing until postfjord_get_media says ready. A draft can use the id right away; scheduling waits until it is ready. Nothing is posted. On a retry after a timeout or error, send the same idempotency_key: the first answer comes back and nothing is made or sent twice.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| alt | No | Alt text: what the picture shows, for people who cannot see it. | |
| url | No | The http(s) address of the file. It must answer with the file itself, not a web page about it. | |
| name | No | The file name to show in the library. Left out, the name comes from the address or the file. | |
| path | No | The full path of a file on this computer, instead of url. | |
| idempotency_key | No | Your own id for this one action, for example post-20261006-launch. Make a new one for each new thing; send the same one again only when you retry. Left out, the exact same call within 10 minutes counts as a retry. |