mirror of
				https://github.com/juspay/hyperswitch.git
				synced 2025-11-01 02:57:02 +08:00 
			
		
		
		
	refactor(merchant_id): create domain type for merchant_id (#5408)
				
					
				
			Co-authored-by: hyperswitch-bot[bot] <148525504+hyperswitch-bot[bot]@users.noreply.github.com> Co-authored-by: Sanchith Hegde <22217505+SanchithHegde@users.noreply.github.com>
This commit is contained in:
		| @ -33,8 +33,8 @@ pub struct PayoutCreateRequest { | ||||
|  | ||||
|     /// This is an identifier for the merchant account. This is inferred from the API key | ||||
|     /// provided during the request | ||||
|     #[schema(max_length = 255, value_type = String, example = "merchant_1668273825")] | ||||
|     pub merchant_id: Option<String>, | ||||
|     #[schema(max_length = 255, value_type = Option<String>, example = "merchant_1668273825")] | ||||
|     pub merchant_id: Option<id_type::MerchantId>, | ||||
|  | ||||
|     /// The payout amount. Amount for the payout in lowest denomination of the currency. (i.e) in cents for USD denomination, in paisa for INR denomination etc., | ||||
|     #[schema(value_type = i64, example = 1000)] | ||||
| @ -362,7 +362,7 @@ pub struct PayoutCreateResponse { | ||||
|     /// This is an identifier for the merchant account. This is inferred from the API key | ||||
|     /// provided during the request | ||||
|     #[schema(max_length = 255, value_type = String, example = "merchant_1668273825")] | ||||
|     pub merchant_id: String, | ||||
|     pub merchant_id: id_type::MerchantId, | ||||
|  | ||||
|     /// The payout amount. Amount for the payout in lowest denomination of the currency. (i.e) in cents for USD denomination, in paisa for INR denomination etc., | ||||
|     #[schema(value_type = i64, example = 1000)] | ||||
| @ -531,7 +531,8 @@ pub struct PayoutAttemptResponse { | ||||
| #[derive(Default, Debug, Clone, Deserialize, ToSchema)] | ||||
| pub struct PayoutRetrieveBody { | ||||
|     pub force_sync: Option<bool>, | ||||
|     pub merchant_id: Option<String>, | ||||
|     #[schema(value_type = Option<String>)] | ||||
|     pub merchant_id: Option<id_type::MerchantId>, | ||||
| } | ||||
|  | ||||
| #[derive(Default, Debug, Serialize, ToSchema, Clone, Deserialize)] | ||||
| @ -552,7 +553,8 @@ pub struct PayoutRetrieveRequest { | ||||
|     pub force_sync: Option<bool>, | ||||
|  | ||||
|     /// The identifier for the Merchant Account. | ||||
|     pub merchant_id: Option<String>, | ||||
|     #[schema(value_type = Option<String>)] | ||||
|     pub merchant_id: Option<id_type::MerchantId>, | ||||
| } | ||||
|  | ||||
| #[derive(Default, Debug, Serialize, ToSchema, Clone, Deserialize)] | ||||
| @ -707,7 +709,8 @@ pub struct PayoutLinkResponse { | ||||
|  | ||||
| #[derive(Clone, Debug, serde::Deserialize, ToSchema, serde::Serialize)] | ||||
| pub struct PayoutLinkInitiateRequest { | ||||
|     pub merchant_id: String, | ||||
|     #[schema(value_type = String)] | ||||
|     pub merchant_id: id_type::MerchantId, | ||||
|     pub payout_id: String, | ||||
| } | ||||
|  | ||||
|  | ||||
		Reference in New Issue
	
	Block a user
	 Narayan Bhat
					Narayan Bhat