I'm an engineer at Kinvey. To use the REST API, you need to first get an API URL to upload by making a GET request to:
/blob/:appKey/upload-loc/:fileName
That will return a response with the following object:
{ "URI" : <externalLocation> }
Exctract response.body.URI, and perform a PUT request to that URI. Set the content-length header, and pass your binary file as the request.body.
A couple of notes about file upload:
- The URI retrieved by upload-loc is only valid for 30 seconds
- The library only supports files < 64 MB in size.