class Monban::UseCase::Auth::Token::Authy
Public Instance Methods
create(params)
click to toggle source
# File lib/monban/use_case/auth/token/authy.rb, line 32 def create(params) Getto::Params.new.validate(params) do |v| v.hash( account_id: v.integer{|val| param_error!(account_id: val) }, ) end or param_error!(params: params) repository.transaction do auth.authy( public_id: generate_public_id!(account_id: params[:account_id]), authy_id: repository.authy_id(account_id: params[:account_id]), expired_at: time.now + expire, ) end end