Server communication code

Adding the code that allows our php code to communicate with the
core-service.