fixed error in swagger documentation

* set pin request needs to be a POST request
* added payload to swagger documentation
This commit is contained in:
Bernhard B
2025-03-16 00:22:39 +01:00
parent 2833a9b8a7
commit 8346f9072a
4 changed files with 50 additions and 4 deletions

View File

@@ -65,7 +65,7 @@ const docTemplate = `{
}
},
"/v1/accounts/{number}/pin": {
"get": {
"post": {
"description": "Sets a new Signal Pin",
"produces": [
"application/json"
@@ -81,6 +81,15 @@ const docTemplate = `{
"name": "number",
"in": "path",
"required": true
},
{
"description": "Request",
"name": "data",
"in": "body",
"required": true,
"schema": {
"$ref": "#/definitions/api.SetPinRequest"
}
}
],
"responses": {
@@ -2426,6 +2435,14 @@ const docTemplate = `{
}
}
},
"api.SetPinRequest": {
"type": "object",
"properties": {
"pin": {
"type": "string"
}
}
},
"api.SetUsernameRequest": {
"type": "object",
"properties": {