Implements the web service.