Upload Files
First you need to use createFiles
query to get the file url,
and then you have to upload your file to that url.
- GraphQL
- JS Client
To upload the files you need to put all the fields in the fields
in addition to content type and file
to the body of the post request. Here is a JavaScript example of how to do it.
Our javascript client have a function to automatically create and upload the files for you.
It takes an extra File
object as an argument.