Update client.js

Added API draft for dynamic service discovery.