Answer the question
In order to leave comments, you need to log in
Java: how to make JSON requests to the server and how to parse responses?
Hello!
I send myself daily beautiful reports generated by a bash script pulling the Zabbix API. Because the script has long outgrown two and a half hundred lines, I wanted to port it to a high-level language. I chose Java because I study it in my spare time. I found this lib https://github.com/hengyunabc/zabbix-api , but it has a fatal flaw: it allows you to pass no more than one parameter value. Those. for example, in the filter field, you cannot pass something like
"filter": {
"value":"1",
"description":"Some kind of trigger"
}
"filter": {
"value":"1"
}
Answer the question
In order to leave comments, you need to log in
There are hundreds of libraries for this. The standard for writing REST clients and services is JAX-RS , and its reference implementation is Jersey .
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question