Module: RocketGate::ResponseCode

Defined in:
lib/rocketgate/response_code.rb

Constant Summary collapse

AVS =
{
  'D'             => :match,
  'F'             => :match,
  'M'             => :match,
  'X'             => :match,
  'Y'             => :match,
  'A'             => :address_only_match,
  'B'             => :address_only_match,
  'P'             => :zip_only_match,
  'T'             => :zip_only_match,
  'W'             => :zip_only_match,
  'Z'             => :zip_only_match,
  'C'             => :not_verified,
  'G'             => :not_verified,
  'I'             => :not_verified,
  'R'             => :unavailable,
  'U'             => :unavailable,
  'S'             => :unsupported,
  'N'             => :no_match
}
AVS_SUCCESSES =
[ :match, :address_only_match, :zip_only_match, nil ]
CVV =
{
  'M'             => :match,
  'N'             => :no_match,
  'P'             => :not_processed,
  'S'             => :should_have_been_present,
  'U'             => :issuer_could_not_process
}
CVV_SUCCESSES =
[ :match, :not_processed, :issuer_could_not_process, nil ]
CARD_BRAND =
{
  'AMEX'          => :amex,
  'CARTEBLANCHE'  => :carte_blanche,
  'DINERSCLUB'    => :diners_club,
  'DISCOVER'      => :discover,
  'JCB'           => :jcb,
  'MAESTRO'       => :maestro,
  'MC'            => :master_card,
  'SOLO'          => :solo,
  'VISA'          => :visa
}
CARD_REGION =
{
  '1'             => :usa,
  '2'             => :canada,
  '3'             => :europe,
  '4'             => :asia_pacific,
  '5'             => :latin_america,
  '6'             => :africa_middle_east
}
CARD_TYPE =
{
  '0'             => :debit,
  '1'             => :credit,
  '2'             => :both
}
REASON =
{
  '0'             => :success,
  '100'           => :no_matching_transaction,
  '101'           => :cannot_void,
  '102'           => :cannot_credit,
  '103'           => :cannot_ticket,
  '104'           => :declined_generic,
  '105'           => :declined_over_limit,
  '106'           => :declined_cvv_mismatch,
  '107'           => :declined_expired,
  '108'           => :declined_call_issuer,
  '109'           => :declined_pickup_card,
  '110'           => :declined_excessive_use,
  '111'           => :declined_invalid_card,
  '112'           => :declined_invalid_expiration,
  '113'           => :declined_bank_unavailable,
  '117'           => :declined_avs_mismatch,
  '123'           => :declined_by_user_request,
  '150'           => :declined_avs_mismatch,
  '151'           => :declined_cvv_mismatch,
  '152'           => :declined_invalid_amount,
  '154'           => :declined_integration_error,
  '156'           => :declined_unsupported_card,
  '157'           => :declined_processor_risk,
  '200'           => :declined_fraud_scrubbing,
  '201'           => :declined_customer_blocked,
  '208'           => :declined_duplicate_membership_id,
  '209'           => :declined_duplicate_membership_card,
  '210'           => :declined_duplicate_membership_email,
  '211'           => :declined_over_max_purchase,
  '212'           => :declined_duplicate_transaction,
  '213'           => :declined_customer_velocity,
  '214'           => :declined_card_velocity,
  '215'           => :declined_email_velocity,
  '216'           => :declined_iovation_generic,
  '217'           => :declined_iovation_email_velocity,
  '218'           => :declined_iovation_duplicate_membership,
  '219'           => :declined_different_source_ip,
  '220'           => :declined_too_many_cards,
  '221'           => :declined_affiliate_blocked,
  '222'           => :declined_trial_abuse,
  '300'           => :error_dns_failed,
  '301'           => :error_connection_failed,
  '303'           => :error_read_timeout,
  '311'           => :error_bank_communcations,
  '312'           => :error_bank_communcations,
  '313'           => :error_bank_communcations,
  '314'           => :error_bank_communcations,
  '315'           => :error_bank_communcations,
  '316'           => :error_bank_communcations,
  '321'           => :error_bank_communcations,
  '323'           => :error_bank_communcations,
  '325'           => :error_3d_secure,
  '403'           => :error_invalid_card_number,
  '404'           => :error_invalid_expiration,
  '405'           => :error_invalid_amount,
  '406'           => :error_invalid_merchant_id,
  '407'           => :error_invalid_merchant_account,
  '408'           => :error_incompatible_card_type,
  '409'           => :error_no_suitable_account,
  '410'           => :error_invalid_transaction_id,
  '411'           => :error_invalid_access_code,
  '412'           => :error_invalid_customer_data,
  '413'           => :error_invalid_external_data,
  '414'           => :error_invalid_customer_id,
  '418'           => :error_invalid_currency,
  '419'           => :error_incompatible_currency,
  '420'           => :error_invalid_rebill_arguments,
  '436'           => :error_incompatible_descriptor,
  '438'           => :error_invalid_site_id,
  '441'           => :error_invoice_not_found,
  '443'           => :error_missing_customer_id,
  '444'           => :error_missing_customer_name,
  '445'           => :error_missing_customer_address,
  '446'           => :error_missing_cvv,
  '448'           => :error_no_active_membership,
  '449'           => :error_invalid_cvv,
  '451'           => :error_invalid_clone_data,
  '452'           => :error_redundant_operation
}
RESPONSE =
{
  '0'             => :success,
  '1'             => :bank_decline,
  '2'             => :rocketgate_scrubbing_decline,
  '3'             => :system_error,
  '4'             => :missing_or_invalid_fields
}