diff --git a/src/api/api.go b/src/api/api.go index 642b5ad..bab9956 100644 --- a/src/api/api.go +++ b/src/api/api.go @@ -1416,7 +1416,7 @@ func (a *Api) UpdateGroup(c *gin.Context) { // @Success 204 {string} OK // @Failure 400 {object} Error // @Param data body Reaction true "Reaction" -// @Param id path int true "Reaction Identifier" +// @Param id path string true "Phone number" // @Router /v1/reactions/{number} [post] func (a *Api) SendReaction(c *gin.Context) { var req Reaction @@ -1465,7 +1465,7 @@ func (a *Api) SendReaction(c *gin.Context) { // @Success 204 {string} OK // @Failure 400 {object} Error // @Param data body Reaction true "Reaction" -// @Param id path int true "Reaction Identifier" +// @Param id path string true "Phone number" // @Router /v1/reactions/{number} [delete] func (a *Api) RemoveReaction(c *gin.Context) { var req Reaction @@ -1509,7 +1509,7 @@ func (a *Api) RemoveReaction(c *gin.Context) { // @Success 204 {string} OK // @Failure 400 {object} Error // @Param data body Receipt true "Receipt" -// @Param id path int true "Receipt Identifier" +// @Param id path string true "Phone number" // @Router /v1/receipts/{number} [post] func (a *Api) SendReceipt(c *gin.Context) { var req Receipt diff --git a/src/docs/README.md b/src/docs/README.md index 08b925d..eb559cb 100644 --- a/src/docs/README.md +++ b/src/docs/README.md @@ -1,6 +1,6 @@ These files are generated from the [swaggo/swag](https://github.com/swaggo/swag) tool. -To regenerate them, run: +To regenerate them, run in /src: ```bash docker run --rm -v $(pwd):/code ghcr.io/swaggo/swag:latest init diff --git a/src/docs/docs.go b/src/docs/docs.go index dd62453..bee7032 100644 --- a/src/docs/docs.go +++ b/src/docs/docs.go @@ -1417,8 +1417,8 @@ const docTemplate = `{ } }, { - "type": "integer", - "description": "Reaction Identifier", + "type": "string", + "description": "Phone number", "name": "id", "in": "path", "required": true @@ -1462,8 +1462,8 @@ const docTemplate = `{ } }, { - "type": "integer", - "description": "Reaction Identifier", + "type": "string", + "description": "Phone number", "name": "id", "in": "path", "required": true @@ -1509,8 +1509,8 @@ const docTemplate = `{ } }, { - "type": "integer", - "description": "Receipt Identifier", + "type": "string", + "description": "Phone number", "name": "id", "in": "path", "required": true diff --git a/src/docs/swagger.json b/src/docs/swagger.json index bbc1ebc..f485cdf 100644 --- a/src/docs/swagger.json +++ b/src/docs/swagger.json @@ -1414,8 +1414,8 @@ } }, { - "type": "integer", - "description": "Reaction Identifier", + "type": "string", + "description": "Phone number", "name": "id", "in": "path", "required": true @@ -1459,8 +1459,8 @@ } }, { - "type": "integer", - "description": "Reaction Identifier", + "type": "string", + "description": "Phone number", "name": "id", "in": "path", "required": true @@ -1506,8 +1506,8 @@ } }, { - "type": "integer", - "description": "Receipt Identifier", + "type": "string", + "description": "Phone number", "name": "id", "in": "path", "required": true diff --git a/src/docs/swagger.yaml b/src/docs/swagger.yaml index 634f5e7..285f723 100644 --- a/src/docs/swagger.yaml +++ b/src/docs/swagger.yaml @@ -1287,11 +1287,11 @@ paths: required: true schema: $ref: '#/definitions/api.Reaction' - - description: Reaction Identifier + - description: Phone number in: path name: id required: true - type: integer + type: string produces: - application/json responses: @@ -1317,11 +1317,11 @@ paths: required: true schema: $ref: '#/definitions/api.Reaction' - - description: Reaction Identifier + - description: Phone number in: path name: id required: true - type: integer + type: string produces: - application/json responses: @@ -1348,11 +1348,11 @@ paths: required: true schema: $ref: '#/definitions/api.Receipt' - - description: Receipt Identifier + - description: Phone number in: path name: id required: true - type: integer + type: string produces: - application/json responses: