Upload to Postman completed with status: 400 - Bad Request #578
-
Hi there Portman community, Hopefully someone can help me here. I am trying to automatically sync my generated postman collection to postman and I keep getting the following error: Debugging this a bit deeper, the following error is being returned from the PostmanAPIService: |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 14 replies
-
hi @PaulCluver To not overload the Postman API when syncing the generated Postman collections, Portman keeps a local cache of the workspaces and collections in the workspace. It might be that there is something off in the cache which causes the error to occur. Some CLI options to try:
If none, of this works, could you try to find the file .portman.cache.json (usually in the "tmp" folder), and remove that file? |
Beta Was this translation helpful? Give feedback.
-
Hi Tim, Unfortunately, none of the above suggestions worked. I will keep digging and update this post when I have found the root cause of the 400 response. Kind regards, |
Beta Was this translation helpful? Give feedback.
Hi Tim,
After a bit of debugging a bit, I decided to extract the values being sent to the below method:
I then went into my Postman instance and tried to update the collection using the portman generated postman collection. This revealed a malformedRequestError as detailed below:
I do not believe this to be an issue with Portman. Rather, it is related to the API spec file which is being built and maintained in Mulesoft. I fixed this by simply adding the following to the API spec before sending the file to Portman.
Kind regards,
Paul