swagger: document the ?lang= query parameter on every admin endpoint
appresult.Localize applies to all /api/admin routes, so each handler's godoc now declares lang (tm, ru, en, all; default tm) and Swagger UI offers it as a dropdown. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -44,6 +44,7 @@ func (h *handler) Register(router *gin.RouterGroup) {
|
||||
// @Produce json
|
||||
// @Security BearerAuth
|
||||
// @Param id path int true "Visa/master payment order ID"
|
||||
// @Param lang query string false "Language of localized fields; all returns the full {en, ru, tm} objects" Enums(tm, ru, en, all) default(tm)
|
||||
// @Success 200 {object} PaymentQuoteDTO
|
||||
// @Failure 400 {object} appresult.AppError
|
||||
// @Failure 404 {object} appresult.AppError
|
||||
@@ -77,6 +78,7 @@ func (h *handler) quote(c *gin.Context) {
|
||||
// @Security BearerAuth
|
||||
// @Param id path int true "Visa/master payment order ID"
|
||||
// @Param body body PayOrderDTO true "Payment payload"
|
||||
// @Param lang query string false "Language of localized fields; all returns the full {en, ru, tm} objects" Enums(tm, ru, en, all) default(tm)
|
||||
// @Success 200 {object} PaymentInitResultDTO
|
||||
// @Failure 400 {object} appresult.AppError
|
||||
// @Failure 404 {object} appresult.AppError
|
||||
@@ -117,6 +119,7 @@ func (h *handler) pay(c *gin.Context) {
|
||||
// @Produce json
|
||||
// @Security BearerAuth
|
||||
// @Param id path int true "Visa/master payment order ID"
|
||||
// @Param lang query string false "Language of localized fields; all returns the full {en, ru, tm} objects" Enums(tm, ru, en, all) default(tm)
|
||||
// @Success 200 {object} PaymentResultDTO
|
||||
// @Failure 400 {object} appresult.AppError
|
||||
// @Failure 404 {object} appresult.AppError
|
||||
@@ -152,6 +155,7 @@ func (h *handler) status(c *gin.Context) {
|
||||
// @Tags visa-master-payment-orders
|
||||
// @Produce json
|
||||
// @Param paymentId query int true "Payment attempt ID"
|
||||
// @Param lang query string false "Language of localized fields; all returns the full {en, ru, tm} objects" Enums(tm, ru, en, all) default(tm)
|
||||
// @Success 200 {object} CallbackResultDTO
|
||||
// @Router /visa-master-payment-orders/callback [get]
|
||||
func (h *handler) callback(c *gin.Context) {
|
||||
|
||||
Reference in New Issue
Block a user