package routers import ( "fmt" "git.apinb.com/heqiapp/platforms/backend/api/internal/logic/payment" "github.com/gin-gonic/gin" ) // RegisterPaymentReturn 注册无 JWT 的渠道回调;安全性由渠道签名、商户、金额和支付单校验保证。 func RegisterPaymentReturn(serviceKey string, engine *gin.Engine) { group := engine.Group(fmt.Sprintf("/%s/payment-return/v1", serviceKey)) group.POST("/alipay/notify", payment.AlipayNotify) group.POST("/wechat/notify", payment.WechatNotify) engine.POST(fmt.Sprintf("/%s/internal/v1/payment/close-expired", serviceKey), payment.CloseExpiredHandler) }