/
authentication-refresh.yaml
54 lines (52 loc) · 2.5 KB
/
authentication-refresh.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
openapi: 3.0.2
info:
title: Eclipse Kapua REST API - Authentication
version: '1.0'
contact:
name: Eclipse Kapua Dev Team
url: https://eclipse.org/kapua
email: kapua-dev@eclipse.org
license:
name: Eclipse Public License 2.0
url: https://www.eclipse.org/legal/epl-2.0
paths:
/authentication/refresh:
post:
tags:
- Authentication
summary: Refresh an AccessToken
description: |
Creates a new AccessToken from an existing (even if expired) AccessToken and a Refresh Token that must be still valid.
Regardless of the expiration date, the AccessToken provided to the refresh operation WILL be invalidated
operationId: authenticationRefresh
requestBody:
content:
application/json:
schema:
type: object
properties:
refreshToken:
type: string
format: uuid
tokenId:
$ref: './authentication.yaml#/components/schemas/jwt'
required:
- refreshToken
- tokenId
example:
refreshToken: 15395d03-ccad-4aed-a57a-cd0e289e822c
tokenId: eyJhbGciOiJSUzI1NiJ9.eyJpc3MiOiJodHRwczovL3d3dy5lY2xpcHNlLm9yZy9rYXB1YSIsImlhdCI6MTYyMjQ3NDE1NCwiZXhwIjoxNjIyNDc0MTU0LCJzdWIiOiJBUSIsInNJZCI6IkFRIn0.cVHkdXKbAtiOPUj1tyUQi9mRiRV9e6CwQ9RMLmAoX1UCK-POZcusqgSvuaaDzDIe-WNUjsalYYqNquxync8bvOF8Bx84rS8BJlB3anxCIaXwi7_5E9ZjmOSgvNiwgDPFVQsRo9MaNTe07jb3TsT1BPR9zo-i9-OEada6o4nhyaBNrAw_vybA3aLp6hamUNP1vHLRhlq0tnHgtGtitCW1_VBt4Eh0b41Enfs7G7hWv0Sj2CfwVIwAQzJ55MV5tnTjuD-eOD5xxeQGlWTol4Yc40jmOKjo2kshJlEQRNkp6mFzJ3EJxE8nBWhbWO4hd36eI0rB8pHxSdsFDbVAcxyRM44K7YuLENCk2mdMRgv9d7CKUTujvPw5vCoa5IQY7E47rWszwKAF2xJBU8hYwI8BhQWbB6efAaB-lkzq4rCziBU5WzTDZlries4WqPqM9mgfIPjlHP4po2b-RAK-89E-FejOvNefNcXqvqt5QPiNwj9bdLmhXlO4ladZ-wKw-22AYbqVhhoffOYT2mdxqXGc9F9XsRnsNswzxUdejBF6war4XqqxsrcPoYoReLMGlR1piQ1dpcPQlY6p9qKlkpBGJFL3pnBLSSE0mj9_2-zDKmJ81stUr51yP17ky2GB3Ls5q4O8gD83CJjqZaW-6xNO5iJENr4UYK4AV7yzfWqLAI8
responses:
200:
description: The new AccessToken
content:
application/json:
schema:
$ref: './authentication.yaml#/components/schemas/accessToken'
401:
$ref: '../openapi.yaml#/components/responses/unauthenticated'
403:
$ref: '../openapi.yaml#/components/responses/subjectUnauthorized'
500:
$ref: '../openapi.yaml#/components/responses/kapuaError'
security: []