Added templates() api method & test