const file = await fs.readFile(path.resolve(__dirname, fileName)
const file = await fs.readFile(path.resolve(__dirname, fileName), {
encoding: null,
});
json: false
to the list of request parameter, i.e.const r = await spr.post(uri, {
body: f,
json: false,
headers: {
"X-RequestDigest": digest,
"X-HTTP-Method": "POST",
"IF-MATCH": "*",
"Content-Length": f.length,
},
});