class Uploadcare::Param::AuthenticationHeader

This object returns headers needed for authentication This authentication method is more secure, but more tedious

Public Class Methods

call(**options) click to toggle source

@see uploadcare.com/docs/api_reference/rest/requests_auth/#auth-uploadcare

# File lib/uploadcare/param/authentication_header.rb, line 13
def self.call(**options)
  case Uploadcare.config.auth_type
  when 'Uploadcare'
    SecureAuthHeader.call(**options)
  when 'Uploadcare.Simple'
    SimpleAuthHeader.call
  else
    raise ArgumentError, "Unknown auth_scheme: '#{Uploadcare.config.auth_type}'"
  end
end