Java PUT request using Unirest

In this post we will provide some examples on how to make a PUT request using Unirest. Unirest is a lightweight and readable HTTP java client. Setup: You will need to add the following dependency:

Put request using Unirest: Below ¬†are two examples on how to make a REST API call using Unirest, the … Continue reading Java PUT request using Unirest

Java POST request using Unirest

In this post we will provide an example on how to make a POST request using Unirest. Setup: You will need to add the following dependency to your maven project

POST request using Unirest: Below is a simple example on how to send a HTTP Post request.

As you can see the Unirest … Continue reading Java POST request using Unirest

Java GET request using Unirest

In this post we will provide examples of how to make a GET request using Unirest. Unirest is an increasingly popular HTTP client library, with a great API making your code very readable. Setup: You will need to add the following dependency to your maven project

GET request using Unirest: The examples below include … Continue reading Java GET request using Unirest

Convert JSON to a Map using Jackson

In this post we will demonstrate how to convert JSON to a Map using Jackson. Setup: You will need to add the following dependancy to your project.

Convert JSON to a Map using Jackson: The example below shows how to convert a JSON string to a Java Map using Jackson.

The main class … Continue reading Convert JSON to a Map using Jackson

Convert a java map to JSON using Jackson

In this post we will convert a java map to JSON using the jackson library. Setup: You will need to add the following dependancy to your project

Convert a java map to JSON: The following example shows how to convert a Java map to JSON using the ObjectMapper class. The ObjectMapper class has a … Continue reading Convert a java map to JSON using Jackson

Convert a JSON array to a List using Jackson

In this post we will provide an example of how to convert a JSON array to a List using Jackson. Setup: In this example you will need to add the following dependancy

Convert a JSON array to a list: The example below shows how to convert a JSON array to a java list using … Continue reading Convert a JSON array to a List using Jackson

Convert a List to JSON array using Jackson

In this post we will show how to convert a List to JSON array using Jackson. Setup: In this example you will need to add the following dependancy

Convert a List to JSON array: The example below shows how to convert a java list to a JSON array using the Jackson parser.

As … Continue reading Convert a List to JSON array using Jackson