From d2a5a550f746a0c2436db2485921e36c3269049f Mon Sep 17 00:00:00 2001
From: Simon Zolin <s.zolin@adguard.com>
Date: Wed, 11 Sep 2019 19:26:37 +0300
Subject: [PATCH] + openapi: /login, /logout

---
 openapi/openapi.yaml | 40 +++++++++++++++++++++++++++++++++++++++-
 1 file changed, 39 insertions(+), 1 deletion(-)

diff --git a/openapi/openapi.yaml b/openapi/openapi.yaml
index fa36fac9..8febe107 100644
--- a/openapi/openapi.yaml
+++ b/openapi/openapi.yaml
@@ -932,6 +932,34 @@ paths:
                 500:
                     description: "Cannot start the DNS server"
 
+    /login:
+        post:
+            tags:
+                - global
+            operationId: login
+            summary: "Perform administrator log-in"
+            consumes:
+            - application/json
+            parameters:
+            - in: "body"
+              name: "body"
+              required: true
+              schema:
+                $ref: "#/definitions/Login"
+            responses:
+                200:
+                    description: OK
+
+    /logout:
+        get:
+            tags:
+                - global
+            operationId: logout
+            summary: "Perform administrator log-out"
+            responses:
+                302:
+                    description: OK
+
 definitions:
     ServerStatus:
         type: "object"
@@ -1673,4 +1701,14 @@ definitions:
             password:
                 type: "string"
                 description: "Basic auth password"
-                example: "password"
\ No newline at end of file
+                example: "password"
+    Login:
+        type: "object"
+        description: "Login request data"
+        properties:
+            username:
+                type: "string"
+                description: "User name"
+            password:
+                type: "string"
+                description: "Password"