Hi.
My request
await this.httpService
.post(
`https://api.cloudflare.com/client/v4/accounts/${this.configService.get(
'cloudflare.image.accountId',
)}/images/v1`,
{ file: file },
{
headers: {
Accept: 'application/json',
'Content-Type': 'application/json',
Authorization: `Berear ${this.configService.get(
'cloudflare.image.token',
)}`,
},
},
)
.toPromise();
error
"message": "Request failed with status code 400",
"name": "AxiosError",
"stack": "AxiosError: Request failed with status code 400\n at settle (/usr/src/app/node_modules/axios/lib/core/settle.js:19:12)\n at IncomingMessage.handleStreamEnd (/usr/src/app/node_modules/axios/lib/adapters/http.js:556:11)\n at IncomingMessage.emit (node:events:525:35)\n at endReadableNT (node:internal/streams/readable:1359:12)\n at processTicksAndRejections (node:internal/process/task_queues:82:21)",