mirror of
https://github.com/juspay/hyperswitch.git
synced 2025-10-29 09:07:09 +08:00
refactor(users): Deprecate unused user APIs and stabilize v1 APIs (#6114)
This commit is contained in:
@ -54,42 +54,17 @@ pub enum ParentGroup {
|
||||
Recon,
|
||||
}
|
||||
|
||||
#[derive(Debug, serde::Serialize)]
|
||||
pub enum PermissionModule {
|
||||
Payments,
|
||||
Refunds,
|
||||
MerchantAccount,
|
||||
Connectors,
|
||||
Routing,
|
||||
Analytics,
|
||||
Mandates,
|
||||
Customer,
|
||||
Disputes,
|
||||
ThreeDsDecisionManager,
|
||||
SurchargeDecisionManager,
|
||||
AccountCreate,
|
||||
Payouts,
|
||||
Recon,
|
||||
}
|
||||
|
||||
#[derive(Debug, serde::Serialize)]
|
||||
pub struct AuthorizationInfoResponse(pub Vec<AuthorizationInfo>);
|
||||
|
||||
#[derive(Debug, serde::Serialize)]
|
||||
#[serde(untagged)]
|
||||
pub enum AuthorizationInfo {
|
||||
Module(ModuleInfo),
|
||||
Group(GroupInfo),
|
||||
GroupWithTag(ParentInfo),
|
||||
}
|
||||
|
||||
#[derive(Debug, serde::Serialize)]
|
||||
pub struct ModuleInfo {
|
||||
pub module: PermissionModule,
|
||||
pub description: &'static str,
|
||||
pub permissions: Vec<PermissionInfo>,
|
||||
}
|
||||
|
||||
// TODO: To be deprecated
|
||||
#[derive(Debug, serde::Serialize)]
|
||||
pub struct GroupInfo {
|
||||
pub group: PermissionGroup,
|
||||
@ -122,16 +97,6 @@ pub enum UserStatus {
|
||||
InvitationSent,
|
||||
}
|
||||
|
||||
#[derive(Debug, serde::Deserialize, serde::Serialize)]
|
||||
pub struct MerchantSelectRequest {
|
||||
pub merchant_ids: Vec<common_utils::id_type::MerchantId>,
|
||||
}
|
||||
|
||||
#[derive(Debug, serde::Deserialize, serde::Serialize)]
|
||||
pub struct AcceptInvitationRequest {
|
||||
pub merchant_ids: Vec<common_utils::id_type::MerchantId>,
|
||||
}
|
||||
|
||||
#[derive(Debug, serde::Deserialize, serde::Serialize)]
|
||||
pub struct DeleteUserRoleRequest {
|
||||
pub email: pii::Email,
|
||||
|
||||
Reference in New Issue
Block a user