VEuPathDB / lib-jaxrs-container-core

Core library for VEuPathDB JaxRS container services
Apache License 2.0
0 stars 0 forks source link

Weird error when endpoint is sent valid json as an entity, but it does not align with the expected structure. #43

Open Foxcapades opened 7 months ago

Foxcapades commented 7 months ago
curl -H'Content-Type: application/json' -XPOST -d'{"targets":["fQ666Oc5Hhj"]}' https://sfischer.plasmodb.org/vdi/vdi-datasets/admin/install-cleanup

{"status":"unsupported-content-type","message":"HTTP 415 Unsupported Media Type"}

The service expected targets array to be an array of objects, not strings. The endpoint should have returned a 400 here but returned a 415 instead.