-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
refactor(core): move router data flow types to hyperswitch domain mod…
…els crate (#4801)
- Loading branch information
1 parent
08eefdb
commit 61e67e4
Showing
18 changed files
with
148 additions
and
116 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
pub mod access_token_auth; | ||
pub mod dispute; | ||
pub mod files; | ||
pub mod fraud_check; | ||
pub mod payments; | ||
pub mod payouts; | ||
pub mod refunds; | ||
pub mod webhooks; | ||
|
||
pub use access_token_auth::*; | ||
pub use dispute::*; | ||
pub use files::*; | ||
pub use fraud_check::*; | ||
pub use payments::*; | ||
pub use payouts::*; | ||
pub use refunds::*; | ||
pub use webhooks::*; |
2 changes: 2 additions & 0 deletions
2
crates/hyperswitch_domain_models/src/router_flow_types/access_token_auth.rs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
#[derive(Clone, Debug)] | ||
pub struct AccessTokenAuth; |
7 changes: 7 additions & 0 deletions
7
crates/hyperswitch_domain_models/src/router_flow_types/dispute.rs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
#[derive(Debug, Clone)] | ||
pub struct Accept; | ||
#[derive(Debug, Clone)] | ||
pub struct Evidence; | ||
|
||
#[derive(Debug, Clone)] | ||
pub struct Defend; |
5 changes: 5 additions & 0 deletions
5
crates/hyperswitch_domain_models/src/router_flow_types/files.rs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
#[derive(Debug, Clone)] | ||
pub struct Retrieve; | ||
|
||
#[derive(Debug, Clone)] | ||
pub struct Upload; |
14 changes: 14 additions & 0 deletions
14
crates/hyperswitch_domain_models/src/router_flow_types/fraud_check.rs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
#[derive(Debug, Clone)] | ||
pub struct Sale; | ||
|
||
#[derive(Debug, Clone)] | ||
pub struct Checkout; | ||
|
||
#[derive(Debug, Clone)] | ||
pub struct Transaction; | ||
|
||
#[derive(Debug, Clone)] | ||
pub struct Fulfillment; | ||
|
||
#[derive(Debug, Clone)] | ||
pub struct RecordReturn; |
48 changes: 48 additions & 0 deletions
48
crates/hyperswitch_domain_models/src/router_flow_types/payments.rs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
// Core related api layer. | ||
#[derive(Debug, Clone)] | ||
pub struct Authorize; | ||
|
||
#[derive(Debug, Clone)] | ||
pub struct AuthorizeSessionToken; | ||
|
||
#[derive(Debug, Clone)] | ||
pub struct CompleteAuthorize; | ||
|
||
#[derive(Debug, Clone)] | ||
pub struct Approve; | ||
|
||
// Used in gift cards balance check | ||
#[derive(Debug, Clone)] | ||
pub struct Balance; | ||
|
||
#[derive(Debug, Clone)] | ||
pub struct InitPayment; | ||
|
||
#[derive(Debug, Clone)] | ||
pub struct Capture; | ||
|
||
#[derive(Debug, Clone)] | ||
pub struct PSync; | ||
#[derive(Debug, Clone)] | ||
pub struct Void; | ||
|
||
#[derive(Debug, Clone)] | ||
pub struct Reject; | ||
|
||
#[derive(Debug, Clone)] | ||
pub struct Session; | ||
|
||
#[derive(Debug, Clone)] | ||
pub struct PaymentMethodToken; | ||
|
||
#[derive(Debug, Clone)] | ||
pub struct CreateConnectorCustomer; | ||
|
||
#[derive(Debug, Clone)] | ||
pub struct SetupMandate; | ||
|
||
#[derive(Debug, Clone)] | ||
pub struct PreProcessing; | ||
|
||
#[derive(Debug, Clone)] | ||
pub struct IncrementalAuthorization; |
20 changes: 20 additions & 0 deletions
20
crates/hyperswitch_domain_models/src/router_flow_types/payouts.rs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
#[derive(Debug, Clone)] | ||
pub struct PoCancel; | ||
|
||
#[derive(Debug, Clone)] | ||
pub struct PoCreate; | ||
|
||
#[derive(Debug, Clone)] | ||
pub struct PoEligibility; | ||
|
||
#[derive(Debug, Clone)] | ||
pub struct PoFulfill; | ||
|
||
#[derive(Debug, Clone)] | ||
pub struct PoQuote; | ||
|
||
#[derive(Debug, Clone)] | ||
pub struct PoRecipient; | ||
|
||
#[derive(Debug, Clone)] | ||
pub struct PoRecipientAccount; |
4 changes: 4 additions & 0 deletions
4
crates/hyperswitch_domain_models/src/router_flow_types/refunds.rs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
#[derive(Debug, Clone)] | ||
pub struct Execute; | ||
#[derive(Debug, Clone)] | ||
pub struct RSync; |
2 changes: 2 additions & 0 deletions
2
crates/hyperswitch_domain_models/src/router_flow_types/webhooks.rs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
#[derive(Clone, Debug)] | ||
pub struct VerifyWebhookSource; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.