Help

Re: Connect Airtable and Nextcloud / Owncloud

1501 0
cancel
Showing results for 
Search instead for 
Did you mean: 
JazzHall
6 - Interface Innovator
6 - Interface Innovator

Hey everybody,

with the CDN changes in Airtable, i am now looking on storing our data (mainly images and documents/pdf) to our own Nextcloud instance and fetching those links back to AT. I have been doing some research, but nothing really helpful came up and i am a bit confused with the Nextcloud documentation. 

Did anybody do this yet?

Ideally i would like to achieve this with an Airtable Script.

I am familiar with APIs and Airtable Scripting.
For the complete picture, this is what needs to happen:

1. Upload of files to an attachment field via a form or user upload.
2. Upload triggers script, which transfers file to Nextcloud location.
3. After complete transfer, the public link to the file in Nextcloud is stored in AT.

It's mainly No. 2 i'm struggling with right now.
Any help appreciated!

4 Replies 4

I don't know scripting, so I can't help you there.

If you want a non-scripting way of doing it, you can simply use Make's NextCloud API integrations.

There can be a bit of a learning curve with Make, which is why I created this basic navigation video for Make, along with providing the link to Make’s free training courses.

You’ll need to get the URL from the attachments field, then fetch the files from Airtable since nextcloud is looking to for raw files to be uploaded. 

Then you can send the fetched raw files via API call to nextcloud. nextcloud docs say use the PUT method to upload files.

Then there might be a header in the response that contains file ID or something you can use to identify the URL path of the uploaded file.

I’ve never done it but that’s what I’d try first after glancing at the docs.

JazzHall
6 - Interface Innovator
6 - Interface Innovator

Thank you both!

I'll have a look at using MAKE, although i'd rather like to do this with only Airtable and Nextcloud.

Regarding the API approach: I technically know how to do it - i was just hoping somebody, who might have done it before, could point out how to call the Nextcloud API with Airtable Scripting only (which is limited to JavaScript basically).

JazzHall
6 - Interface Innovator
6 - Interface Innovator

@Stephen_Orr1 : I've come a bit farther on this. Made successful API calls with Postman (at least).

Now it looks as if i have to get an image in binary code to make it uploadable to Nextcloud, which would be my body in an API call. Do you have any idea on how to get this from Airtable?

In Postman i can just upload the file and it will translate to the right format - but that's of course not working for an automated upload.