Hi,
Is it possible to download media files using API? Can anyone guide me towards the documentation or just let me know how?
Thanks!
Hi @Kal_Lam ,
Thanks. But that is not the solution I’m looking for. That solution suggests we loop over the URLs and download files one by one. That is time consuming and impractical. I am looking for the API method to download media as zip file. Like the option we find in downloads
. Attaching screenshot for clarity. You will notice the Media Attachments (zip)
option. I want to know if we have similar option in API too.
Thanks.
Hi @scary.scarecrow, you can refer to this script where I use the API to pull all project media, but again it does loop through each item: GitHub - joshuaberetta/kobomedia
Otherwise you can send a POST
request to the endpoint to initiate a ZIP export (the same as pressing the “New Export” button in the UI):
https://{kc_url}/{username}/exports/{asset_uid}/zip/new
I would suggest using your browser’s dev tools to see what API calls are made from the UI to do what you’re wanting — the UI is API driven.
We will be implementing an improved ZIP media export feature in the coming months.