class Castle::Commands::Authenticate
Generates the payload for the authenticate request
Public Class Methods
build(options = {})
click to toggle source
@param options [Hash] @return [Castle::Command]
# File lib/castle/commands/authenticate.rb, line 10 def build(options = {}) Castle::Validators::Present.call(options, %i[event]) context = Castle::Context::Sanitize.call(options[:context]) Castle::Command.new( 'authenticate', options.merge(context: context, sent_at: Castle::Utils::GetTimestamp.call), :post ) end