feat(order): add validation for quantity and amount limits in order requests

This commit is contained in:
Chang lue Tsen
2026-02-08 06:41:23 -05:00
parent 1995987f00
commit 701d47ed21
8 changed files with 106 additions and 23 deletions
+5
View File
@@ -6,4 +6,9 @@ const (
StripeAlipay = "stripe_alipay"
StripeWeChatPay = "stripe_wechat_pay"
Balance = "balance"
// MaxOrderAmount Order amount limits
MaxOrderAmount = 2147483647 // int32 max value (2.1 billion)
MaxRechargeAmount = 2000000000 // 2 billion, slightly lower for safety
MaxQuantity = 1000 // Maximum quantity per order
)