I need to send a complex JSON
document from the client application(AngularJS
) to my server side(Java
, Spring MVC/Rest
) in order to retrieve the desired information.
This is the JSON
example:
[
{
"operator":"AND",
"queries":[
{
"value":10,
"comparisonOperator":"\u003e\u003d",
"characteristicId":391
},
{
"value":50,
"comparisonOperator":"\u003c\u003d",
"characteristicId":391
}
],
"characteristicId":391
},
{
"value":true,
"comparisonOperator":"\u003d",
"characteristicId":383
}
]
My client app communicates with the back end via RESTful
web services. For data retrieving I use the GET
method and use url with path/query parameters.
I'm in doubt how to handle the case where I have to GET data and provide JSON
document presented above.
Q:Is it okay to include such kind of JSON
into GET request body ?
If no, what is the best way to solve this issue ?
Anyway, I can't change this JSON
with path/query parameters due to schema less nature of this document.