I have trouble understanding how the file.uploadchunk exactly should be used.
My understanding is that you first call the file.allocate method, from which you can retrieve the filePHID, to be used as parameter in the file.uploadchunk method.
The dataEncoding parameter of the file.uploadchunk is set to “base64”, byteStart parameter is set to 0 for the first chunk.
But I don’t know what should be in the data parameter: what is the size of a chunk ?
I suppose the data parameter contains the bytes to be uploaded formatted as a base64 string.
If I use a chunk of 2MB or more, I get the following (PHP?) error message:
escapeshellarg(): Argument exceeds the allowed length of 2097152 bytes
If I use a chunk of less than 2MB, I get a Conduit error message like this:
Chunk end byte is 4194304, not 284.