How to execute web-api script on the client ?

Hi,compiled and executed my first web-api script on the SD 5.0 server I tried to do same thing on the client without success, what are right steps to launch script from client ?My script is executed by smart action.