mirror of
https://github.com/juspay/hyperswitch.git
synced 2025-10-29 00:49:42 +08:00
feat(connector): [BLUECODE] Added Template Code (#8756)
Co-authored-by: Sayak Bhattacharya <sayak.b@Sayak-Bhattacharya-G092THXJ34.local> Co-authored-by: hyperswitch-bot[bot] <148525504+hyperswitch-bot[bot]@users.noreply.github.com> Co-authored-by: sakksham7 <130480324+sakksham7@users.noreply.github.com>
This commit is contained in:
committed by
GitHub
parent
1e6a088c04
commit
9f6182b7fb
@ -9,13 +9,13 @@ pub use hyperswitch_connectors::connectors::{
|
||||
authorizedotnet::Authorizedotnet, bambora, bambora::Bambora, bamboraapac,
|
||||
bamboraapac::Bamboraapac, bankofamerica, bankofamerica::Bankofamerica, barclaycard,
|
||||
barclaycard::Barclaycard, billwerk, billwerk::Billwerk, bitpay, bitpay::Bitpay,
|
||||
blackhawknetwork, blackhawknetwork::Blackhawknetwork, bluesnap, bluesnap::Bluesnap, boku,
|
||||
boku::Boku, braintree, braintree::Braintree, breadpay, breadpay::Breadpay, cashtocode,
|
||||
cashtocode::Cashtocode, celero, celero::Celero, chargebee, chargebee::Chargebee, checkbook,
|
||||
checkbook::Checkbook, checkout, checkout::Checkout, coinbase, coinbase::Coinbase, coingate,
|
||||
coingate::Coingate, cryptopay, cryptopay::Cryptopay, ctp_mastercard,
|
||||
ctp_mastercard::CtpMastercard, custombilling, custombilling::Custombilling, cybersource,
|
||||
cybersource::Cybersource, datatrans, datatrans::Datatrans, deutschebank,
|
||||
blackhawknetwork, blackhawknetwork::Blackhawknetwork, bluecode, bluecode::Bluecode, bluesnap,
|
||||
bluesnap::Bluesnap, boku, boku::Boku, braintree, braintree::Braintree, breadpay,
|
||||
breadpay::Breadpay, cashtocode, cashtocode::Cashtocode, celero, celero::Celero, chargebee,
|
||||
chargebee::Chargebee, checkbook, checkbook::Checkbook, checkout, checkout::Checkout, coinbase,
|
||||
coinbase::Coinbase, coingate, coingate::Coingate, cryptopay, cryptopay::Cryptopay,
|
||||
ctp_mastercard, ctp_mastercard::CtpMastercard, custombilling, custombilling::Custombilling,
|
||||
cybersource, cybersource::Cybersource, datatrans, datatrans::Datatrans, deutschebank,
|
||||
deutschebank::Deutschebank, digitalvirgo, digitalvirgo::Digitalvirgo, dlocal, dlocal::Dlocal,
|
||||
dwolla, dwolla::Dwolla, ebanx, ebanx::Ebanx, elavon, elavon::Elavon, facilitapay,
|
||||
facilitapay::Facilitapay, fiserv, fiserv::Fiserv, fiservemea, fiservemea::Fiservemea, fiuu,
|
||||
|
||||
@ -129,6 +129,10 @@ impl ConnectorAuthTypeAndMetadataValidation<'_> {
|
||||
bluesnap::transformers::BluesnapAuthType::try_from(self.auth_type)?;
|
||||
Ok(())
|
||||
}
|
||||
// api_enums::Connector::Bluecode => {
|
||||
// bluecode::transformers::BluecodeAuthType::try_from(self.auth_type)?;
|
||||
// Ok(())
|
||||
// }
|
||||
api_enums::Connector::Braintree => {
|
||||
braintree::transformers::BraintreeAuthType::try_from(self.auth_type)?;
|
||||
braintree::transformers::BraintreeMeta::try_from(self.connector_meta_data)?;
|
||||
|
||||
@ -2041,16 +2041,21 @@ pub async fn is_ucs_enabled(state: &SessionState, config_key: &str) -> bool {
|
||||
let db = state.store.as_ref();
|
||||
db.find_config_by_key_unwrap_or(config_key, Some("false".to_string()))
|
||||
.await
|
||||
.map_err(|error| {
|
||||
.inspect_err(|error| {
|
||||
logger::error!(
|
||||
?error,
|
||||
"Failed to fetch `{config_key}` UCS enabled config from DB"
|
||||
);
|
||||
})
|
||||
.ok()
|
||||
.and_then(|config| {
|
||||
config.config.parse::<bool>().map_err(|error| {
|
||||
logger::error!(?error, "Failed to parse `{config_key}` UCS enabled config");
|
||||
})
|
||||
config
|
||||
.config
|
||||
.parse::<bool>()
|
||||
.inspect_err(|error| {
|
||||
logger::error!(?error, "Failed to parse `{config_key}` UCS enabled config");
|
||||
})
|
||||
.ok()
|
||||
})
|
||||
.unwrap_or(false)
|
||||
}
|
||||
|
||||
@ -144,6 +144,9 @@ impl ConnectorData {
|
||||
enums::Connector::Bluesnap => {
|
||||
Ok(ConnectorEnum::Old(Box::new(connector::Bluesnap::new())))
|
||||
}
|
||||
// enums::Connector::Bluecode => {
|
||||
// Ok(ConnectorEnum::Old(Box::new(connector::Bluecode::new())))
|
||||
// }
|
||||
enums::Connector::Boku => Ok(ConnectorEnum::Old(Box::new(connector::Boku::new()))),
|
||||
enums::Connector::Braintree => {
|
||||
Ok(ConnectorEnum::Old(Box::new(connector::Braintree::new())))
|
||||
|
||||
@ -22,6 +22,7 @@ impl ForeignTryFrom<api_enums::Connector> for common_enums::RoutableConnectors {
|
||||
api_enums::Connector::Billwerk => Self::Billwerk,
|
||||
api_enums::Connector::Bitpay => Self::Bitpay,
|
||||
api_enums::Connector::Bluesnap => Self::Bluesnap,
|
||||
// api_enums::Connector::Bluecode => Self::Bluecode,
|
||||
api_enums::Connector::Boku => Self::Boku,
|
||||
api_enums::Connector::Braintree => Self::Braintree,
|
||||
api_enums::Connector::Breadpay => Self::Breadpay,
|
||||
|
||||
Reference in New Issue
Block a user