Why am I unable to post a build status into Bitbucket?

I am trying to configure Jenkins to post a build status to Bitbucket Server each time we run a build. When I make the API call from the REST API Browser in Bitbucket it is successful, however when I try to make the same request using CURL or Postman it fails with an HTTP 500 error and the message "An error occurred while processing the request. Check the server logs for more information."

Upon checking the Bitbucket server logs I find an unhandled exception being thrown.

I haven't been able to find any useful information about what could be causing this problem. At first I assumed it was an issue with permissions but the user I am authenticating as is an administrator user, and I am able to authenticate properly when calling a GET on the same URL to retrieve the build status.

I have not been able to figure out why I am unable to post the same request from cURL or Postman and get the expected results, but the Jenkins plugin I am using seems to be making the request in a different way, because it is able to successfully post the statuses.

You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.