expose rest template for extending classes

close #60