id stringlengths 20 153 | type stringclasses 1
value | granularity stringclasses 14
values | content stringlengths 16 84.3k | metadata dict |
|---|---|---|---|---|
connector-service_fn_connector-integration_-2475670696279178684 | clm | function | // connector-service/backend/connector-integration/src/connectors/aci/transformers.rs
fn try_from(
item: AciRouterData<
RouterDataV2<RepeatPayment, PaymentFlowData, RepeatPaymentData, PaymentsResponseData>,
T,
>,
) -> Result<Self, Self::Error> {
let auth = AciAuthTyp... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "try_from",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "connector-servic... |
connector-service_fn_connector-integration_5868182820372981165 | clm | function | // connector-service/backend/connector-integration/src/connectors/aci/transformers.rs
fn get_aci_payment_brand(
card_network: Option<common_enums::CardNetwork>,
is_network_token_flow: bool,
) -> Result<PaymentBrand, Error> {
match card_network {
Some(common_enums::CardNetwork::Visa) => Ok(PaymentBr... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "get_aci_payment_brand",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "con... |
connector-service_fn_connector-integration_5993362075725529143 | clm | function | // connector-service/backend/connector-integration/src/connectors/aci/transformers.rs
fn get_transaction_details<
T: PaymentMethodDataTypes
+ std::fmt::Debug
+ std::marker::Sync
+ std::marker::Send
+ 'static
+ Serialize,
>(
item: &AciRouterData<
RouterDataV2<Auth... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "get_transaction_details",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "c... |
connector-service_fn_connector-integration_-6818782463916748221 | clm | function | // connector-service/backend/connector-integration/src/connectors/aci/transformers.rs
fn get_instruction_details<
T: PaymentMethodDataTypes
+ std::fmt::Debug
+ std::marker::Sync
+ std::marker::Send
+ 'static
+ Serialize,
>(
item: &AciRouterData<
RouterDataV2<Auth... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "get_instruction_details",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "c... |
connector-service_fn_connector-integration_-5309365021088424429 | clm | function | // connector-service/backend/connector-integration/src/connectors/aci/transformers.rs
fn get_recurring_type<
T: PaymentMethodDataTypes
+ std::fmt::Debug
+ std::marker::Sync
+ std::marker::Send
+ 'static
+ Serialize,
>(
item: &AciRouterData<
RouterDataV2<Authorize... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "get_recurring_type",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "connec... |
connector-service_fn_connector-integration_-6266609253027953232 | clm | function | // connector-service/backend/connector-integration/src/connectors/aci/transformers.rs
fn map_aci_attempt_status(
item: AciPaymentStatus,
auto_capture: bool,
) -> common_enums::AttemptStatus {
match item {
AciPaymentStatus::Succeeded => {
if auto_capture {
common_enums::A... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "map_aci_attempt_status",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "co... |
connector-service_fn_connector-integration_-2349756336930730154 | clm | function | // connector-service/backend/connector-integration/src/connectors/aci/transformers.rs
fn from_str(s: &str) -> Result<Self, Self::Err> {
if FAILURE_CODES.contains(&s) {
Ok(Self::Failed)
} else if PENDING_CODES.contains(&s) {
Ok(Self::Pending)
} else if SUCCESSFUL_CODES.co... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "from_str",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "connector-servic... |
connector-service_fn_connector-integration_-324582186595130169 | clm | function | // connector-service/backend/connector-integration/src/connectors/aci/transformers.rs
fn map_aci_capture_status(item: AciStatus) -> common_enums::AttemptStatus {
match item {
AciStatus::Succeeded => common_enums::AttemptStatus::Charged,
AciStatus::Failed => common_enums::AttemptStatus::Failure,
... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "map_aci_capture_status",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "co... |
connector-service_fn_connector-integration_4759838529303483321 | clm | function | // connector-service/backend/connector-integration/src/connectors/aci/transformers.rs
fn map_aci_void_status(item: AciStatus) -> common_enums::AttemptStatus {
match item {
AciStatus::Succeeded => common_enums::AttemptStatus::Voided,
AciStatus::Failed => common_enums::AttemptStatus::VoidFailed,
... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "map_aci_void_status",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "conne... |
connector-service_fn_connector-integration_5967455669209128865 | clm | function | // connector-service/backend/connector-integration/src/connectors/aci/transformers.rs
fn from(item: AciRefundStatus) -> Self {
match item {
AciRefundStatus::Succeeded => Self::Success,
AciRefundStatus::Failed => Self::Failure,
AciRefundStatus::Pending => Self::Pending,
... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "from",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "connector-service",
... |
connector-service_fn_connector-integration_6772711868557895414 | clm | function | // connector-service/backend/connector-integration/src/connectors/fiserv/transformers.rs
fn get_card_expiry_year_4_digit_placeholder(
year_yy: &Secret<String>,
) -> Result<Secret<String>, error_stack::Report<ConnectorError>> {
let year_str = year_yy.peek();
if year_str.len() == 2 && year_str.chars().all(ch... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "get_card_expiry_year_4_digit_placeholder",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": n... |
connector-service_fn_connector-integration_2816155212846388580 | clm | function | // connector-service/backend/connector-integration/src/connectors/fiserv/transformers.rs
fn try_from(item: ResponseRouterData<FiservErrorResponse, Self>) -> Result<Self, Self::Error> {
let ResponseRouterData {
response,
router_data,
http_code,
} = item;
let ... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "try_from",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "connector-servic... |
connector-service_fn_connector-integration_4136552758440614962 | clm | function | // connector-service/backend/connector-integration/src/connectors/fiserv/transformers.rs
fn from(item: FiservPaymentStatus) -> Self {
match item {
FiservPaymentStatus::Captured
| FiservPaymentStatus::Succeeded
| FiservPaymentStatus::Authorized => Self::Success,
F... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "from",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "connector-service",
... |
connector-service_fn_connector-integration_-3758289943798318162 | clm | function | // connector-service/backend/connector-integration/src/connectors/checkout/transformers.rs
fn to_connector_meta(
connector_meta: Option<serde_json::Value>,
) -> CustomResult<CheckoutMeta, ConnectorError> {
connector_meta
.map(|meta| {
serde_json::from_value::<CheckoutMeta>(meta)
... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "to_connector_meta",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "connect... |
connector-service_fn_connector-integration_-6306299953775902384 | clm | function | // connector-service/backend/connector-integration/src/connectors/checkout/transformers.rs
fn get_connector_meta(
capture_method: enums::CaptureMethod,
) -> CustomResult<serde_json::Value, ConnectorError> {
match capture_method {
enums::CaptureMethod::Automatic | enums::CaptureMethod::SequentialAutomat... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "get_connector_meta",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "connec... |
connector-service_fn_connector-integration_4376085001000379583 | clm | function | // connector-service/backend/connector-integration/src/connectors/checkout/transformers.rs
fn from(status: CheckoutPaymentStatus) -> Self {
get_attempt_status_bal((status, None))
}
| {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "from",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "connector-service",
... |
connector-service_fn_connector-integration_5289544423721072476 | clm | function | // connector-service/backend/connector-integration/src/connectors/checkout/transformers.rs
fn get_attempt_status_cap(
item: (CheckoutPaymentStatus, Option<enums::CaptureMethod>),
) -> enums::AttemptStatus {
let (status, capture_method) = item;
match status {
CheckoutPaymentStatus::Authorized => {
... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "get_attempt_status_cap",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "co... |
connector-service_fn_connector-integration_5008216598957983708 | clm | function | // connector-service/backend/connector-integration/src/connectors/checkout/transformers.rs
fn get_attempt_status_intent(
item: (CheckoutPaymentStatus, CheckoutPaymentIntent),
) -> enums::AttemptStatus {
let (status, psync_flow) = item;
match status {
CheckoutPaymentStatus::Authorized => {
... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "get_attempt_status_intent",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": ... |
connector-service_fn_connector-integration_5133014760509552792 | clm | function | // connector-service/backend/connector-integration/src/connectors/checkout/transformers.rs
fn get_attempt_status_bal(item: (CheckoutPaymentStatus, Option<Balances>)) -> enums::AttemptStatus {
let (status, balances) = item;
match status {
CheckoutPaymentStatus::Authorized => {
if let Some(B... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "get_attempt_status_bal",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "co... |
connector-service_fn_connector-integration_-3841855297523034765 | clm | function | // connector-service/backend/connector-integration/src/connectors/checkout/transformers.rs
fn try_from(
item: ResponseRouterData<
&ActionResponse,
RouterDataV2<F, RefundFlowData, RefundSyncData, RefundsResponseData>,
>,
) -> Result<Self, Self::Error> {
let ResponseRo... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "try_from",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "connector-servic... |
connector-service_fn_connector-integration_-2434093513669160601 | clm | function | // connector-service/backend/connector-integration/src/connectors/cashtocode/transformers.rs
fn get_mid(
connector_auth_type: &ConnectorAuthType,
payment_method_type: Option<common_enums::PaymentMethodType>,
currency: common_enums::Currency,
) -> Result<Secret<String>, errors::ConnectorError> {
match C... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "get_mid",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "connector-service... |
connector-service_fn_connector-integration_1867878338672038562 | clm | function | // connector-service/backend/connector-integration/src/connectors/cashtocode/transformers.rs
fn try_from(
item: ResponseRouterData<CashtocodePaymentsResponse, Self>,
) -> Result<Self, Self::Error> {
let ResponseRouterData {
response,
router_data,
http_code,
... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "try_from",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "connector-servic... |
connector-service_fn_connector-integration_-5154119684211301797 | clm | function | // connector-service/backend/connector-integration/src/connectors/cashtocode/transformers.rs
fn from(item: CashtocodePaymentStatus) -> Self {
match item {
CashtocodePaymentStatus::Succeeded => Self::Charged,
CashtocodePaymentStatus::Processing => Self::AuthenticationPending,
}
... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "from",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "connector-service",
... |
connector-service_fn_connector-integration_6883614331911483996 | clm | function | // connector-service/backend/connector-integration/src/connectors/cashtocode/transformers.rs
fn get_redirect_form_data(
payment_method_type: common_enums::PaymentMethodType,
response_data: CashtocodePaymentsResponseData,
) -> CustomResult<RedirectForm, errors::ConnectorError> {
match payment_method_type {
... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "get_redirect_form_data",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "co... |
connector-service_fn_connector-integration_8339934356743527216 | clm | function | // connector-service/backend/connector-integration/src/connectors/cybersource/transformers.rs
fn card_issuer_to_string(card_issuer: CardIssuer) -> String {
let card_type = match card_issuer {
CardIssuer::AmericanExpress => "003",
CardIssuer::Master => "002",
//"042" is the type code for Mas... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "card_issuer_to_string",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "con... |
connector-service_fn_connector-integration_7619619377881359831 | clm | function | // connector-service/backend/connector-integration/src/connectors/cybersource/transformers.rs
fn try_from(
(item, solution, network): (
&CybersourceRouterData<
RouterDataV2<
RepeatPayment,
PaymentFlowData,
RepeatPaymentData... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "try_from",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "connector-servic... |
connector-service_fn_connector-integration_-4165971609938476048 | clm | function | // connector-service/backend/connector-integration/src/connectors/cybersource/transformers.rs
fn from(item: CybersourceRefundStatus) -> Self {
match item {
CybersourceRefundStatus::Succeeded | CybersourceRefundStatus::Transmitted => {
Self::Success
}
Cybersou... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "from",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "connector-service",
... |
connector-service_fn_connector-integration_-8019715245686394547 | clm | function | // connector-service/backend/connector-integration/src/connectors/cybersource/transformers.rs
fn get_authentication_data_for_check_enrollment_response(
response: CybersourceConsumerAuthInformationEnrollmentResponse,
) -> router_request_types::AuthenticationData {
let trans_status = response
.validate_r... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "get_authentication_data_for_check_enrollment_response",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"nu... |
connector-service_fn_connector-integration_305558305954841632 | clm | function | // connector-service/backend/connector-integration/src/connectors/cybersource/transformers.rs
fn get_authentication_data_for_validation_response(
response: CybersourceConsumerAuthInformationEnrollmentResponse,
) -> router_request_types::AuthenticationData {
let trans_status = response
.validate_respons... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "get_authentication_data_for_validation_response",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_stru... |
connector-service_fn_connector-integration_7498401018909472574 | clm | function | // connector-service/backend/connector-integration/src/connectors/cybersource/transformers.rs
fn truncate_string(state: &Secret<String>, max_len: usize) -> Secret<String> {
let exposed = state.clone().expose();
let truncated = exposed.get(..max_len).unwrap_or(&exposed);
Secret::new(truncated.to_string())
}... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "truncate_string",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "connector... |
connector-service_fn_connector-integration_8046806024228547471 | clm | function | // connector-service/backend/connector-integration/src/connectors/cybersource/transformers.rs
fn build_bill_to(
address_details: Option<&Address>,
email: pii::Email,
) -> Result<BillTo, error_stack::Report<errors::ConnectorError>> {
let default_address = BillTo {
first_name: None,
last_name... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "build_bill_to",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "connector-s... |
connector-service_fn_connector-integration_-8939643827257498663 | clm | function | // connector-service/backend/connector-integration/src/connectors/cybersource/transformers.rs
fn convert_metadata_to_merchant_defined_info(metadata: Value) -> Vec<MerchantDefinedInformation> {
let hashmap: std::collections::BTreeMap<String, Value> =
serde_json::from_str(&metadata.to_string()).unwrap_or(std... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "convert_metadata_to_merchant_defined_info",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": ... |
connector-service_fn_connector-integration_-8248328403727091815 | clm | function | // connector-service/backend/connector-integration/src/connectors/cybersource/transformers.rs
fn get_samsung_pay_payment_information<
T: PaymentMethodDataTypes
+ std::fmt::Debug
+ std::marker::Sync
+ std::marker::Send
+ 'static
+ Serialize,
>(
samsung_pay_data: &payment_... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "get_samsung_pay_payment_information",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
... |
connector-service_fn_connector-integration_5532048770562631172 | clm | function | // connector-service/backend/connector-integration/src/connectors/cybersource/transformers.rs
fn get_samsung_pay_fluid_data_value(
samsung_pay_token_data: &payment_method_data::SamsungPayTokenData,
) -> Result<SamsungPayFluidDataValue, error_stack::Report<errors::ConnectorError>> {
let samsung_pay_header = jwt... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "get_samsung_pay_fluid_data_value",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"... |
connector-service_fn_connector-integration_8082865412243660934 | clm | function | // connector-service/backend/connector-integration/src/connectors/cybersource/transformers.rs
pub fn map_cybersource_attempt_status(
status: CybersourcePaymentStatus,
capture: bool,
) -> common_enums::AttemptStatus {
match status {
CybersourcePaymentStatus::Authorized => {
if capture {
... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "map_cybersource_attempt_status",
"is_async": false,
"is_pub": true,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"rep... |
connector-service_fn_connector-integration_-4136628398086485022 | clm | function | // connector-service/backend/connector-integration/src/connectors/cybersource/transformers.rs
fn get_error_response_if_failure(
(info_response, status, http_code): (
&CybersourcePaymentsResponse,
common_enums::AttemptStatus,
u16,
),
) -> Option<ErrorResponse> {
if domain_types::util... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "get_error_response_if_failure",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"rep... |
connector-service_fn_connector-integration_-2599135435502679244 | clm | function | // connector-service/backend/connector-integration/src/connectors/cybersource/transformers.rs
fn get_payment_response(
(info_response, status, http_code): (
&CybersourcePaymentsResponse,
common_enums::AttemptStatus,
u16,
),
) -> Result<PaymentsResponseData, Box<ErrorResponse>> {
let... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "get_payment_response",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "conn... |
connector-service_fn_connector-integration_-1078727645221439739 | clm | function | // connector-service/backend/connector-integration/src/connectors/cybersource/transformers.rs
pub fn get_error_response(
error_data: &Option<CybersourceErrorInformation>,
processor_information: &Option<ClientProcessorInformation>,
risk_information: &Option<ClientRiskInformation>,
attempt_status: Option... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "get_error_response",
"is_async": false,
"is_pub": true,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "connect... |
connector-service_fn_connector-integration_-439592443807537185 | clm | function | // connector-service/backend/connector-integration/src/connectors/cybersource/transformers.rs
pub fn get_error_reason(
error_info: Option<String>,
detailed_error_info: Option<String>,
avs_error_info: Option<String>,
) -> Option<String> {
match (error_info, detailed_error_info, avs_error_info) {
... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "get_error_reason",
"is_async": false,
"is_pub": true,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "connector... |
connector-service_fn_connector-integration_7012713584769309075 | clm | function | // connector-service/backend/connector-integration/src/connectors/cybersource/transformers.rs
fn get_cybersource_card_type(card_network: common_enums::CardNetwork) -> Option<&'static str> {
match card_network {
common_enums::CardNetwork::Visa => Some("001"),
common_enums::CardNetwork::Mastercard =>... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "get_cybersource_card_type",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": ... |
connector-service_fn_connector-integration_-4004266570812326990 | clm | function | // connector-service/backend/connector-integration/src/connectors/cybersource/transformers.rs
fn remove_new_line(&self) -> Self {
self.clone().map(|value| value.replace("\n", " "))
}
| {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "remove_new_line",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "connector... |
connector-service_fn_connector-integration_-445441321632269646 | clm | function | // connector-service/backend/connector-integration/src/connectors/cryptopay/transformers.rs
fn try_from(notif: CryptopayWebhookDetails) -> Result<Self, Self::Error> {
let status = common_enums::AttemptStatus::from(notif.data.status.clone());
if is_payment_failure(status) {
Ok(Self {
... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "try_from",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "connector-servic... |
connector-service_fn_connector-integration_-5655207447427497326 | clm | function | // connector-service/backend/connector-integration/src/connectors/cryptopay/transformers.rs
fn from(item: CryptopayPaymentStatus) -> Self {
match item {
CryptopayPaymentStatus::New => Self::AuthenticationPending,
CryptopayPaymentStatus::Completed => Self::Charged,
CryptopayP... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "from",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "connector-service",
... |
connector-service_fn_connector-integration_6584227525461909224 | clm | function | // connector-service/backend/connector-integration/src/connectors/razorpayv2/test.rs
fn test_upi_flow_determination() {
// Add tests for UPI flow determination logic
// TODO: Implement comprehensive tests
}
| {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "test_upi_flow_determination",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo"... |
connector-service_fn_connector-integration_1558662536331175589 | clm | function | // connector-service/backend/connector-integration/src/connectors/razorpayv2/test.rs
fn test_create_order_request_building() {
// Add tests for create order request building
// TODO: Implement comprehensive tests
}
| {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "test_create_order_request_building",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
... |
connector-service_fn_connector-integration_7335008701231297933 | clm | function | // connector-service/backend/connector-integration/src/connectors/razorpayv2/test.rs
fn test_payments_request_building() {
// Add tests for payments request building
// TODO: Implement comprehensive tests
}
| {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "test_payments_request_building",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"re... |
connector-service_fn_connector-integration_1676547017282257746 | clm | function | // connector-service/backend/connector-integration/src/connectors/razorpayv2/transformers.rs
pub fn generate_authorization_header(&self) -> String {
match self {
RazorpayV2AuthType::AuthToken(token) => format!("Bearer {}", token.peek()),
RazorpayV2AuthType::ApiKeySecret {
... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "generate_authorization_header",
"is_async": false,
"is_pub": true,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo... |
connector-service_fn_connector-integration_-4026817227612703553 | clm | function | // connector-service/backend/connector-integration/src/connectors/razorpayv2/transformers.rs
fn try_from(item: &RazorpayV2RouterData<&RefundsData, U>) -> Result<Self, Self::Error> {
let amount_in_minor_units = item.amount.get_amount_as_i64();
Ok(Self {
amount: amount_in_minor_units,
... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "try_from",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "connector-servic... |
connector-service_fn_connector-integration_593002213147923887 | clm | function | // connector-service/backend/connector-integration/src/connectors/razorpayv2/transformers.rs
fn get_psync_razorpay_payment_status(razorpay_status: RazorpayStatus) -> AttemptStatus {
match razorpay_status {
RazorpayStatus::Created => AttemptStatus::Pending,
RazorpayStatus::Authorized => AttemptStatu... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "get_psync_razorpay_payment_status",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
... |
connector-service_fn_connector-integration_-2965787975485232033 | clm | function | // connector-service/backend/connector-integration/src/connectors/razorpayv2/transformers.rs
fn foreign_try_from(
(response, data, _status_code, __raw_response): (
RazorpayV2PaymentsResponse,
RouterDataV2<
Authorize,
PaymentFlowData,
Payme... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "foreign_try_from",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "connecto... |
connector-service_fn_connector-integration_-1285128844360666749 | clm | function | // connector-service/backend/connector-integration/src/connectors/trustpay/transformers.rs
fn try_from(
item: ResponseRouterData<
TrustpayAuthUpdateResponse,
RouterDataV2<
CreateAccessToken,
PaymentFlowData,
AccessTokenRequestData,
... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "try_from",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "connector-servic... |
connector-service_fn_connector-integration_7812994628977182480 | clm | function | // connector-service/backend/connector-integration/src/connectors/trustpay/transformers.rs
pub fn error_message(&self) -> &'static str {
match self {
Self::EmptyCvvNotAllowed => "Empty CVV for VISA, MASTER not allowed",
Self::SessionRejected => "Referenced session is rejected (no action... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "error_message",
"is_async": false,
"is_pub": true,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "connector-se... |
connector-service_fn_connector-integration_6693742641953233707 | clm | function | // connector-service/backend/connector-integration/src/connectors/trustpay/transformers.rs
pub fn is_failure(&self) -> bool {
!matches!(self, Self::Unknown)
}
| {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "is_failure",
"is_async": false,
"is_pub": true,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "connector-servi... |
connector-service_fn_connector-integration_1583704845102738579 | clm | function | // connector-service/backend/connector-integration/src/connectors/trustpay/transformers.rs
fn from(item: TrustpayBankRedirectPaymentStatus) -> Self {
match item {
TrustpayBankRedirectPaymentStatus::Paid => Self::Success,
TrustpayBankRedirectPaymentStatus::Rejected => Self::Failure,
... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "from",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "connector-service",
... |
connector-service_fn_connector-integration_-5912870118739466683 | clm | function | // connector-service/backend/connector-integration/src/connectors/trustpay/transformers.rs
fn is_payment_failed(payment_status: &str) -> (bool, &'static str) {
let status_code = TrustpayPaymentStatusCode::from(payment_status);
(status_code.is_failure(), status_code.error_message())
}
| {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "is_payment_failed",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "connect... |
connector-service_fn_connector-integration_6622341884730005451 | clm | function | // connector-service/backend/connector-integration/src/connectors/trustpay/transformers.rs
fn is_payment_successful(payment_status: &str) -> CustomResult<bool, errors::ConnectorError> {
match payment_status {
"000.400.100" => Ok(true),
_ => {
let allowed_prefixes = [
"00... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "is_payment_successful",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "con... |
connector-service_fn_connector-integration_2952569615443560748 | clm | function | // connector-service/backend/connector-integration/src/connectors/trustpay/transformers.rs
fn get_pending_status_based_on_redirect_url(redirect_url: Option<Url>) -> enums::AttemptStatus {
match redirect_url {
Some(_url) => enums::AttemptStatus::AuthenticationPending,
None => enums::AttemptStatus::P... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "get_pending_status_based_on_redirect_url",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": n... |
connector-service_fn_connector-integration_-5915264256727995919 | clm | function | // connector-service/backend/connector-integration/src/connectors/trustpay/transformers.rs
fn get_transaction_status(
payment_status: Option<String>,
redirect_url: Option<Url>,
) -> CustomResult<(enums::AttemptStatus, Option<String>), errors::ConnectorError> {
// We don't get payment_status only in case, w... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "get_transaction_status",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "co... |
connector-service_fn_connector-integration_1583055968923952888 | clm | function | // connector-service/backend/connector-integration/src/connectors/trustpay/transformers.rs
fn handle_cards_response(
response: PaymentsResponseCards,
status_code: u16,
) -> CustomResult<
(
enums::AttemptStatus,
Option<ErrorResponse>,
PaymentsResponseData,
),
errors::Connecto... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "handle_cards_response",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "con... |
connector-service_fn_connector-integration_-3517347824656025567 | clm | function | // connector-service/backend/connector-integration/src/connectors/trustpay/transformers.rs
fn handle_bank_redirects_response(
response: PaymentsResponseBankRedirect,
status_code: u16,
) -> CustomResult<
(
enums::AttemptStatus,
Option<ErrorResponse>,
PaymentsResponseData,
),
... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "handle_bank_redirects_response",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"re... |
connector-service_fn_connector-integration_-4374479314201853124 | clm | function | // connector-service/backend/connector-integration/src/connectors/trustpay/transformers.rs
fn handle_bank_redirects_error_response(
response: ErrorResponseBankRedirect,
status_code: u16,
previous_attempt_status: enums::AttemptStatus,
) -> CustomResult<
(
enums::AttemptStatus,
Option<Err... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "handle_bank_redirects_error_response",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,... |
connector-service_fn_connector-integration_-1347416815255535494 | clm | function | // connector-service/backend/connector-integration/src/connectors/trustpay/transformers.rs
fn handle_bank_redirects_sync_response(
response: SyncResponseBankRedirect,
status_code: u16,
) -> CustomResult<
(
enums::AttemptStatus,
Option<ErrorResponse>,
PaymentsResponseData,
),
... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "handle_bank_redirects_sync_response",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
... |
connector-service_fn_connector-integration_-2715685907814403815 | clm | function | // connector-service/backend/connector-integration/src/connectors/trustpay/transformers.rs
pub fn handle_webhook_response(
payment_information: WebhookPaymentInformation,
status_code: u16,
) -> CustomResult<
(
enums::AttemptStatus,
Option<ErrorResponse>,
PaymentsResponseData,
),... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "handle_webhook_response",
"is_async": false,
"is_pub": true,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "co... |
connector-service_fn_connector-integration_1129761068507008509 | clm | function | // connector-service/backend/connector-integration/src/connectors/trustpay/transformers.rs
pub fn get_trustpay_response(
response: TrustpayPaymentsResponse,
status_code: u16,
previous_attempt_status: enums::AttemptStatus,
) -> CustomResult<
(
enums::AttemptStatus,
Option<ErrorResponse>,... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "get_trustpay_response",
"is_async": false,
"is_pub": true,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "conn... |
connector-service_fn_connector-integration_-6845142066205286710 | clm | function | // connector-service/backend/connector-integration/src/connectors/xendit/transformers.rs
fn try_from(item: ResponseRouterData<RefundResponse, Self>) -> Result<Self, Self::Error> {
let ResponseRouterData {
response,
router_data,
http_code,
} = item;
Ok(Self {
... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "try_from",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "connector-servic... |
connector-service_fn_connector-integration_-7764359483446056564 | clm | function | // connector-service/backend/connector-integration/src/connectors/xendit/transformers.rs
fn is_auto_capture<
T: PaymentMethodDataTypes
+ std::fmt::Debug
+ std::marker::Sync
+ std::marker::Send
+ 'static
+ Serialize,
>(
data: &PaymentsAuthorizeData<T>,
) -> Result<bool, C... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "is_auto_capture",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "connector... |
connector-service_fn_connector-integration_2957072239002240268 | clm | function | // connector-service/backend/connector-integration/src/connectors/xendit/transformers.rs
fn is_auto_capture_psync(data: &PaymentsSyncData) -> Result<bool, ConnectorError> {
match data.capture_method {
Some(common_enums::CaptureMethod::Automatic) | None => Ok(true),
Some(common_enums::CaptureMethod:... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "is_auto_capture_psync",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "con... |
connector-service_fn_connector-integration_1220201645857116306 | clm | function | // connector-service/backend/connector-integration/src/connectors/xendit/transformers.rs
fn map_payment_response_to_attempt_status(
response: XenditPaymentResponse,
is_auto_capture: bool,
) -> common_enums::AttemptStatus {
match response.status {
PaymentStatus::Failed => common_enums::AttemptStatus... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "map_payment_response_to_attempt_status",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": nul... |
connector-service_fn_connector-integration_4328141175566158444 | clm | function | // connector-service/backend/connector-integration/src/connectors/xendit/transformers.rs
fn from(item: RefundStatus) -> Self {
match item {
RefundStatus::Succeeded => Self::Success,
RefundStatus::Failed | RefundStatus::Cancelled => Self::Failure,
RefundStatus::Pending | Refu... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "from",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "connector-service",
... |
connector-service_fn_connector-integration_-7080870094687339040 | clm | function | // connector-service/backend/connector-integration/src/connectors/xendit/transformers.rs
fn is_mandate_payment<
T: PaymentMethodDataTypes
+ std::fmt::Debug
+ std::marker::Sync
+ std::marker::Send
+ 'static
+ Serialize,
>(
item: &PaymentsAuthorizeData<T>,
) -> bool {
... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "is_mandate_payment",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "connec... |
connector-service_fn_connector-integration_-5499501572199064837 | clm | function | // connector-service/backend/connector-integration/src/connectors/volt/transformers.rs
fn try_from(item: RefundsResponseRouterData<F, RefundResponse>) -> Result<Self, Self::Error> {
Ok(Self {
response: Ok(RefundsResponseData {
connector_refund_id: item.response.id.to_string(),
... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "try_from",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "connector-servic... |
connector-service_fn_connector-integration_-4471542057309744522 | clm | function | // connector-service/backend/connector-integration/src/connectors/volt/transformers.rs
fn get_attempt_status((item, current_status): (VoltPaymentStatus, AttemptStatus)) -> AttemptStatus {
match item {
VoltPaymentStatus::Received | VoltPaymentStatus::Settled => AttemptStatus::Charged,
VoltPaymentSta... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "get_attempt_status",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "connec... |
connector-service_fn_connector-integration_-8121934653120202201 | clm | function | // connector-service/backend/connector-integration/src/connectors/volt/transformers.rs
fn from(status: VoltWebhookBodyEventType) -> Self {
match status {
VoltWebhookBodyEventType::Payment(payment_data) => match payment_data.status {
VoltWebhookPaymentStatus::Received => Self::Paymen... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "from",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "connector-service",
... |
connector-service_fn_connector-integration_4840959861993344353 | clm | function | // connector-service/backend/connector-integration/src/connectors/noon/transformers.rs
fn get_value_as_string(value: &serde_json::Value) -> String {
match value {
serde_json::Value::String(string) => string.to_owned(),
serde_json::Value::Null
| serde_json::Value::Bool(_)
| serde_jso... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "get_value_as_string",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "conne... |
connector-service_fn_connector-integration_3000270290517726204 | clm | function | // connector-service/backend/connector-integration/src/connectors/noon/transformers.rs
pub fn new(metadata: &serde_json::Value) -> Self {
let metadata_as_string = metadata.to_string();
let hash_map: std::collections::BTreeMap<String, serde_json::Value> =
serde_json::from_str(&metadata_as_st... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "new",
"is_async": false,
"is_pub": true,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "connector-service",
... |
connector-service_fn_connector-integration_4862076425151944515 | clm | function | // connector-service/backend/connector-integration/src/connectors/noon/transformers.rs
fn try_from(item: ResponseRouterData<SetupMandateResponse, Self>) -> Result<Self, Self::Error> {
let order = item.response.result.order;
let current_attempt_status = item.router_data.resource_common_data.status;
... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "try_from",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "connector-servic... |
connector-service_fn_connector-integration_6624040959457726474 | clm | function | // connector-service/backend/connector-integration/src/connectors/noon/transformers.rs
fn get_payment_status(data: (NoonPaymentStatus, AttemptStatus)) -> AttemptStatus {
let (item, current_status) = data;
match item {
NoonPaymentStatus::Authorized => AttemptStatus::Authorized,
NoonPaymentStatus... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "get_payment_status",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "connec... |
connector-service_fn_connector-integration_253263964257174660 | clm | function | // connector-service/backend/connector-integration/src/connectors/noon/transformers.rs
fn from(value: NoonWebhookObject) -> Self {
Self {
result: NoonPaymentsResponseResult {
order: NoonPaymentsOrderResponse {
status: value.order_status,
id: v... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "from",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "connector-service",
... |
connector-service_fn_connector-integration_-8659267270991720171 | clm | function | // connector-service/backend/connector-integration/src/connectors/placetopay/transformers.rs
fn try_from(
item: ResponseRouterData<PlacetopayRefundResponse, Self>,
) -> Result<Self, Self::Error> {
Ok(Self {
response: Ok(RefundsResponseData {
connector_refund_id: item.res... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "try_from",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "connector-servic... |
connector-service_fn_connector-integration_-6218284339970308393 | clm | function | // connector-service/backend/connector-integration/src/connectors/placetopay/transformers.rs
fn from(item: PlacetopayRefundStatus) -> Self {
match item {
PlacetopayRefundStatus::Ok
| PlacetopayRefundStatus::Approved
| PlacetopayRefundStatus::Refunded => Self::Success,
... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "from",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "connector-service",
... |
connector-service_fn_connector-integration_3152717781405429979 | clm | function | // connector-service/backend/connector-integration/src/connectors/razorpay/test.rs
fn test_build_request_valid() {
let email = Email::try_from("testuser@gmail.com".to_string()).unwrap();
let test_router_data = RouterDataV2 {
flow: std::marker::PhantomData,
resou... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "test_build_request_valid",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "... |
connector-service_fn_connector-integration_-6108357518927124253 | clm | function | // connector-service/backend/connector-integration/src/connectors/razorpay/test.rs
fn test_build_request_missing() {
use common_enums::Currency;
use common_utils::{id_type::MerchantId, types::MinorUnit};
use domain_types::{
connector_types::PaymentCreateOrderData,
... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "test_build_request_missing",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo":... |
connector-service_fn_connector-integration_-4559112145041872844 | clm | function | // connector-service/backend/connector-integration/src/connectors/razorpay/test.rs
fn test_build_request_invalid() {
use common_enums::{
AttemptStatus, AuthenticationType, Currency, PaymentMethod, PaymentMethodType,
};
use common_utils::{id_type::MerchantId, types::M... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "test_build_request_invalid",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo":... |
connector-service_fn_connector-integration_-3871210758204669158 | clm | function | // connector-service/backend/connector-integration/src/connectors/razorpay/test.rs
fn test_handle_response_v2_valid_authorize_response() {
use std::str::FromStr;
use common_enums::Currency;
use common_utils::{id_type::MerchantId, pii::Email, types::MinorUnit};
use domai... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "test_handle_response_v2_valid_authorize_response",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_str... |
connector-service_fn_connector-integration_-8922597920826393306 | clm | function | // connector-service/backend/connector-integration/src/connectors/razorpay/test.rs
fn test_handle_authorize_error_response() {
use domain_types::{
connector_flow::Authorize,
connector_types::{PaymentFlowData, PaymentsAuthorizeData, PaymentsResponseData},
};
... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "test_handle_authorize_error_response",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,... |
connector-service_fn_connector-integration_901397538912186964 | clm | function | // connector-service/backend/connector-integration/src/connectors/razorpay/test.rs
fn test_handle_authorize_missing_required_fields() {
use domain_types::{
connector_flow::Authorize,
connector_types::{PaymentFlowData, PaymentsAuthorizeData, PaymentsResponseData},
... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "test_handle_authorize_missing_required_fields",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_struct... |
connector-service_fn_connector-integration_-4972240173322938778 | clm | function | // connector-service/backend/connector-integration/src/connectors/razorpay/test.rs
fn test_handle_authorize_invalid_error_fields() {
use domain_types::{
connector_flow::Authorize,
connector_types::{PaymentFlowData, PaymentsAuthorizeData, PaymentsResponseData},
};
let ht... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "test_handle_authorize_invalid_error_fields",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs":... |
connector-service_fn_connector-integration_8878164691626727343 | clm | function | // connector-service/backend/connector-integration/src/connectors/razorpay/test.rs
fn test_handle_response_v2_missing_fields_authorize_response() {
use std::str::FromStr;
use common_enums::Currency;
use common_utils::{id_type::MerchantId, pii::Email, types::MinorUnit};
use domain_types... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "test_handle_response_v2_missing_fields_authorize_response",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
... |
connector-service_fn_connector-integration_-1262477012638053872 | clm | function | // connector-service/backend/connector-integration/src/connectors/razorpay/test.rs
fn test_handle_response_v2_invalid_json_authorize_response() {
use std::str::FromStr;
use common_enums::Currency;
use common_utils::{id_type::MerchantId, pii::Email, types::MinorUnit};
use domain_types::... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "test_handle_response_v2_invalid_json_authorize_response",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"... |
connector-service_fn_connector-integration_-7908791156729419999 | clm | function | // connector-service/backend/connector-integration/src/connectors/razorpay/test.rs
fn test_build_request_valid_order() {
use common_enums::Currency;
use common_utils::{id_type::MerchantId, request::RequestContent, types::MinorUnit};
use domain_types::{
connector_type... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "test_build_request_valid_order",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"re... |
connector-service_fn_connector-integration_-2250098341918712889 | clm | function | // connector-service/backend/connector-integration/src/connectors/razorpay/test.rs
fn test_handle_response_v2_valid_order_response() {
use common_enums::Currency;
use common_utils::{id_type::MerchantId, pii::Email, types::MinorUnit};
use domain_types::{
connector_types::{PaymentCrea... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "test_handle_response_v2_valid_order_response",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs... |
connector-service_fn_connector-integration_6941333131051758840 | clm | function | // connector-service/backend/connector-integration/src/connectors/razorpay/test.rs
fn test_handle_response_missing() {
use common_enums::Currency;
use common_utils::{id_type::MerchantId, pii::Email, types::MinorUnit};
use domain_types::{
connector_types::PaymentCreateOrderData,
... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "test_handle_response_missing",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo... |
connector-service_fn_connector-integration_989211878059782093 | clm | function | // connector-service/backend/connector-integration/src/connectors/razorpay/test.rs
fn test_handle_response_invalid() {
use common_enums::Currency;
use common_utils::{id_type::MerchantId, pii::Email, types::MinorUnit};
use domain_types::{
connector_types::PaymentCreateOrderData,
... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "test_handle_response_invalid",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo... |
connector-service_fn_connector-integration_3435598897392635562 | clm | function | // connector-service/backend/connector-integration/src/connectors/razorpay/test.rs
fn test_handle_error_response_valid() {
let http_response = Response {
headers: None,
response: br#"{
"error": {
"code": "BAD_REQUEST_ERROR",
"descr... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "test_handle_error_response_valid",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"... |
connector-service_fn_connector-integration_8132296736493886026 | clm | function | // connector-service/backend/connector-integration/src/connectors/razorpay/test.rs
fn test_handle_error_response_invalid_json() {
let http_response = Response {
headers: None,
response: br#"{ "error": { "code": "BAD_REQUEST_ERROR" "#.to_vec().into(),
status_code: 400,
... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "test_handle_error_response_invalid_json",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": nu... |
connector-service_fn_connector-integration_4630970440140951762 | clm | function | // connector-service/backend/connector-integration/src/connectors/razorpay/test.rs
fn test_handle_error_response_missing_error_field() {
let http_response = Response {
headers: None,
response: br#"{
"message": "Some generic message",
"status": "failed"
}"... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "test_handle_error_response_missing_error_field",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_struc... |
connector-service_fn_connector-integration_-9078528393221723888 | clm | function | // connector-service/backend/connector-integration/src/connectors/razorpay/transformers.rs
fn try_from(
item: &RazorpayRouterData<
&RouterDataV2<
domain_types::connector_flow::Authorize,
PaymentFlowData,
PaymentsAuthorizeData<T>,
Payme... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "try_from",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "connector-servic... |
connector-service_fn_connector-integration_5939746031037116638 | clm | function | // connector-service/backend/connector-integration/src/connectors/razorpay/transformers.rs
pub fn generate_authorization_header(&self) -> String {
let auth_type_name = match self {
RazorpayAuthType::AuthToken(_) => "AuthToken",
RazorpayAuthType::ApiKeySecret { .. } => "ApiKeySecret",
... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "generate_authorization_header",
"is_async": false,
"is_pub": true,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo... |
connector-service_fn_connector-integration_-7098095553287580584 | clm | function | // connector-service/backend/connector-integration/src/connectors/razorpay/transformers.rs
fn extract_payment_method_and_data<
T: PaymentMethodDataTypes
+ std::fmt::Debug
+ std::marker::Sync
+ std::marker::Send
+ 'static
+ Serialize,
>(
payment_method_data: &PaymentMetho... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "extract_payment_method_and_data",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"r... |
connector-service_fn_connector-integration_-7952878649503609795 | clm | function | // connector-service/backend/connector-integration/src/connectors/razorpay/transformers.rs
fn foreign_try_from(
(upi_response, data, _status_code, _raw_response): (
RazorpayUpiPaymentsResponse,
RouterDataV2<F, PaymentFlowData, Req, PaymentsResponseData>,
u16,
Vec... | {
"chunk": null,
"crate": "connector-integration",
"enum_name": null,
"file_size": null,
"for_type": null,
"function_name": "foreign_try_from",
"is_async": false,
"is_pub": false,
"lines": null,
"method_name": null,
"num_enums": null,
"num_items": null,
"num_structs": null,
"repo": "connecto... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.