feat: stop single session and auto start all sessions

This commit is contained in:
Anton Voylenko 2025-07-11 20:14:24 +03:00
commit 19797f4268
8 changed files with 162 additions and 7 deletions

View file

@ -220,6 +220,74 @@
]
}
},
"/session/stop/{sessionId}": {
"get": {
"tags": [
"Session"
],
"summary": "Stop session",
"description": "Stops a session for the given session ID.",
"parameters": [
{
"name": "sessionId",
"in": "path",
"required": true,
"schema": {
"type": "string"
},
"description": "Unique identifier for the session (alphanumeric and - allowed)",
"example": "f8377d8d-a589-4242-9ba6-9486a04ef80c"
}
],
"responses": {
"200": {
"description": "Status of the stopped session.",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/StopSessionResponse"
}
}
}
},
"403": {
"description": "Forbidden.",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/ForbiddenResponse"
}
}
}
},
"422": {
"description": "Unprocessable Entity.",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/ErrorResponse"
}
}
}
},
"500": {
"description": "Server failure.",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/ErrorResponse"
}
}
}
}
},
"security": [
{
"apiKeyAuth": []
}
]
}
},
"/session/status/{sessionId}": {
"get": {
"tags": [
@ -11571,6 +11639,22 @@
"name": "StartSessionResponse"
}
},
"StopSessionResponse": {
"type": "object",
"properties": {
"success": {
"type": "boolean",
"example": true
},
"message": {
"type": "string",
"example": "Session stopped successfully"
}
},
"xml": {
"name": "StopSessionResponse"
}
},
"StatusSessionResponse": {
"type": "object",
"properties": {