Querying and templating the services