Added TemplatesApi unit tests

If we are sending links without type to the API, we shouldn't. Let's make sure we send proper links.