Optimisation on webservice and validation