id stringlengths 11 116 | type stringclasses 1 value | granularity stringclasses 4 values | content stringlengths 16 477k | metadata dict |
|---|---|---|---|---|
fn_clm_router_get_default_payment_info_7310687942263774903 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/tsys
fn get_default_payment_info() -> Option<utils::PaymentInfo> {
None
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 7278,
"total_crates": null
} |
fn_clm_router_payment_method_details_7310687942263774903 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/tsys
fn payment_method_details(amount: i64) -> Option<types::PaymentsAuthorizeData> {
Some(types::PaymentsAuthorizeData {
amount,
payment_method_data: domain::PaymentMethodData::Card(domain::Card {
card_number: CardNumber::from_str("4111111111111111").unwrap(),
..utils::CCardType::default().0
}),
..utils::PaymentAuthorizeType::default().0
})
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 4406,
"total_crates": null
} |
fn_clm_router_get_name_7310687942263774903 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/tsys
// Implementation of TsysTest for utils::Connector
fn get_name(&self) -> String {
"tsys".to_string()
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 46,
"total_crates": null
} |
fn_clm_router_get_data_7310687942263774903 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/tsys
// Implementation of TsysTest for utils::Connector
fn get_data(&self) -> types::api::ConnectorData {
use router::connector::Tsys;
utils::construct_connector_data_old(
Box::new(Tsys::new()),
types::Connector::Tsys,
types::api::GetToken::Connector,
None,
)
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 41,
"total_crates": null
} |
fn_clm_router_get_auth_token_7310687942263774903 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/tsys
// Implementation of TsysTest for utils::Connector
fn get_auth_token(&self) -> types::ConnectorAuthType {
utils::to_connector_auth_type(
connector_auth::ConnectorAuthentication::new()
.tsys
.expect("Missing connector authentication configuration")
.into(),
)
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 32,
"total_crates": null
} |
fn_clm_router_get_default_payment_info_-1559009153578484443 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/hyperwallet
fn get_default_payment_info() -> Option<utils::PaymentInfo> {
None
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 7278,
"total_crates": null
} |
fn_clm_router_payment_method_details_-1559009153578484443 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/hyperwallet
fn payment_method_details() -> Option<types::PaymentsAuthorizeData> {
None
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 4398,
"total_crates": null
} |
fn_clm_router_get_name_-1559009153578484443 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/hyperwallet
// Implementation of HyperwalletTest for utils::Connector
fn get_name(&self) -> String {
"hyperwallet".to_string()
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 46,
"total_crates": null
} |
fn_clm_router_get_data_-1559009153578484443 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/hyperwallet
// Implementation of HyperwalletTest for utils::Connector
fn get_data(&self) -> api::ConnectorData {
use router::connector::Hyperwallet;
utils::construct_connector_data_old(
Box::new(Hyperwallet::new()),
types::Connector::Plaid,
api::GetToken::Connector,
None,
)
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 41,
"total_crates": null
} |
fn_clm_router_get_auth_token_-1559009153578484443 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/hyperwallet
// Implementation of HyperwalletTest for utils::Connector
fn get_auth_token(&self) -> types::ConnectorAuthType {
utils::to_connector_auth_type(
connector_auth::ConnectorAuthentication::new()
.hyperwallet
.expect("Missing connector authentication configuration")
.into(),
)
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 32,
"total_crates": null
} |
fn_clm_router_get_default_payment_info_7687820590040990858 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/cryptopay
fn get_default_payment_info() -> Option<utils::PaymentInfo> {
Some(utils::PaymentInfo {
address: Some(PaymentAddress::new(
None,
Some(Address {
address: Some(AddressDetails {
first_name: Some(Secret::new("first".to_string())),
last_name: Some(Secret::new("last".to_string())),
line1: Some(Secret::new("line1".to_string())),
line2: Some(Secret::new("line2".to_string())),
city: Some("city".to_string()),
zip: Some(Secret::new("zip".to_string())),
country: Some(api_models::enums::CountryAlpha2::IN),
..Default::default()
}),
phone: Some(PhoneDetails {
number: Some(Secret::new("9123456789".to_string())),
country_code: Some("+91".to_string()),
}),
email: None,
}),
None,
None,
)),
..Default::default()
})
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 7312,
"total_crates": null
} |
fn_clm_router_payment_method_details_7687820590040990858 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/cryptopay
fn payment_method_details() -> Option<types::PaymentsAuthorizeData> {
Some(types::PaymentsAuthorizeData {
amount: 1,
currency: enums::Currency::USD,
payment_method_data: domain::PaymentMethodData::Crypto(domain::CryptoData {
pay_currency: Some("XRP".to_string()),
network: None,
}),
confirm: true,
statement_descriptor_suffix: None,
statement_descriptor: None,
setup_future_usage: None,
mandate_id: None,
off_session: None,
setup_mandate_details: None,
browser_info: None,
order_details: None,
order_category: None,
email: None,
customer_name: None,
payment_experience: None,
payment_method_type: None,
session_token: None,
enrolled_for_3ds: false,
related_transaction_id: None,
router_return_url: Some(String::from("https://google.com/")),
webhook_url: None,
complete_authorize_url: None,
capture_method: None,
customer_id: None,
surcharge_details: None,
request_incremental_authorization: false,
metadata: None,
authentication_data: None,
customer_acceptance: None,
..utils::PaymentAuthorizeType::default().0
})
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 4406,
"total_crates": null
} |
fn_clm_router_get_name_7687820590040990858 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/cryptopay
// Implementation of CryptopayTest for utils::Connector
fn get_name(&self) -> String {
"cryptopay".to_string()
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 46,
"total_crates": null
} |
fn_clm_router_get_data_7687820590040990858 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/cryptopay
// Implementation of CryptopayTest for utils::Connector
fn get_data(&self) -> api::ConnectorData {
use router::connector::Cryptopay;
utils::construct_connector_data_old(
Box::new(Cryptopay::new()),
types::Connector::Cryptopay,
api::GetToken::Connector,
None,
)
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 41,
"total_crates": null
} |
fn_clm_router_get_auth_token_7687820590040990858 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/cryptopay
// Implementation of CryptopayTest for utils::Connector
fn get_auth_token(&self) -> types::ConnectorAuthType {
utils::to_connector_auth_type(
connector_auth::ConnectorAuthentication::new()
.cryptopay
.expect("Missing connector authentication configuration")
.into(),
)
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 32,
"total_crates": null
} |
fn_clm_router_get_default_payment_info_8178527839014475052 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/checkout
fn get_default_payment_info() -> Option<utils::PaymentInfo> {
None
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 7278,
"total_crates": null
} |
fn_clm_router_payment_method_details_8178527839014475052 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/checkout
fn payment_method_details() -> Option<types::PaymentsAuthorizeData> {
None
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 4398,
"total_crates": null
} |
fn_clm_router_get_name_8178527839014475052 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/checkout
// Implementation of CheckoutTest for utils::Connector
fn get_name(&self) -> String {
"checkout".to_string()
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 46,
"total_crates": null
} |
fn_clm_router_get_data_8178527839014475052 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/checkout
// Implementation of CheckoutTest for utils::Connector
fn get_data(&self) -> types::api::ConnectorData {
use router::connector::Checkout;
utils::construct_connector_data_old(
Box::new(Checkout::new()),
types::Connector::Checkout,
types::api::GetToken::Connector,
None,
)
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 41,
"total_crates": null
} |
fn_clm_router_get_auth_token_8178527839014475052 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/checkout
// Implementation of CheckoutTest for utils::Connector
fn get_auth_token(&self) -> types::ConnectorAuthType {
utils::to_connector_auth_type(
connector_auth::ConnectorAuthentication::new()
.checkout
.expect("Missing connector authentication configuration")
.into(),
)
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 32,
"total_crates": null
} |
fn_clm_router_get_default_payment_info_3924116375193633722 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/billwerk
fn get_default_payment_info() -> Option<utils::PaymentInfo> {
None
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 7278,
"total_crates": null
} |
fn_clm_router_payment_method_details_3924116375193633722 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/billwerk
fn payment_method_details() -> Option<types::PaymentsAuthorizeData> {
None
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 4398,
"total_crates": null
} |
fn_clm_router_get_name_3924116375193633722 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/billwerk
// Implementation of BillwerkTest for utils::Connector
fn get_name(&self) -> String {
"billwerk".to_string()
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 46,
"total_crates": null
} |
fn_clm_router_get_data_3924116375193633722 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/billwerk
// Implementation of BillwerkTest for utils::Connector
fn get_data(&self) -> types::api::ConnectorData {
use router::connector::Billwerk;
utils::construct_connector_data_old(
Box::new(Billwerk::new()),
// Added as Dummy connector as template code is added for future usage
types::Connector::DummyConnector1,
types::api::GetToken::Connector,
None,
)
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 41,
"total_crates": null
} |
fn_clm_router_get_auth_token_3924116375193633722 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/billwerk
// Implementation of BillwerkTest for utils::Connector
fn get_auth_token(&self) -> types::ConnectorAuthType {
utils::to_connector_auth_type(
connector_auth::ConnectorAuthentication::new()
.billwerk
.expect("Missing connector authentication configuration")
.into(),
)
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 32,
"total_crates": null
} |
fn_clm_router_get_payment_authorize_data_7296667990497110747 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/nmi
fn get_payment_authorize_data() -> Option<types::PaymentsAuthorizeData> {
Some(types::PaymentsAuthorizeData {
payment_method_data: domain::PaymentMethodData::Card(domain::Card {
card_number: cards::CardNumber::from_str("4111111111111111").unwrap(),
..utils::CCardType::default().0
}),
amount: 2023,
..utils::PaymentAuthorizeType::default().0
})
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 215,
"total_crates": null
} |
fn_clm_router_get_name_7296667990497110747 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/nmi
// Implementation of NmiTest for utils::Connector
fn get_name(&self) -> String {
"nmi".to_string()
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 46,
"total_crates": null
} |
fn_clm_router_get_data_7296667990497110747 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/nmi
// Implementation of NmiTest for utils::Connector
fn get_data(&self) -> types::api::ConnectorData {
use router::connector::Nmi;
utils::construct_connector_data_old(
Box::new(Nmi::new()),
types::Connector::Nmi,
types::api::GetToken::Connector,
None,
)
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 41,
"total_crates": null
} |
fn_clm_router_should_partially_refund_manually_captured_payment_7296667990497110747 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/nmi
async fn should_partially_refund_manually_captured_payment() {
let response = CONNECTOR
.authorize_payment(get_payment_authorize_data(), None)
.await
.unwrap();
assert_eq!(response.status, enums::AttemptStatus::Authorizing);
let transaction_id = utils::get_connector_transaction_id(response.response.to_owned()).unwrap();
let sync_response = CONNECTOR
.psync_retry_till_status_matches(
enums::AttemptStatus::Authorized,
Some(types::PaymentsSyncData {
connector_transaction_id: types::ResponseId::ConnectorTransactionId(
transaction_id.clone(),
),
capture_method: Some(enums::CaptureMethod::Manual),
..Default::default()
}),
None,
)
.await
.unwrap();
assert_eq!(sync_response.status, enums::AttemptStatus::Authorized);
let capture_response = CONNECTOR
.capture_payment(
transaction_id.clone(),
Some(types::PaymentsCaptureData {
amount_to_capture: 2023,
..utils::PaymentCaptureType::default().0
}),
None,
)
.await
.unwrap();
assert_eq!(
capture_response.status,
enums::AttemptStatus::CaptureInitiated
);
let sync_response = CONNECTOR
.psync_retry_till_status_matches(
enums::AttemptStatus::Pending,
Some(types::PaymentsSyncData {
connector_transaction_id: types::ResponseId::ConnectorTransactionId(
transaction_id.clone(),
),
capture_method: Some(enums::CaptureMethod::Manual),
..Default::default()
}),
None,
)
.await
.unwrap();
assert_eq!(sync_response.status, enums::AttemptStatus::Pending);
let refund_response = CONNECTOR
.refund_payment(
transaction_id.clone(),
Some(types::RefundsData {
refund_amount: 1023,
..utils::PaymentRefundType::default().0
}),
None,
)
.await
.unwrap();
assert_eq!(refund_response.status, enums::AttemptStatus::Pending);
let sync_response = CONNECTOR
.rsync_retry_till_status_matches(
enums::RefundStatus::Pending,
refund_response.response.unwrap().connector_refund_id,
None,
None,
)
.await
.unwrap();
assert_eq!(
sync_response.response.unwrap().refund_status,
enums::RefundStatus::Pending
);
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 38,
"total_crates": null
} |
fn_clm_router_should_void_authorized_payment_7296667990497110747 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/nmi
async fn should_void_authorized_payment() {
let response = CONNECTOR
.authorize_payment(get_payment_authorize_data(), None)
.await
.unwrap();
assert_eq!(response.status, enums::AttemptStatus::Authorizing);
let transaction_id = utils::get_connector_transaction_id(response.response.to_owned()).unwrap();
let sync_response = CONNECTOR
.psync_retry_till_status_matches(
enums::AttemptStatus::Authorized,
Some(types::PaymentsSyncData {
connector_transaction_id: types::ResponseId::ConnectorTransactionId(
transaction_id.clone(),
),
capture_method: Some(enums::CaptureMethod::Manual),
..Default::default()
}),
None,
)
.await
.unwrap();
assert_eq!(sync_response.status, enums::AttemptStatus::Authorized);
let void_response = CONNECTOR
.void_payment(
transaction_id.clone(),
Some(types::PaymentsCancelData {
connector_transaction_id: String::from(""),
cancellation_reason: Some("user_cancel".to_string()),
..Default::default()
}),
None,
)
.await
.unwrap();
assert_eq!(void_response.status, enums::AttemptStatus::VoidInitiated);
let sync_response = CONNECTOR
.psync_retry_till_status_matches(
enums::AttemptStatus::Voided,
Some(types::PaymentsSyncData {
connector_transaction_id: types::ResponseId::ConnectorTransactionId(
transaction_id.clone(),
),
capture_method: Some(enums::CaptureMethod::Manual),
..Default::default()
}),
None,
)
.await
.unwrap();
assert_eq!(sync_response.status, enums::AttemptStatus::Voided);
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 34,
"total_crates": null
} |
fn_clm_router_get_default_payment_info_-2998744463150842155 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/ebanx
fn get_default_payment_info() -> Option<utils::PaymentInfo> {
None
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 7278,
"total_crates": null
} |
fn_clm_router_payment_method_details_-2998744463150842155 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/ebanx
fn payment_method_details() -> Option<types::PaymentsAuthorizeData> {
None
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 4398,
"total_crates": null
} |
fn_clm_router_get_name_-2998744463150842155 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/ebanx
// Implementation of EbanxTest for utils::Connector
fn get_name(&self) -> String {
"ebanx".to_string()
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 46,
"total_crates": null
} |
fn_clm_router_get_data_-2998744463150842155 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/ebanx
// Implementation of EbanxTest for utils::Connector
fn get_data(&self) -> types::api::ConnectorData {
use router::connector::Ebanx;
utils::construct_connector_data_old(
Box::new(Ebanx::new()),
types::Connector::Ebanx,
types::api::GetToken::Connector,
None,
)
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 41,
"total_crates": null
} |
fn_clm_router_get_auth_token_-2998744463150842155 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/ebanx
// Implementation of EbanxTest for utils::Connector
fn get_auth_token(&self) -> types::ConnectorAuthType {
utils::to_connector_auth_type(
connector_auth::ConnectorAuthentication::new()
.ebanx
.expect("Missing connector authentication configuration")
.into(),
)
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 32,
"total_crates": null
} |
fn_clm_router_get_default_payment_info_-250649340186479374 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/aci
fn get_default_payment_info() -> Option<PaymentInfo> {
Some(PaymentInfo {
address: Some(PaymentAddress::new(
None,
Some(Address {
address: Some(AddressDetails {
first_name: Some(Secret::new("John".to_string())),
last_name: Some(Secret::new("Doe".to_string())),
line1: Some(Secret::new("123 Main St".to_string())),
city: Some("New York".to_string()),
state: Some(Secret::new("NY".to_string())),
zip: Some(Secret::new("10001".to_string())),
country: Some(enums::CountryAlpha2::US),
..Default::default()
}),
phone: Some(PhoneDetails {
number: Some(Secret::new("+1234567890".to_string())),
country_code: Some("+1".to_string()),
}),
email: None,
}),
None,
None,
)),
..Default::default()
})
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 7312,
"total_crates": null
} |
fn_clm_router_get_payment_authorize_data_-250649340186479374 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/aci
fn get_payment_authorize_data() -> Option<types::PaymentsAuthorizeData> {
Some(types::PaymentsAuthorizeData {
payment_method_data: PaymentMethodData::Card(Card {
card_number: cards::CardNumber::from_str("4200000000000000").unwrap(),
card_exp_month: Secret::new("10".to_string()),
card_exp_year: Secret::new("2025".to_string()),
card_cvc: Secret::new("999".to_string()),
card_holder_name: Some(Secret::new("John Doe".to_string())),
..utils::CCardType::default().0
}),
..utils::PaymentAuthorizeType::default().0
})
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 231,
"total_crates": null
} |
fn_clm_router_get_threeds_payment_authorize_data_-250649340186479374 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/aci
fn get_threeds_payment_authorize_data() -> Option<types::PaymentsAuthorizeData> {
Some(types::PaymentsAuthorizeData {
payment_method_data: PaymentMethodData::Card(Card {
card_number: cards::CardNumber::from_str("4200000000000000").unwrap(),
card_exp_month: Secret::new("10".to_string()),
card_exp_year: Secret::new("2025".to_string()),
card_cvc: Secret::new("999".to_string()),
card_holder_name: Some(Secret::new("John Doe".to_string())),
..utils::CCardType::default().0
}),
enrolled_for_3ds: true,
authentication_data: Some(AuthenticationData {
eci: Some("05".to_string()),
cavv: Secret::new("jJ81HADVRtXfCBATEp01CJUAAAA".to_string()),
threeds_server_transaction_id: Some("9458d8d4-f19f-4c28-b5c7-421b1dd2e1aa".to_string()),
message_version: Some(common_utils::types::SemanticVersion::new(2, 1, 0)),
ds_trans_id: Some("97267598FAE648F28083B2D2AF7B1234".to_string()),
created_at: common_utils::date_time::now(),
challenge_code: Some("01".to_string()),
challenge_cancel: None,
challenge_code_reason: Some("01".to_string()),
message_extension: None,
acs_trans_id: None,
authentication_type: None,
}),
..utils::PaymentAuthorizeType::default().0
})
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 51,
"total_crates": null
} |
fn_clm_router_get_name_-250649340186479374 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/aci
// Implementation of AciTest for utils::Connector
fn get_name(&self) -> String {
"aci".to_string()
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 46,
"total_crates": null
} |
fn_clm_router_get_data_-250649340186479374 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/aci
// Implementation of AciTest for utils::Connector
fn get_data(&self) -> types::api::ConnectorData {
use router::connector::Aci;
utils::construct_connector_data_old(
Box::new(Aci::new()),
types::Connector::Aci,
types::api::GetToken::Connector,
None,
)
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 41,
"total_crates": null
} |
fn_clm_router_get_name_-6986646978551845609 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/zen
// Implementation of ZenTest for utils::Connector
fn get_name(&self) -> String {
"zen".to_string()
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 46,
"total_crates": null
} |
fn_clm_router_get_data_-6986646978551845609 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/zen
// Implementation of ZenTest for utils::Connector
fn get_data(&self) -> types::api::ConnectorData {
use router::connector::Zen;
utils::construct_connector_data_old(
Box::new(&Zen),
types::Connector::Zen,
types::api::GetToken::Connector,
None,
)
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 39,
"total_crates": null
} |
fn_clm_router_get_auth_token_-6986646978551845609 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/zen
// Implementation of ZenTest for utils::Connector
fn get_auth_token(&self) -> types::ConnectorAuthType {
utils::to_connector_auth_type(
connector_auth::ConnectorAuthentication::new()
.zen
.expect("Missing connector authentication configuration")
.into(),
)
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 32,
"total_crates": null
} |
fn_clm_router_should_fail_payment_for_incorrect_cvc_-6986646978551845609 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/zen
async fn should_fail_payment_for_incorrect_cvc() {
let response = CONNECTOR
.make_payment(
Some(types::PaymentsAuthorizeData {
payment_method_data: domain::PaymentMethodData::Card(domain::Card {
card_cvc: Secret::new("12345".to_string()),
..utils::CCardType::default().0
}),
order_details: Some(vec![OrderDetailsWithAmount {
product_name: "iphone 13".to_string(),
quantity: 1,
amount: MinorUnit::new(1000),
product_img_link: None,
requires_shipping: None,
product_id: None,
category: None,
sub_category: None,
brand: None,
product_type: None,
product_tax_code: None,
tax_rate: None,
total_tax_amount: None,
description: None,
sku: None,
upc: None,
commodity_code: None,
unit_of_measure: None,
total_amount: None,
unit_discount_amount: None,
}]),
email: Some(Email::from_str("test@gmail.com").unwrap()),
webhook_url: Some("https://1635-116-74-253-164.ngrok-free.app".to_string()),
..utils::PaymentAuthorizeType::default().0
}),
None,
)
.await
.unwrap();
assert_eq!(
response
.response
.unwrap_err()
.message
.split_once(';')
.unwrap()
.0,
"Request data doesn't pass validation".to_string(),
);
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 16,
"total_crates": null
} |
fn_clm_router_should_fail_payment_for_invalid_exp_month_-6986646978551845609 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/zen
async fn should_fail_payment_for_invalid_exp_month() {
let response = CONNECTOR
.make_payment(
Some(types::PaymentsAuthorizeData {
payment_method_data: domain::PaymentMethodData::Card(domain::Card {
card_exp_month: Secret::new("20".to_string()),
..utils::CCardType::default().0
}),
order_details: Some(vec![OrderDetailsWithAmount {
product_name: "iphone 13".to_string(),
quantity: 1,
amount: MinorUnit::new(1000),
product_img_link: None,
requires_shipping: None,
product_id: None,
category: None,
sub_category: None,
brand: None,
product_type: None,
product_tax_code: None,
tax_rate: None,
total_tax_amount: None,
description: None,
sku: None,
upc: None,
commodity_code: None,
unit_of_measure: None,
total_amount: None,
unit_discount_amount: None,
}]),
email: Some(Email::from_str("test@gmail.com").unwrap()),
webhook_url: Some("https://1635-116-74-253-164.ngrok-free.app".to_string()),
..utils::PaymentAuthorizeType::default().0
}),
None,
)
.await
.unwrap();
assert_eq!(
response
.response
.unwrap_err()
.message
.split_once(';')
.unwrap()
.0,
"Request data doesn't pass validation".to_string(),
);
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 16,
"total_crates": null
} |
fn_clm_router_get_default_payment_info_-6771071247463227708 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/elavon
fn get_default_payment_info() -> Option<utils::PaymentInfo> {
None
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 7278,
"total_crates": null
} |
fn_clm_router_payment_method_details_-6771071247463227708 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/elavon
fn payment_method_details() -> Option<types::PaymentsAuthorizeData> {
None
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 4398,
"total_crates": null
} |
fn_clm_router_get_name_-6771071247463227708 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/elavon
// Implementation of ElavonTest for utils::Connector
fn get_name(&self) -> String {
"elavon".to_string()
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 46,
"total_crates": null
} |
fn_clm_router_get_data_-6771071247463227708 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/elavon
// Implementation of ElavonTest for utils::Connector
fn get_data(&self) -> api::ConnectorData {
use router::connector::Elavon;
utils::construct_connector_data_old(
Box::new(Elavon::new()),
types::Connector::Plaid,
api::GetToken::Connector,
None,
)
// api::ConnectorData {
// connector: Box::new(Elavon::new()),
// connector_name: types::Connector::Elavon,
// get_token: types::api::GetToken::Connector,
// merchant_connector_id: None,
// }
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 41,
"total_crates": null
} |
fn_clm_router_get_auth_token_-6771071247463227708 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/elavon
// Implementation of ElavonTest for utils::Connector
fn get_auth_token(&self) -> types::ConnectorAuthType {
utils::to_connector_auth_type(
connector_auth::ConnectorAuthentication::new()
.elavon
.expect("Missing connector authentication configuration")
.into(),
)
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 32,
"total_crates": null
} |
fn_clm_router_get_default_payment_info_6364676597674539356 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/taxjar
fn get_default_payment_info() -> Option<utils::PaymentInfo> {
None
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 7278,
"total_crates": null
} |
fn_clm_router_payment_method_details_6364676597674539356 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/taxjar
fn payment_method_details() -> Option<types::PaymentsAuthorizeData> {
None
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 4398,
"total_crates": null
} |
fn_clm_router_get_name_6364676597674539356 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/taxjar
// Implementation of TaxjarTest for utils::Connector
fn get_name(&self) -> String {
"taxjar".to_string()
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 46,
"total_crates": null
} |
fn_clm_router_get_data_6364676597674539356 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/taxjar
// Implementation of TaxjarTest for utils::Connector
fn get_data(&self) -> api::ConnectorData {
use router::connector::Taxjar;
utils::construct_connector_data_old(
Box::new(Taxjar::new()),
types::Connector::Adyen,
api::GetToken::Connector,
None,
)
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 41,
"total_crates": null
} |
fn_clm_router_get_auth_token_6364676597674539356 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/taxjar
// Implementation of TaxjarTest for utils::Connector
fn get_auth_token(&self) -> types::ConnectorAuthType {
utils::to_connector_auth_type(
connector_auth::ConnectorAuthentication::new()
.taxjar
.expect("Missing connector authentication configuration")
.into(),
)
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 32,
"total_crates": null
} |
fn_clm_router_get_payment_method_data_2323805215771362225 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/authorizedotnet
fn get_payment_method_data() -> domain::Card {
domain::Card {
card_number: cards::CardNumber::from_str("5424000000000015").unwrap(),
card_exp_month: Secret::new("02".to_string()),
card_exp_year: Secret::new("2035".to_string()),
card_cvc: Secret::new("123".to_string()),
..Default::default()
}
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 100,
"total_crates": null
} |
fn_clm_router_get_name_2323805215771362225 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/authorizedotnet
// Implementation of AuthorizedotnetTest for utils::Connector
fn get_name(&self) -> String {
"authorizedotnet".to_string()
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 46,
"total_crates": null
} |
fn_clm_router_get_data_2323805215771362225 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/authorizedotnet
// Implementation of AuthorizedotnetTest for utils::Connector
fn get_data(&self) -> types::api::ConnectorData {
use router::connector::Authorizedotnet;
utils::construct_connector_data_old(
Box::new(Authorizedotnet::new()),
types::Connector::Authorizedotnet,
types::api::GetToken::Connector,
None,
)
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 41,
"total_crates": null
} |
fn_clm_router_should_capture_authorized_payment_2323805215771362225 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/authorizedotnet
async fn should_capture_authorized_payment() {
let authorize_response = CONNECTOR
.authorize_payment(
Some(types::PaymentsAuthorizeData {
amount: 301,
payment_method_data: domain::PaymentMethodData::Card(get_payment_method_data()),
capture_method: Some(diesel_models::enums::CaptureMethod::Manual),
..utils::PaymentAuthorizeType::default().0
}),
Some(PaymentInfo::with_default_billing_name()),
)
.await
.expect("Authorize payment response");
assert_eq!(authorize_response.status, enums::AttemptStatus::Pending);
let txn_id =
utils::get_connector_transaction_id(authorize_response.response).unwrap_or_default();
let psync_response = CONNECTOR
.psync_retry_till_status_matches(
enums::AttemptStatus::Authorized,
Some(types::PaymentsSyncData {
connector_transaction_id: types::ResponseId::ConnectorTransactionId(txn_id.clone()),
encoded_data: None,
capture_method: None,
..Default::default()
}),
None,
)
.await
.expect("PSync response");
assert_eq!(psync_response.status, enums::AttemptStatus::Authorized);
let cap_response = CONNECTOR
.capture_payment(
txn_id.clone(),
Some(types::PaymentsCaptureData {
amount_to_capture: 301,
..utils::PaymentCaptureType::default().0
}),
None,
)
.await
.expect("Capture payment response");
assert_eq!(cap_response.status, enums::AttemptStatus::Pending);
let response = CONNECTOR
.psync_retry_till_status_matches(
enums::AttemptStatus::CaptureInitiated,
Some(types::PaymentsSyncData {
connector_transaction_id: types::ResponseId::ConnectorTransactionId(txn_id),
encoded_data: None,
capture_method: None,
..Default::default()
}),
None,
)
.await
.expect("PSync response");
assert_eq!(response.status, enums::AttemptStatus::CaptureInitiated);
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 34,
"total_crates": null
} |
fn_clm_router_should_partially_capture_authorized_payment_2323805215771362225 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/authorizedotnet
async fn should_partially_capture_authorized_payment() {
let authorize_response = CONNECTOR
.authorize_payment(
Some(types::PaymentsAuthorizeData {
amount: 302,
payment_method_data: domain::PaymentMethodData::Card(get_payment_method_data()),
capture_method: Some(diesel_models::enums::CaptureMethod::Manual),
..utils::PaymentAuthorizeType::default().0
}),
Some(PaymentInfo::with_default_billing_name()),
)
.await
.expect("Authorize payment response");
assert_eq!(authorize_response.status, enums::AttemptStatus::Pending);
let txn_id =
utils::get_connector_transaction_id(authorize_response.response).unwrap_or_default();
let psync_response = CONNECTOR
.psync_retry_till_status_matches(
enums::AttemptStatus::Authorized,
Some(types::PaymentsSyncData {
connector_transaction_id: types::ResponseId::ConnectorTransactionId(txn_id.clone()),
encoded_data: None,
capture_method: None,
..Default::default()
}),
None,
)
.await
.expect("PSync response");
assert_eq!(psync_response.status, enums::AttemptStatus::Authorized);
let cap_response = CONNECTOR
.capture_payment(
txn_id.clone(),
Some(types::PaymentsCaptureData {
amount_to_capture: 150,
..utils::PaymentCaptureType::default().0
}),
None,
)
.await
.expect("Capture payment response");
assert_eq!(cap_response.status, enums::AttemptStatus::Pending);
let response = CONNECTOR
.psync_retry_till_status_matches(
enums::AttemptStatus::CaptureInitiated,
Some(types::PaymentsSyncData {
connector_transaction_id: types::ResponseId::ConnectorTransactionId(txn_id),
encoded_data: None,
capture_method: None,
..Default::default()
}),
None,
)
.await
.expect("PSync response");
assert_eq!(response.status, enums::AttemptStatus::CaptureInitiated);
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 34,
"total_crates": null
} |
fn_clm_router_get_payment_info_2525192978105779649 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/payeezy
// Inherent implementation for PayeezyTest
fn get_payment_info() -> Option<PaymentInfo> {
Some(PaymentInfo {
address: Some(types::PaymentAddress::new(
None,
Some(Address {
address: Some(AddressDetails {
..Default::default()
}),
phone: None,
email: None,
}),
None,
None,
)),
..Default::default()
})
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 341,
"total_crates": null
} |
fn_clm_router_get_payment_data_2525192978105779649 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/payeezy
// Inherent implementation for PayeezyTest
fn get_payment_data() -> Option<PaymentsAuthorizeData> {
Some(PaymentsAuthorizeData {
payment_method_data: types::domain::PaymentMethodData::Card(types::domain::Card {
card_number: CardNumber::from_str("4012000033330026").unwrap(),
..utils::CCardType::default().0
}),
..utils::PaymentAuthorizeType::default().0
})
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 172,
"total_crates": null
} |
fn_clm_router_get_name_2525192978105779649 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/payeezy
// Implementation of PayeezyTest for utils::Connector
fn get_name(&self) -> String {
"payeezy".to_string()
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 46,
"total_crates": null
} |
fn_clm_router_get_request_interval_2525192978105779649 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/payeezy
// Inherent implementation for PayeezyTest
fn get_request_interval(self) -> u64 {
20
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 41,
"total_crates": null
} |
fn_clm_router_get_data_2525192978105779649 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/payeezy
// Implementation of PayeezyTest for utils::Connector
fn get_data(&self) -> types::api::ConnectorData {
use router::connector::Payeezy;
utils::construct_connector_data_old(
Box::new(&Payeezy),
// Remove `dummy_connector` feature gate from module in `main.rs` when updating this to use actual connector variant
types::Connector::DummyConnector1,
types::api::GetToken::Connector,
None,
)
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 39,
"total_crates": null
} |
fn_clm_router_get_default_payment_info_-5524788897710998776 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/iatapay
fn get_default_payment_info() -> Option<utils::PaymentInfo> {
Some(utils::PaymentInfo {
address: Some(types::PaymentAddress::new(
None,
Some(Address {
address: Some(AddressDetails {
first_name: Some(Secret::new("first".to_string())),
last_name: Some(Secret::new("last".to_string())),
line1: Some(Secret::new("line1".to_string())),
line2: Some(Secret::new("line2".to_string())),
city: Some("city".to_string()),
zip: Some(Secret::new("zip".to_string())),
country: Some(api_models::enums::CountryAlpha2::NL),
..Default::default()
}),
phone: Some(PhoneDetails {
number: Some(Secret::new("9123456789".to_string())),
country_code: Some("+91".to_string()),
}),
email: None,
}),
None,
None,
)),
access_token: get_access_token(),
..Default::default()
})
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 7314,
"total_crates": null
} |
fn_clm_router_payment_method_details_-5524788897710998776 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/iatapay
fn payment_method_details() -> Option<types::PaymentsAuthorizeData> {
Some(types::PaymentsAuthorizeData {
router_return_url: Some("https://hyperswitch.io".to_string()),
webhook_url: Some("https://hyperswitch.io".to_string()),
currency: enums::Currency::EUR,
..PaymentAuthorizeType::default().0
})
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 4404,
"total_crates": null
} |
fn_clm_router_get_name_-5524788897710998776 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/iatapay
// Implementation of IatapayTest for Connector
fn get_name(&self) -> String {
"iatapay".to_string()
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 46,
"total_crates": null
} |
fn_clm_router_get_data_-5524788897710998776 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/iatapay
// Implementation of IatapayTest for Connector
fn get_data(&self) -> api::ConnectorData {
use router::connector::Iatapay;
utils::construct_connector_data_old(
Box::new(Iatapay::new()),
types::Connector::Iatapay,
api::GetToken::Connector,
None,
)
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 41,
"total_crates": null
} |
fn_clm_router_get_access_token_-5524788897710998776 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/iatapay
fn get_access_token() -> Option<AccessToken> {
let connector = IatapayTest {};
match connector.get_auth_token() {
types::ConnectorAuthType::SignatureKey {
api_key,
key1: _,
api_secret: _,
} => Some(AccessToken {
token: api_key,
expires: 60 * 5,
}),
_ => None,
}
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 35,
"total_crates": null
} |
fn_clm_router_get_default_payment_info_-8967411656807679707 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/fiservemea
fn get_default_payment_info() -> Option<utils::PaymentInfo> {
None
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 7278,
"total_crates": null
} |
fn_clm_router_payment_method_details_-8967411656807679707 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/fiservemea
fn payment_method_details() -> Option<types::PaymentsAuthorizeData> {
None
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 4398,
"total_crates": null
} |
fn_clm_router_get_name_-8967411656807679707 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/fiservemea
// Implementation of FiservemeaTest for utils::Connector
fn get_name(&self) -> String {
"fiservemea".to_string()
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 46,
"total_crates": null
} |
fn_clm_router_get_data_-8967411656807679707 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/fiservemea
// Implementation of FiservemeaTest for utils::Connector
fn get_data(&self) -> api::ConnectorData {
use router::connector::Fiservemea;
utils::construct_connector_data_old(
Box::new(Fiservemea::new()),
types::Connector::Plaid,
api::GetToken::Connector,
None,
)
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 41,
"total_crates": null
} |
fn_clm_router_get_auth_token_-8967411656807679707 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/fiservemea
// Implementation of FiservemeaTest for utils::Connector
fn get_auth_token(&self) -> types::ConnectorAuthType {
utils::to_connector_auth_type(
connector_auth::ConnectorAuthentication::new()
.fiservemea
.expect("Missing connector authentication configuration")
.into(),
)
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 32,
"total_crates": null
} |
fn_clm_router_get_payout_info_3076075426692572584 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/wise
// Inherent implementation for WiseTest
fn get_payout_info() -> Option<PaymentInfo> {
Some(PaymentInfo {
currency: Some(enums::Currency::GBP),
address: Some(PaymentAddress::new(
None,
Some(Address {
address: Some(AddressDetails {
country: Some(api_models::enums::CountryAlpha2::GB),
city: Some("London".to_string()),
zip: Some(Secret::new("10025".to_string())),
line1: Some(Secret::new("50 Branson Ave".to_string())),
..Default::default()
}),
phone: None,
email: None,
}),
None,
None,
)),
payout_method_data: Some(api::PayoutMethodData::Bank(api::payouts::BankPayout::Bacs(
api::BacsBankTransfer {
bank_sort_code: "231470".to_string().into(),
bank_account_number: "28821822".to_string().into(),
bank_name: Some("Deutsche Bank".to_string()),
bank_country_code: Some(enums::CountryAlpha2::NL),
bank_city: Some("Amsterdam".to_string()),
},
))),
..Default::default()
})
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 73,
"total_crates": null
} |
fn_clm_router_get_name_3076075426692572584 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/wise
// Implementation of WiseTest for utils::Connector
fn get_name(&self) -> String {
"wise".to_string()
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 46,
"total_crates": null
} |
fn_clm_router_get_data_3076075426692572584 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/wise
// Implementation of WiseTest for utils::Connector
fn get_data(&self) -> api::ConnectorData {
use router::connector::Adyen;
utils::construct_connector_data_old(
Box::new(Adyen::new()),
types::Connector::Adyen,
api::GetToken::Connector,
None,
)
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 41,
"total_crates": null
} |
fn_clm_router_get_auth_token_3076075426692572584 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/wise
// Implementation of WiseTest for utils::Connector
fn get_auth_token(&self) -> types::ConnectorAuthType {
utils::to_connector_auth_type(
connector_auth::ConnectorAuthentication::new()
.wise
.expect("Missing connector authentication configuration")
.into(),
)
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 32,
"total_crates": null
} |
fn_clm_router_get_payout_data_3076075426692572584 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/wise
// Implementation of WiseTest for utils::Connector
fn get_payout_data(&self) -> Option<api::ConnectorData> {
use router::connector::Wise;
Some(utils::construct_connector_data_old(
Box::new(Wise::new()),
types::Connector::Wise,
api::GetToken::Connector,
None,
))
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 29,
"total_crates": null
} |
fn_clm_router_get_default_payment_info_7342236871021814689 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/payload
fn get_default_payment_info() -> Option<utils::PaymentInfo> {
None
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 7278,
"total_crates": null
} |
fn_clm_router_payment_method_details_7342236871021814689 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/payload
fn payment_method_details() -> Option<types::PaymentsAuthorizeData> {
None
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 4398,
"total_crates": null
} |
fn_clm_router_get_name_7342236871021814689 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/payload
// Implementation of PayloadTest for utils::Connector
fn get_name(&self) -> String {
"payload".to_string()
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 46,
"total_crates": null
} |
fn_clm_router_get_data_7342236871021814689 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/payload
// Implementation of PayloadTest for utils::Connector
fn get_data(&self) -> api::ConnectorData {
use router::connector::Payload;
utils::construct_connector_data_old(
Box::new(Payload::new()),
types::Connector::DummyConnector1,
api::GetToken::Connector,
None,
)
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 41,
"total_crates": null
} |
fn_clm_router_get_auth_token_7342236871021814689 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/payload
// Implementation of PayloadTest for utils::Connector
fn get_auth_token(&self) -> types::ConnectorAuthType {
utils::to_connector_auth_type(
connector_auth::ConnectorAuthentication::new()
.payload
.expect("Missing connector authentication configuration")
.into(),
)
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 32,
"total_crates": null
} |
fn_clm_router_get_default_payment_info_1566165419572365968 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/mpgs
fn get_default_payment_info() -> Option<utils::PaymentInfo> {
None
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 7278,
"total_crates": null
} |
fn_clm_router_payment_method_details_1566165419572365968 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/mpgs
fn payment_method_details() -> Option<types::PaymentsAuthorizeData> {
None
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 4398,
"total_crates": null
} |
fn_clm_router_get_name_1566165419572365968 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/mpgs
// Implementation of MpgsTest for utils::Connector
fn get_name(&self) -> String {
"mpgs".to_string()
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 46,
"total_crates": null
} |
fn_clm_router_get_data_1566165419572365968 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/mpgs
// Implementation of MpgsTest for utils::Connector
fn get_data(&self) -> api::ConnectorData {
use router::connector::Mpgs;
utils::construct_connector_data_old(
Box::new(Mpgs::new()),
types::Connector::Plaid,
api::GetToken::Connector,
None,
)
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 41,
"total_crates": null
} |
fn_clm_router_get_auth_token_1566165419572365968 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/mpgs
// Implementation of MpgsTest for utils::Connector
fn get_auth_token(&self) -> types::ConnectorAuthType {
utils::to_connector_auth_type(
connector_auth::ConnectorAuthentication::new()
.mpgs
.expect("Missing connector authentication configuration")
.into(),
)
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 32,
"total_crates": null
} |
fn_clm_router_get_default_payment_info_9156026187172509434 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/trustpay
fn get_default_payment_info() -> Option<utils::PaymentInfo> {
Some(utils::PaymentInfo {
address: Some(types::PaymentAddress::new(
None,
Some(Address {
address: Some(AddressDetails {
first_name: Some(Secret::new("first".to_string())),
last_name: Some(Secret::new("last".to_string())),
line1: Some(Secret::new("line1".to_string())),
line2: Some(Secret::new("line2".to_string())),
city: Some("city".to_string()),
zip: Some(Secret::new("zip".to_string())),
country: Some(api_models::enums::CountryAlpha2::IN),
..Default::default()
}),
phone: None,
email: None,
}),
None,
None,
)),
..Default::default()
})
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 7306,
"total_crates": null
} |
fn_clm_router_get_default_payment_authorize_data_9156026187172509434 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/trustpay
fn get_default_payment_authorize_data() -> Option<types::PaymentsAuthorizeData> {
Some(types::PaymentsAuthorizeData {
payment_method_data: domain::PaymentMethodData::Card(domain::Card {
card_number: cards::CardNumber::from_str("4200000000000000").unwrap(),
card_exp_year: Secret::new("25".to_string()),
card_cvc: Secret::new("123".to_string()),
..utils::CCardType::default().0
}),
browser_info: Some(get_default_browser_info()),
router_return_url: Some(String::from("http://localhost:8080")),
..utils::PaymentAuthorizeType::default().0
})
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 119,
"total_crates": null
} |
fn_clm_router_get_name_9156026187172509434 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/trustpay
// Implementation of TrustpayTest for utils::Connector
fn get_name(&self) -> String {
"trustpay".to_string()
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 46,
"total_crates": null
} |
fn_clm_router_get_data_9156026187172509434 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/trustpay
// Implementation of TrustpayTest for utils::Connector
fn get_data(&self) -> api::ConnectorData {
use router::connector::Trustpay;
utils::construct_connector_data_old(
Box::new(Trustpay::new()),
types::Connector::Trustpay,
api::GetToken::Connector,
None,
)
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 41,
"total_crates": null
} |
fn_clm_router_get_auth_token_9156026187172509434 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/trustpay
// Implementation of TrustpayTest for utils::Connector
fn get_auth_token(&self) -> types::ConnectorAuthType {
utils::to_connector_auth_type(
connector_auth::ConnectorAuthentication::new()
.trustpay
.expect("Missing connector authentication configuration")
.into(),
)
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 32,
"total_crates": null
} |
fn_clm_router_get_default_payment_info_3669844161463872580 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/placetopay
fn get_default_payment_info() -> Option<utils::PaymentInfo> {
None
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 7278,
"total_crates": null
} |
fn_clm_router_payment_method_details_3669844161463872580 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/placetopay
fn payment_method_details() -> Option<types::PaymentsAuthorizeData> {
None
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 4398,
"total_crates": null
} |
fn_clm_router_get_name_3669844161463872580 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/placetopay
// Implementation of PlacetopayTest for utils::Connector
fn get_name(&self) -> String {
"placetopay".to_string()
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 46,
"total_crates": null
} |
fn_clm_router_get_data_3669844161463872580 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/placetopay
// Implementation of PlacetopayTest for utils::Connector
fn get_data(&self) -> types::api::ConnectorData {
use router::connector::Placetopay;
utils::construct_connector_data_old(
Box::new(Placetopay::new()),
types::Connector::Placetopay,
types::api::GetToken::Connector,
None,
)
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 41,
"total_crates": null
} |
fn_clm_router_get_auth_token_3669844161463872580 | clm | function | // Repository: hyperswitch
// Crate: router
// Purpose: Main application server handling HTTP requests, authentication, and business logic orchestration
// Module: crates/router/tests/connectors/placetopay
// Implementation of PlacetopayTest for utils::Connector
fn get_auth_token(&self) -> types::ConnectorAuthType {
utils::to_connector_auth_type(
connector_auth::ConnectorAuthentication::new()
.placetopay
.expect("Missing connector authentication configuration")
.into(),
)
}
| {
"crate": "router",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 32,
"total_crates": null
} |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.