Added code to talk to EWS