add payment settting
Some checks failed
CI/CD / Vet, test, build (push) Has been cancelled
CI/CD / Docker image (push) Has been cancelled
CI/CD / Deploy binary to server (push) Has been cancelled

This commit is contained in:
2026-09-19 02:12:59 +05:00
parent 0971158e98
commit b8455625b5
21 changed files with 1760 additions and 12 deletions

View File

@@ -1295,6 +1295,35 @@ definitions:
- price
- title
type: object
paymentsettings.PaymentSettingsDTO:
properties:
bankFeeTmt:
type: number
gbusFeeTmt:
type: number
sberBankFeeTmt:
type: number
tvebFeeUsd:
type: number
updatedAt:
type: string
type: object
paymentsettings.UpdatePaymentSettingsDTO:
properties:
bankFeeTmt:
type: number
gbusFeeTmt:
type: number
sberBankFeeTmt:
type: number
tvebFeeUsd:
type: number
required:
- bankFeeTmt
- gbusFeeTmt
- sberBankFeeTmt
- tvebFeeUsd
type: object
permission.CreatePermissionDTO:
properties:
code:
@@ -1526,6 +1555,8 @@ definitions:
properties:
address:
type: string
amountUsd:
type: number
branchId:
type: integer
documents:
@@ -1576,6 +1607,7 @@ definitions:
type: integer
required:
- address
- amountUsd
- branchId
- passportName
- passportSurname
@@ -1590,6 +1622,8 @@ definitions:
properties:
address:
type: string
amountUsd:
type: number
branchId:
type: integer
documents:
@@ -1640,6 +1674,7 @@ definitions:
type: integer
required:
- address
- amountUsd
- branchId
- passportName
- passportSurname
@@ -1650,6 +1685,68 @@ definitions:
- senderPassportNumber
- senderPassportSerie
type: object
visamasterpay.PayOrderDTO:
properties:
amountTmt:
type: number
paymentPeriod:
format: date
type: string
type: object
visamasterpay.PaymentQuoteDTO:
properties:
bankFeeTmt:
type: number
exchangeRateRub:
type: number
exchangeRateUsd:
type: number
gbusFeeTmt:
type: number
maxAmountTmt:
type: number
tvebFeeTmt:
type: number
tvebFeeUsd:
type: number
type:
type: string
type: object
visamasterpay.PaymentResultDTO:
properties:
amountTmt:
type: number
amountUsd:
type: number
bankFeeTmt:
type: number
exchangeRateRub:
type: number
exchangeRateUsd:
type: number
gatewayReference:
type: string
gatewayStatus:
type: string
gbusFeeTmt:
type: number
orderId:
type: integer
paid:
type: boolean
paidAt:
type: string
paymentPeriod:
type: string
totalAmountTmt:
type: number
tvebFeeTmt:
type: number
tvebFeeUsd:
type: number
type:
type: string
type: object
host: localhost:5005
info:
contact: {}
@@ -1899,8 +1996,9 @@ paths:
post:
consumes:
- application/json
description: Creates a branch-user assignment, or updates the user's existing
branch if one is already assigned
description: 'Assigns a user to a branch. Users and branches are many-to-many:
a user keeps their other branch assignments, and re-assigning the same pair
is a no-op.'
parameters:
- description: Branch-user payload
in: body
@@ -4792,6 +4890,57 @@ paths:
summary: Update payment card active
tags:
- payment-card
/payment-settings:
get:
description: Returns the admin-configurable bank and GBÜS commission fees used
on loan payments
produces:
- application/json
responses:
"200":
description: OK
schema:
$ref: '#/definitions/paymentsettings.PaymentSettingsDTO'
"500":
description: Internal Server Error
schema:
$ref: '#/definitions/appresult.AppError'
security:
- BearerAuth: []
summary: Get payment settings
tags:
- payment-settings
put:
consumes:
- application/json
description: Updates the bank and GBÜS commission fees used on loan payments
parameters:
- description: Payment settings payload
in: body
name: body
required: true
schema:
$ref: '#/definitions/paymentsettings.UpdatePaymentSettingsDTO'
produces:
- application/json
responses:
"200":
description: OK
schema:
$ref: '#/definitions/paymentsettings.PaymentSettingsDTO'
"400":
description: Bad Request
schema:
$ref: '#/definitions/appresult.AppError'
"500":
description: Internal Server Error
schema:
$ref: '#/definitions/appresult.AppError'
security:
- BearerAuth: []
summary: Update payment settings
tags:
- payment-settings
/permission-roles:
post:
consumes:
@@ -5816,7 +5965,9 @@ paths:
- auth
/users:
get:
description: Returns paginated users with role user, including roleId
description: Returns paginated users, including roleId. Admin-guard callers
(admin, superadmin, and other admin-guard roles) see users of every role;
branch-scoped operators see role=user only, scoped to their branches.
parameters:
- description: Search by username, first name, or last name
in: query
@@ -6271,6 +6422,81 @@ paths:
summary: Update visa/master payment order
tags:
- visa-master-payment-orders
/visa-master-payment-orders/{id}/pay:
post:
consumes:
- application/json
description: Charges the payment gateway and marks the order paid on success
parameters:
- description: Visa/master payment order ID
in: path
name: id
required: true
type: integer
- description: Payment payload
in: body
name: body
required: true
schema:
$ref: '#/definitions/visamasterpay.PayOrderDTO'
produces:
- application/json
responses:
"200":
description: OK
schema:
$ref: '#/definitions/visamasterpay.PaymentResultDTO'
"400":
description: Bad Request
schema:
$ref: '#/definitions/appresult.AppError'
"404":
description: Not Found
schema:
$ref: '#/definitions/appresult.AppError'
"500":
description: Internal Server Error
schema:
$ref: '#/definitions/appresult.AppError'
security:
- BearerAuth: []
summary: Pay out a visa/master/sber order
tags:
- visa-master-payment-orders
/visa-master-payment-orders/{id}/quote:
get:
description: Returns the current rate, configured fees, and max payable amount
for an order's payout
parameters:
- description: Visa/master payment order ID
in: path
name: id
required: true
type: integer
produces:
- application/json
responses:
"200":
description: OK
schema:
$ref: '#/definitions/visamasterpay.PaymentQuoteDTO'
"400":
description: Bad Request
schema:
$ref: '#/definitions/appresult.AppError'
"404":
description: Not Found
schema:
$ref: '#/definitions/appresult.AppError'
"500":
description: Internal Server Error
schema:
$ref: '#/definitions/appresult.AppError'
security:
- BearerAuth: []
summary: Quote a visa/master/sber payment
tags:
- visa-master-payment-orders
securityDefinitions:
BearerAuth:
in: header