fixes #2286 (api validates templates)

fixes #2286