AnsweredAssumed Answered

Insert from URL Version 16 cURL POST

Question asked by rseba on Sep 11, 2017
Latest reply on May 8, 2018 by user10625

I’m trying to connect to a customer API for a client using Version 16 Insert from URL. I’m so new to cURL that I don’t know how to troubleshoot the problem.


The following cURL Options seem to connect but generate an error:

-X -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'X-ST-PartnerID: iresq08222017' -H 'X-ST-AuthType: TOKEN' -H 'X-ST-Token: c3Vic2NyaXBfaXJlc3EwODIyMjAxN2l1anI5aml1dGc3Z3NsZTVuanJpMW5qcHY3' --data-binary '{"claimID": "claim_stage2_094762561138", "depotRefID": "iresq08222017", "stRefID": "NA", "isSuccessful": "true"}'


Error Results:

400 Bad Request</title></head><body bgcolor="white"><center><h1>400 Bad Request

Note: API documentation says that a 400 error = Bad input parameter. Error message should indicate which one and why.


The client IT response is to add “POST" after the -X, such as: -X POST -H ‘Content…”

But that returns a very long error message that includes:

RESTEASY001055: Cannot consume content type</u></p><p><b>JBWEB000069: description</b> <u>JBWEB000135: The server refused this request because the request entity is in a format not supported by the requested resource for the requested method.


If anyone has run into somethingn like this I would appreciate suggestions.