1

Devise helps us to login/register users to our Rails applications. It helps us to Confirm emails, recover accounts. It is easy to implement sessions between app and user. It is easy to use Devise when user accesses to your app via Browser.

However, how to use Devise if users will be accessing to your app via Grape?

In simple Browser app when users wants to login, We can check by using user_signed_in?, or when user accesses to controller we can use before_action :authenticate_user!. Then we use current_user which is user who logged in or registered now.

Is it possible to access these helpers via Grape? Is it good solution to use Devise through Grape!?

Mr.D
  • 7,353
  • 13
  • 60
  • 119

0 Answers0