// Package docs Code generated by swaggo/swag. DO NOT EDIT package docs import "github.com/swaggo/swag" const docTemplate = `{ "schemes": {{ marshal .Schemes }}, "swagger": "2.0", "info": { "description": "{{escape .Description}}", "title": "{{.Title}}", "contact": {}, "version": "{{.Version}}" }, "host": "{{.Host}}", "basePath": "{{.BasePath}}", "paths": { "/branch-users": { "post": { "security": [ { "BearerAuth": [] } ], "description": "Creates a branch-user assignment", "consumes": [ "application/json" ], "produces": [ "application/json" ], "tags": [ "auth" ], "summary": "Assign user to branch", "parameters": [ { "description": "Branch-user payload", "name": "body", "in": "body", "required": true, "schema": { "$ref": "#/definitions/auth.CreateBranchUserDTO" } } ], "responses": { "201": { "description": "Created", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "400": { "description": "Bad Request", "schema": { "$ref": "#/definitions/appresult.AppError" } }, "500": { "description": "Internal Server Error", "schema": { "$ref": "#/definitions/appresult.AppError" } } } } }, "/branch-users/{id}": { "delete": { "security": [ { "BearerAuth": [] } ], "description": "Deletes a branch-user assignment", "produces": [ "application/json" ], "tags": [ "auth" ], "summary": "Remove user from branch", "parameters": [ { "type": "integer", "description": "Branch-user ID", "name": "id", "in": "path", "required": true } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "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" } } } } }, "/branches": { "get": { "security": [ { "BearerAuth": [] } ], "description": "Returns paginated branches with optional filters", "produces": [ "application/json" ], "tags": [ "branches" ], "summary": "List branches", "parameters": [ { "type": "integer", "description": "Filter by province ID", "name": "province_id", "in": "query" }, { "type": "string", "description": "Filter by province name (en, ru, tm)", "name": "province_name", "in": "query" }, { "type": "string", "description": "Filter by branch name (en, ru, tm)", "name": "branch_name", "in": "query" }, { "type": "string", "description": "Filter by unique code", "name": "unique_code", "in": "query" }, { "type": "integer", "default": 1, "description": "Page number", "name": "page", "in": "query" }, { "type": "integer", "default": 10, "description": "Items per page", "name": "limit", "in": "query" } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "400": { "description": "Bad Request", "schema": { "$ref": "#/definitions/appresult.AppError" } }, "500": { "description": "Internal Server Error", "schema": { "$ref": "#/definitions/appresult.AppError" } } } }, "post": { "security": [ { "BearerAuth": [] } ], "description": "Creates a new branch", "consumes": [ "application/json" ], "produces": [ "application/json" ], "tags": [ "branches" ], "summary": "Create branch", "parameters": [ { "description": "Branch payload", "name": "body", "in": "body", "required": true, "schema": { "$ref": "#/definitions/branches.CreateBranchDTO" } } ], "responses": { "201": { "description": "Created", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "400": { "description": "Bad Request", "schema": { "$ref": "#/definitions/appresult.AppError" } }, "500": { "description": "Internal Server Error", "schema": { "$ref": "#/definitions/appresult.AppError" } } } } }, "/branches/{id}": { "get": { "security": [ { "BearerAuth": [] } ], "description": "Returns a single branch", "produces": [ "application/json" ], "tags": [ "branches" ], "summary": "Get branch by ID", "parameters": [ { "type": "integer", "description": "Branch ID", "name": "id", "in": "path", "required": true } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "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" } } } }, "put": { "security": [ { "BearerAuth": [] } ], "description": "Updates an existing branch", "consumes": [ "application/json" ], "produces": [ "application/json" ], "tags": [ "branches" ], "summary": "Update branch", "parameters": [ { "type": "integer", "description": "Branch ID", "name": "id", "in": "path", "required": true }, { "description": "Branch payload", "name": "body", "in": "body", "required": true, "schema": { "$ref": "#/definitions/branches.UpdateBranchDTO" } } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "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" } } } }, "delete": { "security": [ { "BearerAuth": [] } ], "description": "Deletes a branch", "produces": [ "application/json" ], "tags": [ "branches" ], "summary": "Delete branch", "parameters": [ { "type": "integer", "description": "Branch ID", "name": "id", "in": "path", "required": true } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "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" } } } } }, "/card-orders": { "get": { "security": [ { "BearerAuth": [] } ], "description": "Returns paginated card orders with optional filters", "produces": [ "application/json" ], "tags": [ "card-orders" ], "summary": "List card orders", "parameters": [ { "type": "string", "description": "Filter by status", "name": "status", "in": "query" }, { "type": "integer", "description": "Filter by branch ID", "name": "branch_id", "in": "query" }, { "type": "integer", "description": "Filter by user ID", "name": "user_id", "in": "query" }, { "type": "integer", "description": "Filter by card state ID", "name": "card_state_id", "in": "query" }, { "type": "integer", "description": "Filter by card type ID", "name": "card_type_id", "in": "query" }, { "type": "string", "description": "Filter by region", "name": "region", "in": "query" }, { "type": "integer", "default": 1, "description": "Page number", "name": "page", "in": "query" }, { "type": "integer", "default": 10, "description": "Items per page", "name": "limit", "in": "query" } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "400": { "description": "Bad Request", "schema": { "$ref": "#/definitions/appresult.AppError" } }, "500": { "description": "Internal Server Error", "schema": { "$ref": "#/definitions/appresult.AppError" } } } }, "post": { "security": [ { "BearerAuth": [] } ], "description": "Creates a new card order", "consumes": [ "application/json" ], "produces": [ "application/json" ], "tags": [ "card-orders" ], "summary": "Create card order", "parameters": [ { "description": "Card order payload", "name": "body", "in": "body", "required": true, "schema": { "$ref": "#/definitions/cardorder.CreateCardOrderDTO" } } ], "responses": { "201": { "description": "Created", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "400": { "description": "Bad Request", "schema": { "$ref": "#/definitions/appresult.AppError" } }, "500": { "description": "Internal Server Error", "schema": { "$ref": "#/definitions/appresult.AppError" } } } } }, "/card-orders/{id}": { "get": { "security": [ { "BearerAuth": [] } ], "description": "Returns a single card order", "produces": [ "application/json" ], "tags": [ "card-orders" ], "summary": "Get card order by ID", "parameters": [ { "type": "integer", "description": "Card order ID", "name": "id", "in": "path", "required": true } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "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" } } } }, "put": { "security": [ { "BearerAuth": [] } ], "description": "Updates an existing card order", "consumes": [ "application/json" ], "produces": [ "application/json" ], "tags": [ "card-orders" ], "summary": "Update card order", "parameters": [ { "type": "integer", "description": "Card order ID", "name": "id", "in": "path", "required": true }, { "description": "Card order payload", "name": "body", "in": "body", "required": true, "schema": { "$ref": "#/definitions/cardorder.UpdateCardOrderDTO" } } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "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" } } } }, "delete": { "security": [ { "BearerAuth": [] } ], "description": "Deletes a card order", "produces": [ "application/json" ], "tags": [ "card-orders" ], "summary": "Delete card order", "parameters": [ { "type": "integer", "description": "Card order ID", "name": "id", "in": "path", "required": true } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "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" } } } } }, "/cards": { "get": { "security": [ { "BearerAuth": [] } ], "description": "Returns paginated cards with optional filters", "produces": [ "application/json" ], "tags": [ "cards" ], "summary": "List cards", "parameters": [ { "type": "integer", "description": "Filter by user ID", "name": "user_id", "in": "query" }, { "type": "string", "description": "Filter by card type", "name": "type", "in": "query" }, { "type": "integer", "default": 1, "description": "Page number", "name": "page", "in": "query" }, { "type": "integer", "default": 10, "description": "Items per page", "name": "limit", "in": "query" } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "400": { "description": "Bad Request", "schema": { "$ref": "#/definitions/appresult.AppError" } }, "500": { "description": "Internal Server Error", "schema": { "$ref": "#/definitions/appresult.AppError" } } } }, "post": { "security": [ { "BearerAuth": [] } ], "description": "Creates a new card", "consumes": [ "application/json" ], "produces": [ "application/json" ], "tags": [ "cards" ], "summary": "Create card", "parameters": [ { "description": "Card payload", "name": "body", "in": "body", "required": true, "schema": { "$ref": "#/definitions/cards.CreateCardDTO" } } ], "responses": { "201": { "description": "Created", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "400": { "description": "Bad Request", "schema": { "$ref": "#/definitions/appresult.AppError" } }, "500": { "description": "Internal Server Error", "schema": { "$ref": "#/definitions/appresult.AppError" } } } } }, "/cards/{id}": { "get": { "security": [ { "BearerAuth": [] } ], "description": "Returns a single card", "produces": [ "application/json" ], "tags": [ "cards" ], "summary": "Get card by ID", "parameters": [ { "type": "integer", "description": "Card ID", "name": "id", "in": "path", "required": true } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "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" } } } }, "put": { "security": [ { "BearerAuth": [] } ], "description": "Updates an existing card", "consumes": [ "application/json" ], "produces": [ "application/json" ], "tags": [ "cards" ], "summary": "Update card", "parameters": [ { "type": "integer", "description": "Card ID", "name": "id", "in": "path", "required": true }, { "description": "Card payload", "name": "body", "in": "body", "required": true, "schema": { "$ref": "#/definitions/cards.UpdateCardDTO" } } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "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" } } } }, "delete": { "security": [ { "BearerAuth": [] } ], "description": "Deletes a card", "produces": [ "application/json" ], "tags": [ "cards" ], "summary": "Delete card", "parameters": [ { "type": "integer", "description": "Card ID", "name": "id", "in": "path", "required": true } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "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" } } } } }, "/file": { "post": { "security": [ { "BearerAuth": [] } ], "description": "file upload", "consumes": [ "multipart/form-data" ], "produces": [ "application/json" ], "tags": [ "file-upload" ], "parameters": [ { "type": "file", "description": "this is a test file", "name": "file", "in": "formData", "required": true } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "400": { "description": "Bad Request", "schema": { "$ref": "#/definitions/appresult.AppError" } }, "500": { "description": "Internal Server Error", "schema": { "$ref": "#/definitions/appresult.AppError" } } } } }, "/file/{id}": { "get": { "security": [ { "BearerAuth": [] } ], "description": "download file", "produces": [ "application/octet-stream" ], "tags": [ "file-upload" ], "parameters": [ { "type": "string", "description": "object name", "name": "id", "in": "path", "required": true } ], "responses": { "200": { "description": "OK", "schema": { "type": "file" } }, "500": { "description": "Internal Server Error", "schema": { "$ref": "#/definitions/appresult.AppError" } } } }, "delete": { "security": [ { "BearerAuth": [] } ], "description": "remove file", "produces": [ "application/json" ], "tags": [ "file-upload" ], "parameters": [ { "type": "string", "description": "object name", "name": "id", "in": "path", "required": true } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "500": { "description": "Internal Server Error", "schema": { "$ref": "#/definitions/appresult.AppError" } } } } }, "/loan-orders": { "get": { "security": [ { "BearerAuth": [] } ], "description": "Returns paginated loan orders with optional filters", "produces": [ "application/json" ], "tags": [ "loan-orders" ], "summary": "List loan orders", "parameters": [ { "type": "string", "description": "Filter by status", "name": "status", "in": "query" }, { "type": "integer", "description": "Filter by branch ID", "name": "branch_id", "in": "query" }, { "type": "integer", "description": "Filter by user ID", "name": "user_id", "in": "query" }, { "type": "string", "description": "Filter by region", "name": "region", "in": "query" }, { "type": "integer", "default": 1, "description": "Page number", "name": "page", "in": "query" }, { "type": "integer", "default": 10, "description": "Items per page", "name": "limit", "in": "query" } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "400": { "description": "Bad Request", "schema": { "$ref": "#/definitions/appresult.AppError" } }, "500": { "description": "Internal Server Error", "schema": { "$ref": "#/definitions/appresult.AppError" } } } }, "post": { "security": [ { "BearerAuth": [] } ], "description": "Creates a new loan order", "consumes": [ "application/json" ], "produces": [ "application/json" ], "tags": [ "loan-orders" ], "summary": "Create loan order", "parameters": [ { "description": "Loan order payload", "name": "body", "in": "body", "required": true, "schema": { "$ref": "#/definitions/loanorders.CreateLoanOrderDTO" } } ], "responses": { "201": { "description": "Created", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "400": { "description": "Bad Request", "schema": { "$ref": "#/definitions/appresult.AppError" } }, "500": { "description": "Internal Server Error", "schema": { "$ref": "#/definitions/appresult.AppError" } } } } }, "/loan-orders/{id}": { "get": { "security": [ { "BearerAuth": [] } ], "description": "Returns a single loan order", "produces": [ "application/json" ], "tags": [ "loan-orders" ], "summary": "Get loan order by ID", "parameters": [ { "type": "integer", "description": "Loan order ID", "name": "id", "in": "path", "required": true } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "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" } } } }, "put": { "security": [ { "BearerAuth": [] } ], "description": "Updates an existing loan order", "consumes": [ "application/json" ], "produces": [ "application/json" ], "tags": [ "loan-orders" ], "summary": "Update loan order", "parameters": [ { "type": "integer", "description": "Loan order ID", "name": "id", "in": "path", "required": true }, { "description": "Loan order payload", "name": "body", "in": "body", "required": true, "schema": { "$ref": "#/definitions/loanorders.UpdateLoanOrderDTO" } } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "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" } } } }, "delete": { "security": [ { "BearerAuth": [] } ], "description": "Deletes a loan order", "produces": [ "application/json" ], "tags": [ "loan-orders" ], "summary": "Delete loan order", "parameters": [ { "type": "integer", "description": "Loan order ID", "name": "id", "in": "path", "required": true } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "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" } } } } }, "/loan-paid-off-letters": { "get": { "security": [ { "BearerAuth": [] } ], "description": "Returns paginated loan paid off letters with optional filters", "produces": [ "application/json" ], "tags": [ "loan-paid-off-letters" ], "summary": "List loan paid off letters", "parameters": [ { "type": "string", "description": "Filter by passport ID", "name": "passport_id", "in": "query" }, { "type": "string", "description": "Filter by status", "name": "status", "in": "query" }, { "type": "integer", "description": "Filter by branch ID", "name": "branch_id", "in": "query" }, { "type": "string", "description": "Filter by region", "name": "region", "in": "query" }, { "type": "integer", "default": 1, "description": "Page number", "name": "page", "in": "query" }, { "type": "integer", "default": 10, "description": "Items per page", "name": "limit", "in": "query" } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "400": { "description": "Bad Request", "schema": { "$ref": "#/definitions/appresult.AppError" } }, "500": { "description": "Internal Server Error", "schema": { "$ref": "#/definitions/appresult.AppError" } } } }, "post": { "security": [ { "BearerAuth": [] } ], "description": "Creates a new loan paid off letter", "consumes": [ "application/json" ], "produces": [ "application/json" ], "tags": [ "loan-paid-off-letters" ], "summary": "Create loan paid off letter", "parameters": [ { "description": "Loan paid off letter payload", "name": "body", "in": "body", "required": true, "schema": { "$ref": "#/definitions/loanpaidletter.CreateLoanPaidLetterDTO" } } ], "responses": { "201": { "description": "Created", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "400": { "description": "Bad Request", "schema": { "$ref": "#/definitions/appresult.AppError" } }, "500": { "description": "Internal Server Error", "schema": { "$ref": "#/definitions/appresult.AppError" } } } } }, "/loan-paid-off-letters/{id}": { "get": { "security": [ { "BearerAuth": [] } ], "description": "Returns a single loan paid off letter", "produces": [ "application/json" ], "tags": [ "loan-paid-off-letters" ], "summary": "Get loan paid off letter by ID", "parameters": [ { "type": "integer", "description": "Loan paid off letter ID", "name": "id", "in": "path", "required": true } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "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" } } } }, "put": { "security": [ { "BearerAuth": [] } ], "description": "Updates an existing loan paid off letter", "consumes": [ "application/json" ], "produces": [ "application/json" ], "tags": [ "loan-paid-off-letters" ], "summary": "Update loan paid off letter", "parameters": [ { "type": "integer", "description": "Loan paid off letter ID", "name": "id", "in": "path", "required": true }, { "description": "Loan paid off letter payload", "name": "body", "in": "body", "required": true, "schema": { "$ref": "#/definitions/loanpaidletter.UpdateLoanPaidLetterDTO" } } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "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" } } } }, "delete": { "security": [ { "BearerAuth": [] } ], "description": "Deletes a loan paid off letter", "produces": [ "application/json" ], "tags": [ "loan-paid-off-letters" ], "summary": "Delete loan paid off letter", "parameters": [ { "type": "integer", "description": "Loan paid off letter ID", "name": "id", "in": "path", "required": true } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "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" } } } } }, "/loan-types": { "get": { "security": [ { "BearerAuth": [] } ], "description": "Returns paginated loan types with optional filters", "produces": [ "application/json" ], "tags": [ "loan-type" ], "summary": "List loan types", "parameters": [ { "type": "string", "description": "Filter by title (en, ru, tm)", "name": "loan_type_name", "in": "query" }, { "type": "integer", "default": 1, "description": "Page number", "name": "page", "in": "query" }, { "type": "integer", "default": 10, "description": "Items per page", "name": "limit", "in": "query" } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "400": { "description": "Bad Request", "schema": { "$ref": "#/definitions/appresult.AppError" } }, "500": { "description": "Internal Server Error", "schema": { "$ref": "#/definitions/appresult.AppError" } } } }, "post": { "security": [ { "BearerAuth": [] } ], "description": "Creates a new loan type", "consumes": [ "application/json" ], "produces": [ "application/json" ], "tags": [ "loan-type" ], "summary": "Create loan type", "parameters": [ { "description": "Loan type payload", "name": "body", "in": "body", "required": true, "schema": { "$ref": "#/definitions/loantype.CreateLoanTypeDTO" } } ], "responses": { "201": { "description": "Created", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "400": { "description": "Bad Request", "schema": { "$ref": "#/definitions/appresult.AppError" } }, "500": { "description": "Internal Server Error", "schema": { "$ref": "#/definitions/appresult.AppError" } } } } }, "/loan-types/{id}": { "get": { "security": [ { "BearerAuth": [] } ], "description": "Returns a single loan type", "produces": [ "application/json" ], "tags": [ "loan-type" ], "summary": "Get loan type by ID", "parameters": [ { "type": "integer", "description": "Loan type ID", "name": "id", "in": "path", "required": true } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "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" } } } }, "put": { "security": [ { "BearerAuth": [] } ], "description": "Updates an existing loan type", "consumes": [ "application/json" ], "produces": [ "application/json" ], "tags": [ "loan-type" ], "summary": "Update loan type", "parameters": [ { "type": "integer", "description": "Loan type ID", "name": "id", "in": "path", "required": true }, { "description": "Loan type payload", "name": "body", "in": "body", "required": true, "schema": { "$ref": "#/definitions/loantype.UpdateLoanTypeDTO" } } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "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" } } } }, "delete": { "security": [ { "BearerAuth": [] } ], "description": "Deletes a loan type", "produces": [ "application/json" ], "tags": [ "loan-type" ], "summary": "Delete loan type", "parameters": [ { "type": "integer", "description": "Loan type ID", "name": "id", "in": "path", "required": true } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "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" } } } } }, "/loans-documents": { "get": { "security": [ { "BearerAuth": [] } ], "description": "Returns paginated loan documents with optional filters", "produces": [ "application/json" ], "tags": [ "loan-document" ], "summary": "List loan documents", "parameters": [ { "type": "string", "description": "Filter by name", "name": "document_name", "in": "query" }, { "type": "boolean", "description": "Filter by active", "name": "active", "in": "query" }, { "type": "integer", "default": 1, "description": "Page number", "name": "page", "in": "query" }, { "type": "integer", "default": 10, "description": "Items per page", "name": "limit", "in": "query" } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "400": { "description": "Bad Request", "schema": { "$ref": "#/definitions/appresult.AppError" } }, "500": { "description": "Internal Server Error", "schema": { "$ref": "#/definitions/appresult.AppError" } } } }, "post": { "security": [ { "BearerAuth": [] } ], "description": "Creates a new loan document", "consumes": [ "application/json" ], "produces": [ "application/json" ], "tags": [ "loan-document" ], "summary": "Create loan document", "parameters": [ { "description": "Loan document payload", "name": "body", "in": "body", "required": true, "schema": { "$ref": "#/definitions/loansdocument.CreateLoanDocumentDTO" } } ], "responses": { "201": { "description": "Created", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "400": { "description": "Bad Request", "schema": { "$ref": "#/definitions/appresult.AppError" } }, "500": { "description": "Internal Server Error", "schema": { "$ref": "#/definitions/appresult.AppError" } } } } }, "/loans-documents/{id}": { "get": { "security": [ { "BearerAuth": [] } ], "description": "Returns a single loan document", "produces": [ "application/json" ], "tags": [ "loan-document" ], "summary": "Get loan document by ID", "parameters": [ { "type": "integer", "description": "Loan document ID", "name": "id", "in": "path", "required": true } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "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" } } } }, "put": { "security": [ { "BearerAuth": [] } ], "description": "Updates an existing loan document", "consumes": [ "application/json" ], "produces": [ "application/json" ], "tags": [ "loan-document" ], "summary": "Update loan document", "parameters": [ { "type": "integer", "description": "Loan document ID", "name": "id", "in": "path", "required": true }, { "description": "Loan document payload", "name": "body", "in": "body", "required": true, "schema": { "$ref": "#/definitions/loansdocument.UpdateLoanDocumentDTO" } } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "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" } } } }, "delete": { "security": [ { "BearerAuth": [] } ], "description": "Deletes a loan document", "produces": [ "application/json" ], "tags": [ "loan-document" ], "summary": "Delete loan document", "parameters": [ { "type": "integer", "description": "Loan document ID", "name": "id", "in": "path", "required": true } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "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" } } } } }, "/loans-documents/{id}/active": { "put": { "security": [ { "BearerAuth": [] } ], "description": "Enables or disables a loan document", "consumes": [ "application/json" ], "produces": [ "application/json" ], "tags": [ "loan-document" ], "summary": "Update loan document active", "parameters": [ { "type": "integer", "description": "Loan document ID", "name": "id", "in": "path", "required": true }, { "description": "Active payload", "name": "body", "in": "body", "required": true, "schema": { "$ref": "#/definitions/loansdocument.UpdateLoanDocumentActiveDTO" } } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "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" } } } } }, "/loans-repayment": { "get": { "security": [ { "BearerAuth": [] } ], "description": "Returns paginated loan repayments with optional filters", "produces": [ "application/json" ], "tags": [ "loans-repayment" ], "summary": "List loan repayments", "parameters": [ { "type": "string", "description": "Filter by passport ID", "name": "passport_id", "in": "query" }, { "type": "integer", "default": 1, "description": "Page number", "name": "page", "in": "query" }, { "type": "integer", "default": 10, "description": "Items per page", "name": "limit", "in": "query" } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "400": { "description": "Bad Request", "schema": { "$ref": "#/definitions/appresult.AppError" } }, "500": { "description": "Internal Server Error", "schema": { "$ref": "#/definitions/appresult.AppError" } } } }, "post": { "security": [ { "BearerAuth": [] } ], "description": "Creates a new loan repayment record", "consumes": [ "application/json" ], "produces": [ "application/json" ], "tags": [ "loans-repayment" ], "summary": "Create loan repayment", "parameters": [ { "description": "Loan repayment payload", "name": "body", "in": "body", "required": true, "schema": { "$ref": "#/definitions/loansrepayment.CreateLoanRepaymentDTO" } } ], "responses": { "201": { "description": "Created", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "400": { "description": "Bad Request", "schema": { "$ref": "#/definitions/appresult.AppError" } }, "500": { "description": "Internal Server Error", "schema": { "$ref": "#/definitions/appresult.AppError" } } } } }, "/loans-repayment/{id}": { "get": { "security": [ { "BearerAuth": [] } ], "description": "Returns a single loan repayment", "produces": [ "application/json" ], "tags": [ "loans-repayment" ], "summary": "Get loan repayment by ID", "parameters": [ { "type": "integer", "description": "Loan repayment ID", "name": "id", "in": "path", "required": true } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "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" } } } }, "put": { "security": [ { "BearerAuth": [] } ], "description": "Updates an existing loan repayment record", "consumes": [ "application/json" ], "produces": [ "application/json" ], "tags": [ "loans-repayment" ], "summary": "Update loan repayment", "parameters": [ { "type": "integer", "description": "Loan repayment ID", "name": "id", "in": "path", "required": true }, { "description": "Loan repayment payload", "name": "body", "in": "body", "required": true, "schema": { "$ref": "#/definitions/loansrepayment.UpdateLoanRepaymentDTO" } } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "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" } } } }, "delete": { "security": [ { "BearerAuth": [] } ], "description": "Deletes a loan repayment record", "produces": [ "application/json" ], "tags": [ "loans-repayment" ], "summary": "Delete loan repayment", "parameters": [ { "type": "integer", "description": "Loan repayment ID", "name": "id", "in": "path", "required": true } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "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" } } } } }, "/login": { "post": { "description": "Authenticates a user by email and password", "consumes": [ "application/json" ], "produces": [ "application/json" ], "tags": [ "auth" ], "summary": "Login", "parameters": [ { "description": "Login payload", "name": "body", "in": "body", "required": true, "schema": { "$ref": "#/definitions/auth.LoginDTO" } } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "400": { "description": "Bad Request", "schema": { "$ref": "#/definitions/appresult.AppError" } }, "401": { "description": "Unauthorized", "schema": { "$ref": "#/definitions/appresult.AppError" } } } } }, "/payment-cards": { "get": { "security": [ { "BearerAuth": [] } ], "description": "Returns paginated payment cards with optional filters", "produces": [ "application/json" ], "tags": [ "payment-card" ], "summary": "List payment cards", "parameters": [ { "type": "string", "description": "Filter by card title (en, ru, tm)", "name": "card_name", "in": "query" }, { "type": "boolean", "description": "Filter by active", "name": "active", "in": "query" }, { "type": "integer", "default": 1, "description": "Page number", "name": "page", "in": "query" }, { "type": "integer", "default": 10, "description": "Items per page", "name": "limit", "in": "query" } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "400": { "description": "Bad Request", "schema": { "$ref": "#/definitions/appresult.AppError" } }, "500": { "description": "Internal Server Error", "schema": { "$ref": "#/definitions/appresult.AppError" } } } }, "post": { "security": [ { "BearerAuth": [] } ], "description": "Creates a new payment card", "consumes": [ "application/json" ], "produces": [ "application/json" ], "tags": [ "payment-card" ], "summary": "Create payment card", "parameters": [ { "description": "Payment card payload", "name": "body", "in": "body", "required": true, "schema": { "$ref": "#/definitions/paymentcard.CreatePaymentCardDTO" } } ], "responses": { "201": { "description": "Created", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "400": { "description": "Bad Request", "schema": { "$ref": "#/definitions/appresult.AppError" } }, "500": { "description": "Internal Server Error", "schema": { "$ref": "#/definitions/appresult.AppError" } } } } }, "/payment-cards/{id}": { "get": { "security": [ { "BearerAuth": [] } ], "description": "Returns a single payment card", "produces": [ "application/json" ], "tags": [ "payment-card" ], "summary": "Get payment card by ID", "parameters": [ { "type": "integer", "description": "Payment card ID", "name": "id", "in": "path", "required": true } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "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" } } } }, "put": { "security": [ { "BearerAuth": [] } ], "description": "Updates an existing payment card", "consumes": [ "application/json" ], "produces": [ "application/json" ], "tags": [ "payment-card" ], "summary": "Update payment card", "parameters": [ { "type": "integer", "description": "Payment card ID", "name": "id", "in": "path", "required": true }, { "description": "Payment card payload", "name": "body", "in": "body", "required": true, "schema": { "$ref": "#/definitions/paymentcard.UpdatePaymentCardDTO" } } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "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" } } } }, "delete": { "security": [ { "BearerAuth": [] } ], "description": "Deletes a payment card", "produces": [ "application/json" ], "tags": [ "payment-card" ], "summary": "Delete payment card", "parameters": [ { "type": "integer", "description": "Payment card ID", "name": "id", "in": "path", "required": true } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "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" } } } } }, "/payment-cards/{id}/active": { "put": { "security": [ { "BearerAuth": [] } ], "description": "Enables or disables a payment card", "consumes": [ "application/json" ], "produces": [ "application/json" ], "tags": [ "payment-card" ], "summary": "Update payment card active", "parameters": [ { "type": "integer", "description": "Payment card ID", "name": "id", "in": "path", "required": true }, { "description": "Active payload", "name": "body", "in": "body", "required": true, "schema": { "$ref": "#/definitions/paymentcard.UpdatePaymentCardActiveDTO" } } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "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" } } } } }, "/permissions": { "get": { "security": [ { "BearerAuth": [] } ], "description": "Returns paginated permissions with optional filters", "produces": [ "application/json" ], "tags": [ "permission" ], "summary": "List permissions", "parameters": [ { "type": "string", "description": "Filter by name", "name": "permission_name", "in": "query" }, { "type": "integer", "default": 1, "description": "Page number", "name": "page", "in": "query" }, { "type": "integer", "default": 10, "description": "Items per page", "name": "limit", "in": "query" } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "400": { "description": "Bad Request", "schema": { "$ref": "#/definitions/appresult.AppError" } }, "500": { "description": "Internal Server Error", "schema": { "$ref": "#/definitions/appresult.AppError" } } } }, "post": { "security": [ { "BearerAuth": [] } ], "description": "Creates a new permission", "consumes": [ "application/json" ], "produces": [ "application/json" ], "tags": [ "permission" ], "summary": "Create permission", "parameters": [ { "description": "Permission payload", "name": "body", "in": "body", "required": true, "schema": { "$ref": "#/definitions/permission.CreatePermissionDTO" } } ], "responses": { "201": { "description": "Created", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "400": { "description": "Bad Request", "schema": { "$ref": "#/definitions/appresult.AppError" } }, "500": { "description": "Internal Server Error", "schema": { "$ref": "#/definitions/appresult.AppError" } } } } }, "/permissions/{id}": { "get": { "security": [ { "BearerAuth": [] } ], "description": "Returns a single permission", "produces": [ "application/json" ], "tags": [ "permission" ], "summary": "Get permission by ID", "parameters": [ { "type": "integer", "description": "Permission ID", "name": "id", "in": "path", "required": true } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "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" } } } }, "put": { "security": [ { "BearerAuth": [] } ], "description": "Updates an existing permission", "consumes": [ "application/json" ], "produces": [ "application/json" ], "tags": [ "permission" ], "summary": "Update permission", "parameters": [ { "type": "integer", "description": "Permission ID", "name": "id", "in": "path", "required": true }, { "description": "Permission payload", "name": "body", "in": "body", "required": true, "schema": { "$ref": "#/definitions/permission.UpdatePermissionDTO" } } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "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" } } } }, "delete": { "security": [ { "BearerAuth": [] } ], "description": "Deletes a permission", "produces": [ "application/json" ], "tags": [ "permission" ], "summary": "Delete permission", "parameters": [ { "type": "integer", "description": "Permission ID", "name": "id", "in": "path", "required": true } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "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" } } } } }, "/profile": { "get": { "security": [ { "BearerAuth": [] } ], "description": "Returns the authenticated user's profile", "produces": [ "application/json" ], "tags": [ "auth" ], "summary": "Get profile", "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "400": { "description": "Bad Request", "schema": { "$ref": "#/definitions/appresult.AppError" } }, "401": { "description": "Unauthorized", "schema": { "$ref": "#/definitions/appresult.AppError" } }, "404": { "description": "Not Found", "schema": { "$ref": "#/definitions/appresult.AppError" } } } } }, "/provinces": { "get": { "security": [ { "BearerAuth": [] } ], "description": "Returns all provinces", "produces": [ "application/json" ], "tags": [ "province" ], "summary": "List provinces", "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "400": { "description": "Bad Request", "schema": { "$ref": "#/definitions/appresult.AppError" } }, "500": { "description": "Internal Server Error", "schema": { "$ref": "#/definitions/appresult.AppError" } } } }, "post": { "security": [ { "BearerAuth": [] } ], "description": "Creates a new province", "consumes": [ "application/json" ], "produces": [ "application/json" ], "tags": [ "province" ], "summary": "Create province", "parameters": [ { "description": "Province payload", "name": "body", "in": "body", "required": true, "schema": { "$ref": "#/definitions/province.CreateProvinceDTO" } } ], "responses": { "201": { "description": "Created", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "400": { "description": "Bad Request", "schema": { "$ref": "#/definitions/appresult.AppError" } }, "500": { "description": "Internal Server Error", "schema": { "$ref": "#/definitions/appresult.AppError" } } } } }, "/provinces/{id}": { "get": { "security": [ { "BearerAuth": [] } ], "description": "Returns a single province", "produces": [ "application/json" ], "tags": [ "province" ], "summary": "Get province by ID", "parameters": [ { "type": "integer", "description": "Province ID", "name": "id", "in": "path", "required": true } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "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" } } } }, "put": { "security": [ { "BearerAuth": [] } ], "description": "Updates an existing province", "consumes": [ "application/json" ], "produces": [ "application/json" ], "tags": [ "province" ], "summary": "Update province", "parameters": [ { "type": "integer", "description": "Province ID", "name": "id", "in": "path", "required": true }, { "description": "Province payload", "name": "body", "in": "body", "required": true, "schema": { "$ref": "#/definitions/province.UpdateProvinceDTO" } } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "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" } } } }, "delete": { "security": [ { "BearerAuth": [] } ], "description": "Deletes a province", "produces": [ "application/json" ], "tags": [ "province" ], "summary": "Delete province", "parameters": [ { "type": "integer", "description": "Province ID", "name": "id", "in": "path", "required": true } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "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" } } } } }, "/reasons-cards": { "get": { "security": [ { "BearerAuth": [] } ], "description": "Returns paginated reason cards with optional filters", "produces": [ "application/json" ], "tags": [ "reason-card" ], "summary": "List reason cards", "parameters": [ { "type": "string", "description": "Filter by title (en, ru, tm)", "name": "reason_name", "in": "query" }, { "type": "integer", "default": 1, "description": "Page number", "name": "page", "in": "query" }, { "type": "integer", "default": 10, "description": "Items per page", "name": "limit", "in": "query" } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "400": { "description": "Bad Request", "schema": { "$ref": "#/definitions/appresult.AppError" } }, "500": { "description": "Internal Server Error", "schema": { "$ref": "#/definitions/appresult.AppError" } } } }, "post": { "security": [ { "BearerAuth": [] } ], "description": "Creates a new reason card", "consumes": [ "application/json" ], "produces": [ "application/json" ], "tags": [ "reason-card" ], "summary": "Create reason card", "parameters": [ { "description": "Reason card payload", "name": "body", "in": "body", "required": true, "schema": { "$ref": "#/definitions/reasonscard.CreateReasonCardDTO" } } ], "responses": { "201": { "description": "Created", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "400": { "description": "Bad Request", "schema": { "$ref": "#/definitions/appresult.AppError" } }, "500": { "description": "Internal Server Error", "schema": { "$ref": "#/definitions/appresult.AppError" } } } } }, "/reasons-cards/{id}": { "get": { "security": [ { "BearerAuth": [] } ], "description": "Returns a single reason card", "produces": [ "application/json" ], "tags": [ "reason-card" ], "summary": "Get reason card by ID", "parameters": [ { "type": "integer", "description": "Reason card ID", "name": "id", "in": "path", "required": true } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "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" } } } }, "put": { "security": [ { "BearerAuth": [] } ], "description": "Updates an existing reason card", "consumes": [ "application/json" ], "produces": [ "application/json" ], "tags": [ "reason-card" ], "summary": "Update reason card", "parameters": [ { "type": "integer", "description": "Reason card ID", "name": "id", "in": "path", "required": true }, { "description": "Reason card payload", "name": "body", "in": "body", "required": true, "schema": { "$ref": "#/definitions/reasonscard.UpdateReasonCardDTO" } } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "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" } } } }, "delete": { "security": [ { "BearerAuth": [] } ], "description": "Deletes a reason card", "produces": [ "application/json" ], "tags": [ "reason-card" ], "summary": "Delete reason card", "parameters": [ { "type": "integer", "description": "Reason card ID", "name": "id", "in": "path", "required": true } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "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" } } } } }, "/roles": { "get": { "security": [ { "BearerAuth": [] } ], "description": "Returns paginated roles with optional filters", "produces": [ "application/json" ], "tags": [ "role" ], "summary": "List roles", "parameters": [ { "type": "string", "description": "Filter by name", "name": "role_name", "in": "query" }, { "type": "integer", "default": 1, "description": "Page number", "name": "page", "in": "query" }, { "type": "integer", "default": 10, "description": "Items per page", "name": "limit", "in": "query" } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "400": { "description": "Bad Request", "schema": { "$ref": "#/definitions/appresult.AppError" } }, "500": { "description": "Internal Server Error", "schema": { "$ref": "#/definitions/appresult.AppError" } } } }, "post": { "security": [ { "BearerAuth": [] } ], "description": "Creates a new role", "consumes": [ "application/json" ], "produces": [ "application/json" ], "tags": [ "role" ], "summary": "Create role", "parameters": [ { "description": "Role payload", "name": "body", "in": "body", "required": true, "schema": { "$ref": "#/definitions/role.CreateRoleDTO" } } ], "responses": { "201": { "description": "Created", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "400": { "description": "Bad Request", "schema": { "$ref": "#/definitions/appresult.AppError" } }, "500": { "description": "Internal Server Error", "schema": { "$ref": "#/definitions/appresult.AppError" } } } } }, "/roles/{id}": { "get": { "security": [ { "BearerAuth": [] } ], "description": "Returns a single role", "produces": [ "application/json" ], "tags": [ "role" ], "summary": "Get role by ID", "parameters": [ { "type": "integer", "description": "Role ID", "name": "id", "in": "path", "required": true } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "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" } } } }, "put": { "security": [ { "BearerAuth": [] } ], "description": "Updates an existing role", "consumes": [ "application/json" ], "produces": [ "application/json" ], "tags": [ "role" ], "summary": "Update role", "parameters": [ { "type": "integer", "description": "Role ID", "name": "id", "in": "path", "required": true }, { "description": "Role payload", "name": "body", "in": "body", "required": true, "schema": { "$ref": "#/definitions/role.UpdateRoleDTO" } } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "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" } } } }, "delete": { "security": [ { "BearerAuth": [] } ], "description": "Deletes a role", "produces": [ "application/json" ], "tags": [ "role" ], "summary": "Delete role", "parameters": [ { "type": "integer", "description": "Role ID", "name": "id", "in": "path", "required": true } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "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" } } } } }, "/token": { "post": { "description": "Issues a new access and refresh token pair", "consumes": [ "application/json" ], "produces": [ "application/json" ], "tags": [ "auth" ], "summary": "Refresh tokens", "parameters": [ { "description": "Refresh token payload", "name": "body", "in": "body", "required": true, "schema": { "$ref": "#/definitions/auth.RefreshTokenDTO" } } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "400": { "description": "Bad Request", "schema": { "$ref": "#/definitions/appresult.AppError" } }, "401": { "description": "Unauthorized", "schema": { "$ref": "#/definitions/appresult.AppError" } } } } }, "/users": { "get": { "security": [ { "BearerAuth": [] } ], "description": "Returns paginated users with optional filters", "produces": [ "application/json" ], "tags": [ "user" ], "summary": "List users", "parameters": [ { "type": "string", "description": "Filter by username", "name": "username", "in": "query" }, { "type": "integer", "default": 1, "description": "Page number", "name": "page", "in": "query" }, { "type": "integer", "default": 10, "description": "Items per page", "name": "limit", "in": "query" } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "400": { "description": "Bad Request", "schema": { "$ref": "#/definitions/appresult.AppError" } }, "500": { "description": "Internal Server Error", "schema": { "$ref": "#/definitions/appresult.AppError" } } } }, "post": { "security": [ { "BearerAuth": [] } ], "description": "Creates a new user", "consumes": [ "application/json" ], "produces": [ "application/json" ], "tags": [ "user" ], "summary": "Create user", "parameters": [ { "description": "User payload", "name": "body", "in": "body", "required": true, "schema": { "$ref": "#/definitions/user.CreateUserDTO" } } ], "responses": { "201": { "description": "Created", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "400": { "description": "Bad Request", "schema": { "$ref": "#/definitions/appresult.AppError" } }, "500": { "description": "Internal Server Error", "schema": { "$ref": "#/definitions/appresult.AppError" } } } } }, "/users/{id}": { "get": { "security": [ { "BearerAuth": [] } ], "description": "Returns a single user", "produces": [ "application/json" ], "tags": [ "user" ], "summary": "Get user by ID", "parameters": [ { "type": "integer", "description": "User ID", "name": "id", "in": "path", "required": true } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "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" } } } }, "put": { "security": [ { "BearerAuth": [] } ], "description": "Updates an existing user", "consumes": [ "application/json" ], "produces": [ "application/json" ], "tags": [ "user" ], "summary": "Update user", "parameters": [ { "type": "integer", "description": "User ID", "name": "id", "in": "path", "required": true }, { "description": "User payload", "name": "body", "in": "body", "required": true, "schema": { "$ref": "#/definitions/user.UpdateUserDTO" } } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "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" } } } }, "delete": { "security": [ { "BearerAuth": [] } ], "description": "Deletes a user", "produces": [ "application/json" ], "tags": [ "user" ], "summary": "Delete user", "parameters": [ { "type": "integer", "description": "User ID", "name": "id", "in": "path", "required": true } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/appresult.AppSuccess" } }, "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" } } } } } }, "definitions": { "appresult.AppError": { "type": "object", "properties": { "code": { "type": "string" }, "message": { "type": "string" }, "status": { "type": "boolean" } } }, "appresult.AppSuccess": { "type": "object", "properties": { "code": { "type": "string" }, "data": {}, "message": { "type": "string" }, "status": { "type": "boolean" } } }, "auth.CreateBranchUserDTO": { "type": "object", "required": [ "branchId", "userId" ], "properties": { "branchId": { "type": "integer" }, "userId": { "type": "integer" } } }, "auth.LoginDTO": { "type": "object", "required": [ "email", "password" ], "properties": { "email": { "type": "string" }, "password": { "type": "string" } } }, "auth.RefreshTokenDTO": { "type": "object", "required": [ "refreshToken" ], "properties": { "refreshToken": { "type": "string" } } }, "branches.CreateBranchDTO": { "type": "object", "required": [ "address", "name", "region" ], "properties": { "active": { "type": "boolean" }, "address": { "$ref": "#/definitions/branches.LocalizedText" }, "billingPassword": { "type": "string" }, "billingSberPassword": { "type": "string" }, "billingSberUsername": { "type": "string" }, "billingSwiftPassword": { "type": "string" }, "billingSwiftUsername": { "type": "string" }, "billingUsername": { "type": "string" }, "billingVisaMasterPassword": { "type": "string" }, "billingVisaMasterUsername": { "type": "string" }, "name": { "$ref": "#/definitions/branches.LocalizedText" }, "phoneNumbers": { "type": "array", "items": { "type": "string" } }, "provinceId": { "type": "integer" }, "region": { "type": "string" }, "uniqueCode": { "type": "string" } } }, "branches.LocalizedText": { "type": "object", "properties": { "en": { "type": "string" }, "ru": { "type": "string" }, "tm": { "type": "string" } } }, "branches.UpdateBranchDTO": { "type": "object", "required": [ "address", "name", "region" ], "properties": { "active": { "type": "boolean" }, "address": { "$ref": "#/definitions/branches.LocalizedText" }, "billingPassword": { "type": "string" }, "billingSberPassword": { "type": "string" }, "billingSberUsername": { "type": "string" }, "billingSwiftPassword": { "type": "string" }, "billingSwiftUsername": { "type": "string" }, "billingUsername": { "type": "string" }, "billingVisaMasterPassword": { "type": "string" }, "billingVisaMasterUsername": { "type": "string" }, "name": { "$ref": "#/definitions/branches.LocalizedText" }, "phoneNumbers": { "type": "array", "items": { "type": "string" } }, "provinceId": { "type": "integer" }, "region": { "type": "string" }, "uniqueCode": { "type": "string" } } }, "cardorder.CreateCardOrderDTO": { "type": "object", "required": [ "bornPlace", "branchId", "cardStateId", "cardTypeId", "citizenship", "customerName", "customerSurname", "passportFour", "passportGivenAt", "passportGivenBy", "passportId", "passportOne", "passportSerie", "passportThree", "passportTwo", "region" ], "properties": { "bornAt": { "type": "string" }, "bornPlace": { "type": "string" }, "branchId": { "type": "integer" }, "cardStateId": { "type": "integer" }, "cardTypeId": { "type": "integer" }, "citizenship": { "type": "string" }, "customerName": { "type": "string" }, "customerPatronicName": { "type": "string" }, "customerSurname": { "type": "string" }, "jobLocation": { "type": "string" }, "notes": { "type": "string" }, "oldSurname": { "type": "string" }, "paid": { "type": "boolean" }, "passportAddress": { "type": "string" }, "passportFour": { "type": "string" }, "passportGivenAt": { "type": "string" }, "passportGivenBy": { "type": "string" }, "passportId": { "type": "string" }, "passportOne": { "type": "string" }, "passportSerie": { "type": "string" }, "passportThree": { "type": "string" }, "passportTwo": { "type": "string" }, "phone": { "type": "string" }, "phoneAdditional": { "type": "string" }, "realAddress": { "type": "string" }, "region": { "type": "string" }, "status": { "type": "string" }, "uniqueId": { "type": "string" }, "userId": { "type": "integer" } } }, "cardorder.UpdateCardOrderDTO": { "type": "object", "required": [ "bornPlace", "branchId", "cardStateId", "cardTypeId", "citizenship", "customerName", "customerSurname", "passportFour", "passportGivenAt", "passportGivenBy", "passportId", "passportOne", "passportSerie", "passportThree", "passportTwo", "region" ], "properties": { "bornAt": { "type": "string" }, "bornPlace": { "type": "string" }, "branchId": { "type": "integer" }, "cardStateId": { "type": "integer" }, "cardTypeId": { "type": "integer" }, "citizenship": { "type": "string" }, "customerName": { "type": "string" }, "customerPatronicName": { "type": "string" }, "customerSurname": { "type": "string" }, "jobLocation": { "type": "string" }, "notes": { "type": "string" }, "oldSurname": { "type": "string" }, "paid": { "type": "boolean" }, "passportAddress": { "type": "string" }, "passportFour": { "type": "string" }, "passportGivenAt": { "type": "string" }, "passportGivenBy": { "type": "string" }, "passportId": { "type": "string" }, "passportOne": { "type": "string" }, "passportSerie": { "type": "string" }, "passportThree": { "type": "string" }, "passportTwo": { "type": "string" }, "phone": { "type": "string" }, "phoneAdditional": { "type": "string" }, "realAddress": { "type": "string" }, "region": { "type": "string" }, "status": { "type": "string" }, "uniqueId": { "type": "string" }, "userId": { "type": "integer" } } }, "cards.CreateCardDTO": { "type": "object", "required": [ "month", "name", "number" ], "properties": { "month": { "type": "string" }, "name": { "type": "string" }, "number": { "type": "string" }, "type": { "type": "string" }, "userId": { "type": "integer" }, "year": { "type": "string" } } }, "cards.UpdateCardDTO": { "type": "object", "required": [ "month", "name", "number" ], "properties": { "month": { "type": "string" }, "name": { "type": "string" }, "number": { "type": "string" }, "type": { "type": "string" }, "userId": { "type": "integer" }, "year": { "type": "string" } } }, "loanorders.CreateLoanOrderDTO": { "type": "object", "required": [ "bornAt", "bornPlace", "branchId", "customerName", "customerSurname", "education", "loanType", "marriageStatus", "passportAddress", "passportFour", "passportGivenAt", "passportGivenBy", "passportId", "passportOne", "passportSerie", "passportThree", "passportTwo", "phone", "realAddress", "region" ], "properties": { "bornAt": { "type": "string" }, "bornPlace": { "type": "string" }, "branchId": { "type": "integer" }, "cardMonth": { "type": "string" }, "cardName": { "type": "string" }, "cardNumber": { "type": "string" }, "cardYear": { "type": "string" }, "customerName": { "type": "string" }, "customerPatronicName": { "type": "string" }, "customerSurname": { "type": "string" }, "education": { "type": "string" }, "email": { "type": "string" }, "guarantor2CardMonth": { "type": "string" }, "guarantor2CardName": { "type": "string" }, "guarantor2CardNumber": { "type": "string" }, "guarantor2CardYear": { "type": "string" }, "guarantor2Name": { "type": "string" }, "guarantor2Note": { "type": "string" }, "guarantor2PassportId": { "type": "string" }, "guarantor2PassportSerie": { "type": "string" }, "guarantor2PatronicName": { "type": "string" }, "guarantor2Surname": { "type": "string" }, "guarantorCardMonth": { "type": "string" }, "guarantorCardName": { "type": "string" }, "guarantorCardNumber": { "type": "string" }, "guarantorCardYear": { "type": "string" }, "guarantorName": { "type": "string" }, "guarantorNote": { "type": "string" }, "guarantorPassportId": { "type": "string" }, "guarantorPassportSerie": { "type": "string" }, "guarantorPatronicName": { "type": "string" }, "guarantorSurname": { "type": "string" }, "loanAmount": { "type": "string" }, "loanCardMonth": { "type": "string" }, "loanCardName": { "type": "string" }, "loanCardNumber": { "type": "string" }, "loanCardYear": { "type": "string" }, "loanOrderRequiredDocId": { "type": "integer" }, "loanType": { "type": "integer" }, "marriageStatus": { "type": "string" }, "notes": { "type": "string" }, "passportAddress": { "type": "string" }, "passportFour": { "type": "string" }, "passportGivenAt": { "type": "string" }, "passportGivenBy": { "type": "string" }, "passportId": { "type": "string" }, "passportOne": { "type": "string" }, "passportSerie": { "type": "string" }, "passportThree": { "type": "string" }, "passportTwo": { "type": "string" }, "phone": { "type": "string" }, "phoneAdditional": { "type": "string" }, "phoneHome": { "type": "string" }, "realAddress": { "type": "string" }, "region": { "type": "string" }, "satisfiable": { "type": "string" }, "source": { "type": "string" }, "status": { "type": "string" }, "uniqueId": { "type": "string" }, "userId": { "type": "integer" }, "workCompany": { "type": "string" }, "workCompanyAccountantNumber": { "type": "string" }, "workPosition": { "type": "string" }, "workProvinceId": { "type": "integer" }, "workRegion": { "type": "string" }, "workSalary": { "type": "string" }, "workStartedAt": { "type": "string" } } }, "loanorders.UpdateLoanOrderDTO": { "type": "object", "required": [ "bornAt", "bornPlace", "branchId", "customerName", "customerSurname", "education", "loanType", "marriageStatus", "passportAddress", "passportFour", "passportGivenAt", "passportGivenBy", "passportId", "passportOne", "passportSerie", "passportThree", "passportTwo", "phone", "realAddress", "region" ], "properties": { "bornAt": { "type": "string" }, "bornPlace": { "type": "string" }, "branchId": { "type": "integer" }, "cardMonth": { "type": "string" }, "cardName": { "type": "string" }, "cardNumber": { "type": "string" }, "cardYear": { "type": "string" }, "customerName": { "type": "string" }, "customerPatronicName": { "type": "string" }, "customerSurname": { "type": "string" }, "education": { "type": "string" }, "email": { "type": "string" }, "guarantor2CardMonth": { "type": "string" }, "guarantor2CardName": { "type": "string" }, "guarantor2CardNumber": { "type": "string" }, "guarantor2CardYear": { "type": "string" }, "guarantor2Name": { "type": "string" }, "guarantor2Note": { "type": "string" }, "guarantor2PassportId": { "type": "string" }, "guarantor2PassportSerie": { "type": "string" }, "guarantor2PatronicName": { "type": "string" }, "guarantor2Surname": { "type": "string" }, "guarantorCardMonth": { "type": "string" }, "guarantorCardName": { "type": "string" }, "guarantorCardNumber": { "type": "string" }, "guarantorCardYear": { "type": "string" }, "guarantorName": { "type": "string" }, "guarantorNote": { "type": "string" }, "guarantorPassportId": { "type": "string" }, "guarantorPassportSerie": { "type": "string" }, "guarantorPatronicName": { "type": "string" }, "guarantorSurname": { "type": "string" }, "loanAmount": { "type": "string" }, "loanCardMonth": { "type": "string" }, "loanCardName": { "type": "string" }, "loanCardNumber": { "type": "string" }, "loanCardYear": { "type": "string" }, "loanOrderRequiredDocId": { "type": "integer" }, "loanType": { "type": "integer" }, "marriageStatus": { "type": "string" }, "notes": { "type": "string" }, "passportAddress": { "type": "string" }, "passportFour": { "type": "string" }, "passportGivenAt": { "type": "string" }, "passportGivenBy": { "type": "string" }, "passportId": { "type": "string" }, "passportOne": { "type": "string" }, "passportSerie": { "type": "string" }, "passportThree": { "type": "string" }, "passportTwo": { "type": "string" }, "phone": { "type": "string" }, "phoneAdditional": { "type": "string" }, "phoneHome": { "type": "string" }, "realAddress": { "type": "string" }, "region": { "type": "string" }, "satisfiable": { "type": "string" }, "source": { "type": "string" }, "status": { "type": "string" }, "uniqueId": { "type": "string" }, "userId": { "type": "integer" }, "workCompany": { "type": "string" }, "workCompanyAccountantNumber": { "type": "string" }, "workPosition": { "type": "string" }, "workProvinceId": { "type": "integer" }, "workRegion": { "type": "string" }, "workSalary": { "type": "string" }, "workStartedAt": { "type": "string" } } }, "loanpaidletter.CreateLoanPaidLetterDTO": { "type": "object", "required": [ "branchId", "customerName", "customerSurname", "passportId", "passportSerie", "phone", "region" ], "properties": { "bornAt": { "type": "string" }, "branchId": { "type": "integer" }, "customerName": { "type": "string" }, "customerPatronicName": { "type": "string" }, "customerSurname": { "type": "string" }, "loanAmount": { "type": "string" }, "loanContractDate": { "type": "string" }, "loanContractNumber": { "type": "string" }, "loanFile": { "type": "string" }, "loanReason": { "type": "string" }, "notes": { "type": "string" }, "passportId": { "type": "string" }, "passportSerie": { "type": "string" }, "phone": { "type": "string" }, "region": { "type": "string" }, "status": { "type": "string" }, "uniqueId": { "type": "string" }, "userId": { "type": "integer" } } }, "loanpaidletter.UpdateLoanPaidLetterDTO": { "type": "object", "required": [ "branchId", "customerName", "customerSurname", "passportId", "passportSerie", "phone", "region" ], "properties": { "bornAt": { "type": "string" }, "branchId": { "type": "integer" }, "customerName": { "type": "string" }, "customerPatronicName": { "type": "string" }, "customerSurname": { "type": "string" }, "loanAmount": { "type": "string" }, "loanContractDate": { "type": "string" }, "loanContractNumber": { "type": "string" }, "loanFile": { "type": "string" }, "loanReason": { "type": "string" }, "notes": { "type": "string" }, "passportId": { "type": "string" }, "passportSerie": { "type": "string" }, "phone": { "type": "string" }, "region": { "type": "string" }, "status": { "type": "string" }, "uniqueId": { "type": "string" }, "userId": { "type": "integer" } } }, "loansdocument.CreateLoanDocumentDTO": { "type": "object", "required": [ "name", "value" ], "properties": { "active": { "type": "boolean" }, "name": { "type": "string" }, "value": { "type": "string" } } }, "loansdocument.UpdateLoanDocumentActiveDTO": { "type": "object", "properties": { "active": { "type": "boolean" } } }, "loansdocument.UpdateLoanDocumentDTO": { "type": "object", "required": [ "name", "value" ], "properties": { "active": { "type": "boolean" }, "name": { "type": "string" }, "value": { "type": "string" } } }, "loansrepayment.CreateLoanRepaymentDTO": { "type": "object", "required": [ "accountNumber", "passportId", "passportSerie", "userId" ], "properties": { "accountNumber": { "type": "string" }, "passportId": { "type": "string" }, "passportSerie": { "type": "string" }, "userId": { "type": "integer" } } }, "loansrepayment.UpdateLoanRepaymentDTO": { "type": "object", "required": [ "accountNumber", "passportId", "passportSerie", "userId" ], "properties": { "accountNumber": { "type": "string" }, "passportId": { "type": "string" }, "passportSerie": { "type": "string" }, "userId": { "type": "integer" } } }, "loantype.CreateLoanTypeDTO": { "type": "object", "required": [ "content", "loanTerm", "tax", "title" ], "properties": { "active": { "type": "boolean" }, "content": { "$ref": "#/definitions/loantype.LocalizedTitle" }, "loanTerm": { "type": "string" }, "tax": { "type": "number" }, "title": { "$ref": "#/definitions/loantype.LocalizedTitle" } } }, "loantype.LocalizedTitle": { "type": "object", "properties": { "en": { "type": "string" }, "ru": { "type": "string" }, "tm": { "type": "string" } } }, "loantype.UpdateLoanTypeDTO": { "type": "object", "required": [ "content", "loanTerm", "tax", "title" ], "properties": { "active": { "type": "boolean" }, "content": { "$ref": "#/definitions/loantype.LocalizedTitle" }, "loanTerm": { "type": "string" }, "tax": { "type": "number" }, "title": { "$ref": "#/definitions/loantype.LocalizedTitle" } } }, "paymentcard.CreatePaymentCardDTO": { "type": "object", "required": [ "price", "title" ], "properties": { "active": { "type": "boolean" }, "notes": { "type": "string" }, "price": { "type": "string" }, "title": { "$ref": "#/definitions/paymentcard.LocalizedText" } } }, "paymentcard.LocalizedText": { "type": "object", "properties": { "en": { "type": "string" }, "ru": { "type": "string" }, "tm": { "type": "string" } } }, "paymentcard.UpdatePaymentCardActiveDTO": { "type": "object", "properties": { "active": { "type": "boolean" } } }, "paymentcard.UpdatePaymentCardDTO": { "type": "object", "required": [ "price", "title" ], "properties": { "active": { "type": "boolean" }, "notes": { "type": "string" }, "price": { "type": "string" }, "title": { "$ref": "#/definitions/paymentcard.LocalizedText" } } }, "permission.CreatePermissionDTO": { "type": "object", "required": [ "code", "guardName", "name" ], "properties": { "code": { "type": "string" }, "guardName": { "type": "string" }, "name": { "type": "string" } } }, "permission.UpdatePermissionDTO": { "type": "object", "required": [ "code", "guardName", "name" ], "properties": { "code": { "type": "string" }, "guardName": { "type": "string" }, "name": { "type": "string" } } }, "province.CreateProvinceDTO": { "type": "object", "required": [ "name", "region" ], "properties": { "active": { "type": "boolean" }, "name": { "$ref": "#/definitions/province.LocalizedName" }, "region": { "$ref": "#/definitions/province.LocalizedName" } } }, "province.LocalizedName": { "type": "object", "properties": { "en": { "type": "string" }, "ru": { "type": "string" }, "tm": { "type": "string" } } }, "province.UpdateProvinceDTO": { "type": "object", "required": [ "name", "region" ], "properties": { "active": { "type": "boolean" }, "name": { "$ref": "#/definitions/province.LocalizedName" }, "region": { "$ref": "#/definitions/province.LocalizedName" } } }, "reasonscard.CreateReasonCardDTO": { "type": "object", "required": [ "price", "title" ], "properties": { "active": { "type": "boolean" }, "notes": { "type": "string" }, "price": { "type": "string" }, "title": { "$ref": "#/definitions/reasonscard.LocalizedText" } } }, "reasonscard.LocalizedText": { "type": "object", "properties": { "en": { "type": "string" }, "ru": { "type": "string" }, "tm": { "type": "string" } } }, "reasonscard.UpdateReasonCardDTO": { "type": "object", "required": [ "price", "title" ], "properties": { "active": { "type": "boolean" }, "notes": { "type": "string" }, "price": { "type": "string" }, "title": { "$ref": "#/definitions/reasonscard.LocalizedText" } } }, "role.CreateRoleDTO": { "type": "object", "required": [ "code", "guardName", "name" ], "properties": { "code": { "type": "string" }, "guardName": { "type": "string" }, "name": { "type": "string" } } }, "role.UpdateRoleDTO": { "type": "object", "required": [ "code", "guardName", "name" ], "properties": { "code": { "type": "string" }, "guardName": { "type": "string" }, "name": { "type": "string" } } }, "user.CreateUserDTO": { "type": "object", "required": [ "email", "name", "password", "username" ], "properties": { "active": { "type": "boolean" }, "avatar": { "type": "string" }, "email": { "type": "string" }, "firstName": { "type": "string" }, "lastName": { "type": "string" }, "lightMode": { "type": "integer" }, "name": { "type": "string" }, "password": { "type": "string" }, "phone": { "type": "string" }, "role": { "type": "string" }, "socialMedia": { "$ref": "#/definitions/user.SocialMedia" }, "username": { "type": "string" } } }, "user.SocialMedia": { "type": "object", "properties": { "facebook": { "type": "string" }, "instagram": { "type": "string" }, "telegram": { "type": "string" } } }, "user.UpdateUserDTO": { "type": "object", "required": [ "email", "name", "username" ], "properties": { "active": { "type": "boolean" }, "avatar": { "type": "string" }, "email": { "type": "string" }, "firstName": { "type": "string" }, "lastName": { "type": "string" }, "lightMode": { "type": "integer" }, "name": { "type": "string" }, "phone": { "type": "string" }, "role": { "type": "string" }, "socialMedia": { "$ref": "#/definitions/user.SocialMedia" }, "username": { "type": "string" } } } }, "securityDefinitions": { "BearerAuth": { "type": "apiKey", "name": "Authorization", "in": "header" } } }` // SwaggerInfo holds exported Swagger Info so clients can modify it var SwaggerInfo = &swag.Spec{ Version: "1.0", Host: "localhost:5050", BasePath: "/api/admin", Schemes: []string{}, Title: "Service APIs", Description: "Online payment system admin API.", InfoInstanceName: "swagger", SwaggerTemplate: docTemplate, LeftDelim: "{{", RightDelim: "}}", } func init() { swag.Register(SwaggerInfo.InstanceName(), SwaggerInfo) }