Module: KapsoClientRuby::Errors

Defined in:
lib/kapso_client_ruby/errors.rb

Defined Under Namespace

Classes: ConfigurationError, GraphApiError, KapsoProxyRequiredError, ValidationError

Constant Summary collapse

ERROR_CATEGORIES =

Error categories mapped from the JavaScript implementation

{
  'authorization' => :authorization,
  'permission' => :permission,
  'parameter' => :parameter,
  'throttling' => :throttling,
  'template' => :template,
  'media' => :media,
  'phone_registration' => :phone_registration,
  'integrity' => :integrity,
  'business_eligibility' => :business_eligibility,
  'reengagement_window' => :reengagement_window,
  'waba_config' => :waba_config,
  'flow' => :flow,
  'synchronization' => :synchronization,
  'server' => :server,
  'unknown' => :unknown
}.freeze
ERROR_CODE_CATEGORIES =

Error codes and their categories

{
  0 => :authorization,
  190 => :authorization,
  3 => :permission,
  10 => :permission,
  (200..219) => :permission,
  4 => :throttling,
  80007 => :throttling,
  130429 => :throttling,
  131048 => :throttling,
  131056 => :throttling,
  33 => :parameter,
  100 => :parameter,
  130472 => :parameter,
  131008 => :parameter,
  131009 => :parameter,
  131021 => :parameter,
  131026 => :parameter,
  131051 => :media,
  131052 => :media,
  131053 => :media,
  131000 => :server,
  131016 => :server,
  131057 => :server,
  133004 => :server,
  133005 => :server,
  368 => :integrity,
  130497 => :integrity,
  131031 => :integrity,
  131047 => :reengagement_window,
  131037 => :waba_config,
  131042 => :business_eligibility,
  131045 => :phone_registration,
  133000 => :phone_registration,
  133006 => :phone_registration,
  133008 => :phone_registration,
  133009 => :phone_registration,
  133010 => :phone_registration,
  133015 => :phone_registration,
  133016 => :phone_registration,
  132000 => :template,
  132001 => :template,
  132005 => :template,
  132007 => :template,
  132012 => :template,
  132015 => :template,
  132016 => :template,
  132068 => :flow,
  132069 => :flow,
  134011 => :business_eligibility,
  135000 => :parameter,
  2593107 => :synchronization,
  2593108 => :synchronization
}.freeze
DO_NOT_RETRY_CODES =

Error codes that should not be retried

[131049, 131050, 131047, 368, 130497, 131031].freeze
REFRESH_TOKEN_CODES =

Error codes that require token refresh

[0, 190].freeze