Module: Grape::OAuth2::UniqueToken
- Defined in:
- lib/grape_oauth2/unique_token.rb
Overview
OAuth2 helper for generation of unique token values. Can process custom payload and options.
Class Method Summary collapse
-
.generate(_payload = {}, options = {}) ⇒ String
Generates unique token value.
Class Method Details
.generate(_payload = {}, options = {}) ⇒ String
Generates unique token value.
15 16 17 |
# File 'lib/grape_oauth2/unique_token.rb', line 15 def self.generate(_payload = {}, = {}) SecureRandom.hex(.delete(:size) || 32) end |