我想在grape-api中使用Rails activerecord-session_store會話。 但下面代碼中的env['rack.session'][:foo]爲空。 請告訴我如何解決。 class API < Grape::API
use ActionDispatch::Session::ActiveRecordStore
~~
get :ping do
我也跟着一步本教程一步:https://wildandcrazytutorials.wordpress.com/2016/03/05/how-to-build-a-grape-standalone-rest-api/ 但是我得到的錯誤: Puma starting in single mode...
Version 3.6.2 (ruby 2.2.2-p95), codename: Sleepy
對於我的一種方法,以下方法無效。我幾乎複製所有直接從官方文檔的: params do
requires :authenticationType, type: Array[String], values: ['LOCAL', 'AD']
given authenticationType: ->(val) { val == 'LOCAL' } do
requires :admin, ty