Another way of implementing a REST talk to a remote API using Java and JSON.
Instead of making a URL encoded request or using a chunk one of binary data here is an example of simply posting a straight JSON string to an HTTP API Server
Pure PHP with CSS for styling