400 response calling assessments/byID/{id}/appDetails


#1

Hi,

Please help diagnosing 400 error in response to assessments/byID/{id}/appDetails

Mike.

Request:

PATCH htttp://talegentassess.tazzy.io/t/talegenttest/devs/tas/assessments/byID/12475/appDetails
{
“status”: “In_progress”,
“passedFlag”: false,
“interactionUris”: {
“candidateInteractionUri”: “htttp://localhost:31567/?ID=393e431a-26f0”,
“userInteractionUri”: null,
“userAttentionRequired”: false
},
“image”: “htttps://mikedev.talegent.com:9443/Aotal/AssessmentImage.aspx?Tenant=talegenttest&ID=393e431a-26f0”
}

Response : 400
{
“timestamp”: 1518998257742,
“status”: 400,
“error”: “Bad Request”,
“exception”: “org.springframework.http.converter.HttpMessageNotReadableException”,
“message”: “JSON parse error: Can not construct instance of com.talentappstore.tenant.v2_0_170.assessmentread.AssessmentRead$Status, problem: In_progress; nested exception is com.fasterxml.jackson.databind.JsonMappingException: Can not construct instance of com.talentappstore.tenant.v2_0_170.assessmentread.AssessmentRead$Status, problem: In_progress\n at [Source: java.io.PushbackInputStream@6343447c; line: 1, column: 11] (through reference chain: com.aotal.assessmenthub.model.AssessmentPatch[“status”])”,
“path”: “/t/talegenttest/tas/devs/tas/assessments/byID/12475/appDetails”
}


#2

Hi Mike,

It looks the reason you’re getting that 400 error is because of how you’re passing in the status, it should be “In progress” instead of “In_progress”.

Thanks


#3

Thanks Kunaal. Looks like the .NET serialization doesn’t handle enumerations with spaces in them. Bugger.