Support Article
Invalid multipart request sent to external API
SA-67701
Summary
Error occurs when sending a file as part of the Connect-REST POST method to an external API and forming the file request by setting pyRequestAttachmentPage with the below properties.
- .pyAttachNames
- .pyAttachTypes
- .pyAttachValues
- .pyAttachFileNames
Error Messages
Invalid request exception
Steps to Reproduce
Create a multipart Connect-REST (POST) request.
Root Cause
The external REST Web service is protected by Oauth. The Oauth token along with the other query parameters were not sent to the Service in the request.
Resolution
As a local-change, add Oauth Bearer token and Service Query parameters to the request.
Published January 4, 2019 - Updated December 2, 2021
Have a question? Get answers now.
Visit the Collaboration Center to ask questions, engage in discussions, share ideas, and help others.