example api server with token authentication implemented using rails and devise