Skip to content

Commit 08ffaed

Browse files
Merge branch 'main' into 4229-feature-store-payment-check-codes-and-authentication-data-from-processors
2 parents b5985d3 + 3eb4642 commit 08ffaed

File tree

42 files changed

+1320
-997
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

42 files changed

+1320
-997
lines changed

Cargo.lock

Lines changed: 418 additions & 451 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

config/config.example.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -600,3 +600,4 @@ region = "eu-central-1"
600600
payment_attempts = "hyperswitch-payment-attempt-events"
601601
payment_intents = "hyperswitch-payment-intent-events"
602602
refunds = "hyperswitch-refund-events"
603+
disputes = "hyperswitch-dispute-events"

config/deployments/env_specific.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -215,6 +215,7 @@ region = "eu-central-1"
215215
payment_attempts = "hyperswitch-payment-attempt-events"
216216
payment_intents = "hyperswitch-payment-intent-events"
217217
refunds = "hyperswitch-refund-events"
218+
disputes = "hyperswitch-dispute-events"
218219

219220
# This section provides some secret values.
220221
[secrets]

config/development.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -597,3 +597,4 @@ region = "eu-central-1"
597597
payment_attempts = "hyperswitch-payment-attempt-events"
598598
payment_intents = "hyperswitch-payment-intent-events"
599599
refunds = "hyperswitch-refund-events"
600+
disputes = "hyperswitch-dispute-events"

config/docker_compose.toml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -455,4 +455,5 @@ region = "eu-central-1"
455455
[opensearch.indexes]
456456
payment_attempts = "hyperswitch-payment-attempt-events"
457457
payment_intents = "hyperswitch-payment-intent-events"
458-
refunds = "hyperswitch-refund-events"
458+
refunds = "hyperswitch-refund-events"
459+
disputes = "hyperswitch-dispute-events"

crates/analytics/src/lib.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -679,6 +679,7 @@ pub struct OpensearchIndexes {
679679
pub payment_attempts: String,
680680
pub payment_intents: String,
681681
pub refunds: String,
682+
pub disputes: String,
682683
}
683684

684685
#[derive(Clone, Debug, serde::Deserialize)]
@@ -700,6 +701,7 @@ impl Default for OpensearchConfig {
700701
payment_attempts: "hyperswitch-payment-attempt-events".to_string(),
701702
payment_intents: "hyperswitch-payment-intent-events".to_string(),
702703
refunds: "hyperswitch-refund-events".to_string(),
704+
disputes: "hyperswitch-dispute-events".to_string(),
703705
},
704706
}
705707
}

crates/analytics/src/search.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@ pub fn search_index_to_opensearch_index(index: SearchIndex, config: &OpensearchI
3434
SearchIndex::PaymentAttempts => config.payment_attempts.clone(),
3535
SearchIndex::PaymentIntents => config.payment_intents.clone(),
3636
SearchIndex::Refunds => config.refunds.clone(),
37+
SearchIndex::Disputes => config.disputes.clone(),
3738
}
3839
}
3940

crates/api_models/src/analytics/search.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,7 @@ pub enum SearchIndex {
3636
PaymentAttempts,
3737
PaymentIntents,
3838
Refunds,
39+
Disputes,
3940
}
4041

4142
#[derive(Clone, Debug, serde::Deserialize, serde::Serialize)]

crates/api_models/src/mandates.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -87,6 +87,8 @@ pub struct MandateCardDetails {
8787
pub struct MandateListConstraints {
8888
/// limit on the number of objects to return
8989
pub limit: Option<i64>,
90+
/// offset on the number of objects to return
91+
pub offset: Option<i64>,
9092
/// status of the mandate
9193
pub mandate_status: Option<api_enums::MandateStatus>,
9294
/// connector linked to mandate

crates/api_models/src/payments.rs

Lines changed: 3 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -2333,7 +2333,7 @@ pub enum ThreeDsMethodData {
23332333
/// Whether ThreeDS method data submission is required
23342334
three_ds_method_data_submission: bool,
23352335
/// ThreeDS method data
2336-
three_ds_method_data: String,
2336+
three_ds_method_data: Option<String>,
23372337
/// ThreeDS method url
23382338
three_ds_method_url: Option<String>,
23392339
},
@@ -3665,40 +3665,12 @@ pub struct SdkInformation {
36653665
pub sdk_max_timeout: u8,
36663666
}
36673667

3668-
#[derive(Clone, Default, Debug, serde::Serialize, serde::Deserialize, Eq, PartialEq, ToSchema)]
3669-
pub enum TransactionStatus {
3670-
/// Authentication/ Account Verification Successful
3671-
#[serde(rename = "Y")]
3672-
Success,
3673-
/// Not Authenticated /Account Not Verified; Transaction denied
3674-
#[default]
3675-
#[serde(rename = "N")]
3676-
Failure,
3677-
/// Authentication/ Account Verification Could Not Be Performed; Technical or other problem, as indicated in Authentication Response(ARes) or Result Request (RReq)
3678-
#[serde(rename = "U")]
3679-
VerificationNotPerformed,
3680-
/// Attempts Processing Performed; Not Authenticated/Verified , but a proof of attempted authentication/verification is provided
3681-
#[serde(rename = "A")]
3682-
NotVerified,
3683-
/// Authentication/ Account Verification Rejected; Issuer is rejecting authentication/verification and request that authorisation not be attempted.
3684-
#[serde(rename = "R")]
3685-
Rejected,
3686-
/// Challenge Required; Additional authentication is required using the Challenge Request (CReq) / Challenge Response (CRes)
3687-
#[serde(rename = "C")]
3688-
ChallengeRequired,
3689-
/// Challenge Required; Decoupled Authentication confirmed.
3690-
#[serde(rename = "D")]
3691-
ChallengeRequiredDecoupledAuthentication,
3692-
/// Informational Only; 3DS Requestor challenge preference acknowledged.
3693-
#[serde(rename = "I")]
3694-
InformationOnly,
3695-
}
3696-
36973668
#[derive(Debug, serde::Serialize, serde::Deserialize, Clone, ToSchema)]
36983669
pub struct PaymentsExternalAuthenticationResponse {
36993670
/// Indicates the trans status
37003671
#[serde(rename = "trans_status")]
3701-
pub transaction_status: TransactionStatus,
3672+
#[schema(value_type = TransactionStatus)]
3673+
pub transaction_status: common_enums::TransactionStatus,
37023674
/// Access Server URL to be used for challenge submission
37033675
pub acs_url: Option<String>,
37043676
/// Challenge request which should be sent to acs_url

0 commit comments

Comments
 (0)