400 Bad request - Trying to upload photo or album
Author: eileoooCreated Jan 15, 2021Updated Aug 10, 2026
Labelsbugunconfirmed
Requirements
- I've searched the Issues
- I've read the basic concepts
- I'm using the latest version
- I've debugged my code using the
DEBUGvariable.
Platform
- I'm using Node.js version
v12.18.1
Description
I'm trying to public a image or album but it's returning 400 Bad Request. (The file path is correct, I've checked!)
Code
ig.publish.photo({
file: waitingFile,
caption: waitingDescription
});Error and Output
(node:3788) UnhandledPromiseRejectionWarning: IgResponseError: POST /rupload_igphoto/1610720084925_0_8828849218 - 400 Bad Request;
at Request.handleResponseError (C:\Users\garci\Documents\Tecticias\bot_local\node_modules\instagram-private-api\dist\core\request.js:125:16)
at Request.send (C:\Users\garci\Documents\Tecticias\bot_local\node_modules\instagram-private-api\dist\core\request.js:53:28)
at async UploadRepository.photo (C:\Users\garci\Documents\Tecticias\bot_local\node_modules\instagram-private-api\dist\repositories\\\upload.repository.js:17:26)
at async PublishService.photo (C:\Users\garci\Documents\Tecticias\bot_local\node_modules\instagram-private-api\dist\services\publish.service.js:79:31)Source: dilame/instagram-private-api