Add temporary route for bad API endpoints

This temporary route returns status 400 with a JSON error if a client
requests a nonexistent endpoint. Note that this is temporary because
there are better ways of doing this.
Add index to tag :tid field

The application searches for Tag by tag ID frequently. Adding an index
would not be a bad idea.
Update routes for api/devices controller

Use "device/register" and "device/unregister" instead of "register" and
"unregister"