Class: Tramway::Api::V1::UserTokensController

Inherits:
ApplicationController show all
Defined in:
app/controllers/tramway/api/v1/user_tokens_controller.rb

Instance Method Summary collapse

Instance Method Details

#create ⇒ Object



5
6
7
8
9
10
11
12
13
# File 'app/controllers/tramway/api/v1/user_tokens_controller.rb', line 5

def create
  token = auth_token
  render json: {
    auth_token: token,
    user: {
      email: @entity.email
    }
  }, status: :created
end