mirror of
https://github.com/juspay/hyperswitch.git
synced 2025-10-29 09:07:09 +08:00
feat(frm): Add support to accept and decline payment when manually reviewed by merchant for risky transaction (#2071)
This commit is contained in:
@ -1908,6 +1908,9 @@ pub struct PaymentsResponse {
|
||||
|
||||
/// total number of attempts associated with this payment
|
||||
pub attempt_count: i16,
|
||||
|
||||
/// Denotes the action(approve or reject) taken by merchant in case of manual review. Manual review can occur when the transaction is marked as risky by the frm_processor, payment processor or when there is underpayment/over payment incase of crypto payment
|
||||
pub merchant_decision: Option<String>,
|
||||
}
|
||||
|
||||
#[derive(Clone, Debug, serde::Deserialize, ToSchema)]
|
||||
@ -2632,6 +2635,20 @@ pub struct PaymentsCancelRequest {
|
||||
pub merchant_connector_details: Option<admin::MerchantConnectorDetailsWrap>,
|
||||
}
|
||||
|
||||
#[derive(Default, Debug, serde::Deserialize, serde::Serialize, Clone, ToSchema)]
|
||||
pub struct PaymentsApproveRequest {
|
||||
/// The identifier for the payment
|
||||
#[serde(skip)]
|
||||
pub payment_id: String,
|
||||
}
|
||||
|
||||
#[derive(Default, Debug, serde::Deserialize, serde::Serialize, Clone, ToSchema)]
|
||||
pub struct PaymentsRejectRequest {
|
||||
/// The identifier for the payment
|
||||
#[serde(skip)]
|
||||
pub payment_id: String,
|
||||
}
|
||||
|
||||
#[derive(Default, Debug, serde::Deserialize, serde::Serialize, ToSchema, Clone)]
|
||||
pub struct PaymentsStartRequest {
|
||||
/// Unique identifier for the payment. This ensures idempotency for multiple payments
|
||||
|
||||
Reference in New Issue
Block a user