diff --git a/api.yaml b/api.yaml index 89152f3..ba8c9f1 100644 --- a/api.yaml +++ b/api.yaml @@ -6,6 +6,33 @@ info: servers: - url: 'http://localhost:8080' paths: + /api/login: + post: + summary: Login to an author account + requestBody: + required: true + content: + application/json: + schema: + type: object + properties: + username: + type: string + description: Username of the user / author which logs in + password: + type: string + description: Password of the user + responses: + 200: + description: Logged in + headers: + Set-Cookie: + schema: + type: string + description: The session_id cookie to authenticate + 401: + description: Login failed + /api/recent: get: summary: Get recent articles