Skip to content

lindar-open/well-rested-client

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

245 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

well-rested-client

Want a nice rest client that just works without too much headache? Try this well rested and ready to go client built on top of apache http client

Check out the Releases page for detailed info about each release.

Examples:

GET Request:

ResponseVO serverResponse = WellRestedRequest.builder().url(url).build().get().submit();

The ResponseVO class contains the status code returned by the server and the server response returned as String.

POST Request:

How to post a json string directly:

ResponseVO serverResponse = WellRestedRequest.builder().url(url).build().post().jsonContent(jsonString).submit();

How to post an object as json:

ResponseVO serverResponse = WellRestedRequest.builder().url(url).build().post().jsonContent(myObj).submit();

How to post an xml string directly:

ResponseVO serverResponse = WellRestedRequest.builder().url(url).build().post().xmlContent(xmlString).submit();

More examples to come...

Usage:

<dependency>
    <groupId>com.lindar</groupId>
    <artifactId>well-rested-client</artifactId>
    <version>1.4.1</version>
</dependency>

About

A very well RESTed client

Topics

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors