mirror of
				https://github.com/juspay/hyperswitch.git
				synced 2025-10-31 10:06:32 +08:00 
			
		
		
		
	bugfix: check if bank_pm exists and then send (#679)
Co-authored-by: Arun Raj M <jarnura47@gmail.com>
This commit is contained in:
		| @ -2,8 +2,8 @@ | ||||
| enabled = false | ||||
|  | ||||
| [log.console] | ||||
| enabled    = true | ||||
| level      = "DEBUG" | ||||
| enabled = true | ||||
| level = "DEBUG" | ||||
| log_format = "default" | ||||
|  | ||||
| [log.telemetry] | ||||
| @ -11,27 +11,27 @@ enabled = false | ||||
|  | ||||
| # TODO: Update database credentials before running application | ||||
| [master_database] | ||||
| username  = "db_user" | ||||
| password  = "db_pass" | ||||
| host      = "localhost" | ||||
| port      = 5432 | ||||
| dbname    = "hyperswitch_db" | ||||
| username = "db_user" | ||||
| password = "db_pass" | ||||
| host = "localhost" | ||||
| port = 5432 | ||||
| dbname = "hyperswitch_db" | ||||
| pool_size = 5 | ||||
|  | ||||
| [replica_database] | ||||
| username           = "replica_user" | ||||
| password           = "replica_pass" | ||||
| host               = "localhost" | ||||
| port               = 5432 | ||||
| dbname             = "hyperswitch_db" | ||||
| pool_size          = 5 | ||||
| username = "replica_user" | ||||
| password = "replica_pass" | ||||
| host = "localhost" | ||||
| port = 5432 | ||||
| dbname = "hyperswitch_db" | ||||
| pool_size = 5 | ||||
| connection_timeout = 10 | ||||
|  | ||||
| [proxy] | ||||
|  | ||||
| [locker] | ||||
| host          = "" | ||||
| mock_locker   = true | ||||
| host = "" | ||||
| mock_locker = true | ||||
| basilisk_host = "" | ||||
|  | ||||
| [jwekey] | ||||
| @ -43,7 +43,7 @@ locker_decryption_key1 = "" | ||||
| locker_decryption_key2 = "" | ||||
|  | ||||
| [connectors.supported] | ||||
| wallets = [ "klarna", "braintree", "applepay" ] | ||||
| wallets = ["klarna", "braintree", "applepay"] | ||||
| cards = [ | ||||
|     "aci", | ||||
|     "adyen", | ||||
| @ -68,7 +68,7 @@ cards = [ | ||||
|  | ||||
| [refund] | ||||
| max_attempts = 10 | ||||
| max_age      = 365 | ||||
| max_age = 365 | ||||
|  | ||||
| [webhooks] | ||||
| outgoing_enabled = true | ||||
| @ -146,35 +146,39 @@ base_url = "https://api.na.bambora.com" | ||||
| stream = "SCHEDULER_STREAM" | ||||
|  | ||||
| [scheduler.consumer] | ||||
| disabled       = false | ||||
| disabled = false | ||||
| consumer_group = "SCHEDULER_GROUP" | ||||
|  | ||||
| [bank_config.eps] | ||||
| stripe = { banks = "arzte_und_apotheker_bank,austrian_anadi_bank_ag,bank_austriabankhaus_carl_spangler,bankhaus_schelhammer_und_schattera_ag,bawag_psk_ag,bks_bank_ag,brull_kallmus_bank_ag,btv_vier_lander_bank" } | ||||
| adyen  = { banks = "austrian_anadi_bank_ag,bank_austriabankhaus_carl_spangler,bankhaus_schelhammer_und_schattera_ag,bawag_psk_ag,bks_bank_ag,brull_kallmus_bank_ag,btv_vier_lander_bank" } | ||||
| stripe = {banks = "arzte_und_apotheker_bank,austrian_anadi_bank_ag,bank_austria,bankhaus_carl_spangler,bankhaus_schelhammer_und_schattera_ag,bawag_psk_ag,bks_bank_ag,brull_kallmus_bank_ag,btv_vier_lander_bank,capital_bank_grawe_gruppe_ag,dolomitenbank,easybank_ag,erste_bank_und_sparkassen,hypo_alpeadriabank_international_ag,hypo_noe_lb_fur_niederosterreich_u_wien,hypo_oberosterreich_salzburg_steiermark,hypo_tirol_bank_ag,hypo_vorarlberg_bank_ag,hypo_bank_burgenland_aktiengesellschaft,marchfelder_bank,oberbank_ag,raiffeisen_bankengruppe_osterreich,schoellerbank_ag,sparda_bank_wien,volksbank_gruppe,volkskreditbank_ag,vr_bank_braunau"} | ||||
| adyen = {banks = "bank_austria,bawag_psk_ag,dolomitenbank,easybank_ag,erste_bank_und_sparkassen,hypo_tirol_bank_ag,posojilnica_bank_e_gen,raiffeisen_bankengruppe_osterreich,schoellerbank_ag,sparda_bank_wien,volksbank_gruppe,volkskreditbank_ag"} | ||||
|  | ||||
| [bank_config.ideal] | ||||
| stripe = {banks = "abn_amro,asn_bank,bunq,handelsbanken,ing,knab,moneyou,rabobank,regiobank,revolut,sns_bank,triodos_bank,van_lanschot"} | ||||
| adyen = {banks = "abn_amro,asn_bank,bunq,handelsbanken,ing,knab,moneyou,rabobank,regiobank,revolut,sns_bank,triodos_bank,van_lanschot"} | ||||
|  | ||||
| [pm_filters.stripe] | ||||
| google_pay        = { country = "AL,DZ,AS,AO,AG,AR,AU,AT,AZ,BH,BY,BE,BR,BG,CA,CL,CO,HR,CZ,DK,DO,EG,EE,FI,FR,DE,GR,HK,HU,IN,ID,IE,IL,IT,JP,JO,KZ,KE,KW,LV,LB,LT,LU,MY,MX,NL,NZ,NO,OM,PK,PA,PE,PH,PL,PT,QA,RO,RU,SA,SG,SK,ZA,ES,LK,SE,CH,TW,TH,TR,UA,AE,GB,US,UY,VN" } | ||||
| apple_pay         = { country = "AU,CN,HK,JP,MO,MY,NZ,SG,TW,AM,AT,AZ,BY,BE,BG,HR,CY,CZ,DK,EE,FO,FI,FR,GE,DE,GR,GL,GG,HU,IS,IE,IM,IT,KZ,JE,LV,LI,LT,LU,MT,MD,MC,ME,NL,NO,PL,PT,RO,SM,RS,SK,SI,ES,SE,CH,UA,GB,AR,CO,CR,BR,MX,PE,BH,IL,JO,KW,PS,QA,SA,AE,CA,UM,US" } | ||||
| klarna            = { country = "AT,BE,DK,FI,FR,DE,IE,IT,NL,NO,ES,SE,GB,US", currency = "EUR,USD,GBP,DKK,SEK,NOK" } | ||||
| affirm            = { country = "US", currency = "USD" } | ||||
| google_pay = { country = "AL,DZ,AS,AO,AG,AR,AU,AT,AZ,BH,BY,BE,BR,BG,CA,CL,CO,HR,CZ,DK,DO,EG,EE,FI,FR,DE,GR,HK,HU,IN,ID,IE,IL,IT,JP,JO,KZ,KE,KW,LV,LB,LT,LU,MY,MX,NL,NZ,NO,OM,PK,PA,PE,PH,PL,PT,QA,RO,RU,SA,SG,SK,ZA,ES,LK,SE,CH,TW,TH,TR,UA,AE,GB,US,UY,VN" } | ||||
| apple_pay = { country = "AU,CN,HK,JP,MO,MY,NZ,SG,TW,AM,AT,AZ,BY,BE,BG,HR,CY,CZ,DK,EE,FO,FI,FR,GE,DE,GR,GL,GG,HU,IS,IE,IM,IT,KZ,JE,LV,LI,LT,LU,MT,MD,MC,ME,NL,NO,PL,PT,RO,SM,RS,SK,SI,ES,SE,CH,UA,GB,AR,CO,CR,BR,MX,PE,BH,IL,JO,KW,PS,QA,SA,AE,CA,UM,US" } | ||||
| klarna = { country = "AT,BE,DK,FI,FR,DE,IE,IT,NL,NO,ES,SE,GB,US", currency = "EUR,USD,GBP,DKK,SEK,NOK" } | ||||
| affirm = { country = "US", currency = "USD" } | ||||
| afterpay_clearpay = { country = "US,CA,GB,AU,NZ,FR,ES", currency = "USD,CAD,GBP,AUD,NZD,EUR" } | ||||
| giropay           = { country = "DE", currency = "EUR" } | ||||
| eps               = { country = "AT", currency = "EUR" } | ||||
| sofort            = { country = "AT,BE,DE,IT,NL,ES", currency = "EUR" } | ||||
| ideal             = { country = "NL", currency = "EUR" } | ||||
| giropay = { country = "DE", currency = "EUR" } | ||||
| eps = { country = "AT", currency = "EUR" } | ||||
| sofort = { country = "AT,BE,DE,IT,NL,ES", currency = "EUR" } | ||||
| ideal = { country = "NL", currency = "EUR" } | ||||
|  | ||||
| [pm_filters.adyen] | ||||
| google_pay        = { country = "AL,DZ,AS,AO,AG,AR,AU,AT,AZ,BH,BY,BE,BR,BG,CA,CL,CO,HR,CZ,DK,DO,EG,EE,FI,FR,DE,GR,HK,HU,IN,ID,IE,IL,IT,JP,JO,KZ,KE,KW,LV,LB,LT,LU,MY,MX,NL,NZ,NO,OM,PK,PA,PE,PH,PL,PT,QA,RO,RU,SA,SG,SK,ZA,ES,LK,SE,CH,TW,TH,TR,UA,AE,GB,US,UY,VN" } | ||||
| apple_pay         = { country = "AU,CN,HK,JP,MO,MY,NZ,SG,TW,AM,AT,AZ,BY,BE,BG,HR,CY,CZ,DK,EE,FO,FI,FR,GE,DE,GR,GL,GG,HU,IS,IE,IM,IT,KZ,JE,LV,LI,LT,LU,MT,MD,MC,ME,NL,NO,PL,PT,RO,SM,RS,SK,SI,ES,SE,CH,UA,GB,AR,CO,CR,BR,MX,PE,BH,IL,JO,KW,PS,QA,SA,AE,CA,UM,US", currency = "AUD,CHF,CAD,EUR,GBP,HKD,SGD,USD" } | ||||
| paypal            = { currency = "AUD,BRL,CAD,CZK,DKK,EUR,HKD,HUF,INR,JPY,MYR,MXN,NZD,NOK,PHP,PLN,RUB,GBP,SGD,SEK,CHF,THB,USD" } | ||||
| klarna            = { country = "AT,BE,DK,FI,FR,DE,IE,IT,NL,NO,ES,SE,GB,US,CA", currency = "USD,GBP,EUR,CHF,DKK,SEK,NOK,AUD,PLN,CAD" } | ||||
| affirm            = { country = "US", currency = "USD" } | ||||
| google_pay = { country = "AL,DZ,AS,AO,AG,AR,AU,AT,AZ,BH,BY,BE,BR,BG,CA,CL,CO,HR,CZ,DK,DO,EG,EE,FI,FR,DE,GR,HK,HU,IN,ID,IE,IL,IT,JP,JO,KZ,KE,KW,LV,LB,LT,LU,MY,MX,NL,NZ,NO,OM,PK,PA,PE,PH,PL,PT,QA,RO,RU,SA,SG,SK,ZA,ES,LK,SE,CH,TW,TH,TR,UA,AE,GB,US,UY,VN" } | ||||
| apple_pay = { country = "AU,CN,HK,JP,MO,MY,NZ,SG,TW,AM,AT,AZ,BY,BE,BG,HR,CY,CZ,DK,EE,FO,FI,FR,GE,DE,GR,GL,GG,HU,IS,IE,IM,IT,KZ,JE,LV,LI,LT,LU,MT,MD,MC,ME,NL,NO,PL,PT,RO,SM,RS,SK,SI,ES,SE,CH,UA,GB,AR,CO,CR,BR,MX,PE,BH,IL,JO,KW,PS,QA,SA,AE,CA,UM,US", currency = "AUD,CHF,CAD,EUR,GBP,HKD,SGD,USD" } | ||||
| paypal = { currency = "AUD,BRL,CAD,CZK,DKK,EUR,HKD,HUF,INR,JPY,MYR,MXN,NZD,NOK,PHP,PLN,RUB,GBP,SGD,SEK,CHF,THB,USD" } | ||||
| klarna = { country = "AT,BE,DK,FI,FR,DE,IE,IT,NL,NO,ES,SE,GB,US,CA", currency = "USD,GBP,EUR,CHF,DKK,SEK,NOK,AUD,PLN,CAD" } | ||||
| affirm = { country = "US", currency = "USD" } | ||||
| afterpay_clearpay = { country = "US,CA,GB,AU,NZ,FR,ES", currency = "GBP" } | ||||
| giropay           = { country = "DE", currency = "EUR" } | ||||
| eps               = { country = "AT", currency = "EUR" } | ||||
| sofort            = { country = "ES,GB,SE,AT,NL,DE,CH,BE,FR,FI,IT,PL", currency = "EUR" } | ||||
| ideal             = { country = "NL", currency = "EUR" } | ||||
| giropay = { country = "DE", currency = "EUR" } | ||||
| eps = { country = "AT", currency = "EUR" } | ||||
| sofort = { country = "ES,GB,SE,AT,NL,DE,CH,BE,FR,FI,IT,PL", currency = "EUR" } | ||||
| ideal = { country = "NL", currency = "EUR" } | ||||
|  | ||||
| [pm_filters.braintree] | ||||
| paypal = { currency = "AUD,BRL,CAD,CNY,CZK,DKK,EUR,HKD,HUF,ILS,JPY,MYR,MXN,TWD,NZD,NOK,PHP,PLN,GBP,RUB,SGD,SEK,CHF,THB,USD" } | ||||
| @ -184,8 +188,8 @@ klarna = { country = "AU,AT,BE,CA,CZ,DK,FI,FR,DE,GR,IE,IT,NL,NZ,NO,PL,PT,ES,SE,C | ||||
|  | ||||
| [pm_filters.authorizedotnet] | ||||
| google_pay = { currency = "CHF,DKK,EUR,GBP,NOK,PLN,SEK,USD,AUD,NZD,CAD" } | ||||
| paypal     = { currency = "CHF,DKK,EUR,GBP,NOK,PLN,SEK,USD,AUD,NZD,CAD" } | ||||
| paypal = { currency = "CHF,DKK,EUR,GBP,NOK,PLN,SEK,USD,AUD,NZD,CAD" } | ||||
|  | ||||
| [pm_filters.worldpay] | ||||
| google_pay = { country = "AL,DZ,AS,AO,AG,AR,AU,AT,AZ,BH,BY,BE,BR,BG,CA,CL,CO,HR,CZ,DK,DO,EG,EE,FI,FR,DE,GR,HK,HU,IN,ID,IE,IL,IT,JP,JO,KZ,KE,KW,LV,LB,LT,LU,MY,MX,NL,NZ,NO,OM,PK,PA,PE,PH,PL,PT,QA,RO,RU,SA,SG,SK,ZA,ES,LK,SE,CH,TW,TH,TR,UA,AE,GB,US,UY,VN" } | ||||
| apple_pay  = { country = "AU,CN,HK,JP,MO,MY,NZ,SG,TW,AM,AT,AZ,BY,BE,BG,HR,CY,CZ,DK,EE,FO,FI,FR,GE,DE,GR,GL,GG,HU,IS,IE,IM,IT,KZ,JE,LV,LI,LT,LU,MT,MD,MC,ME,NL,NO,PL,PT,RO,SM,RS,SK,SI,ES,SE,CH,UA,GB,AR,CO,CR,BR,MX,PE,BH,IL,JO,KW,PS,QA,SA,AE,CA,UM,US" } | ||||
| apple_pay = { country = "AU,CN,HK,JP,MO,MY,NZ,SG,TW,AM,AT,AZ,BY,BE,BG,HR,CY,CZ,DK,EE,FO,FI,FR,GE,DE,GR,GL,GG,HU,IS,IE,IM,IT,KZ,JE,LV,LI,LT,LU,MT,MD,MC,ME,NL,NO,PL,PT,RO,SM,RS,SK,SI,ES,SE,CH,UA,GB,AR,CO,CR,BR,MX,PE,BH,IL,JO,KW,PS,QA,SA,AE,CA,UM,US" } | ||||
|  | ||||
| @ -659,10 +659,12 @@ pub async fn list_payment_methods( | ||||
|         }) | ||||
|     } | ||||
|  | ||||
|     payment_method_responses.push(ResponsePaymentMethodsEnabled { | ||||
|         payment_method: api_enums::PaymentMethod::BankRedirect, | ||||
|         payment_method_types: bank_payment_method_types, | ||||
|     }); | ||||
|     if !bank_payment_method_types.is_empty() { | ||||
|         payment_method_responses.push(ResponsePaymentMethodsEnabled { | ||||
|             payment_method: api_enums::PaymentMethod::BankRedirect, | ||||
|             payment_method_types: bank_payment_method_types, | ||||
|         }); | ||||
|     } | ||||
|  | ||||
|     response | ||||
|         .is_empty() | ||||
|  | ||||
		Reference in New Issue
	
	Block a user
	 Narayan Bhat
					Narayan Bhat