feat(apikey): added route to list user api keys (#1708)

adding api key expiration date

Signed-off-by: Petu Eusebiu <peusebiu@cisco.com>
This commit is contained in:
peusebiu
2023-08-29 19:38:38 +03:00
committed by GitHub
parent 28858f695f
commit 6926bddd3a
15 changed files with 1132 additions and 153 deletions
+33
View File
@@ -12,6 +12,36 @@
},
"paths": {
"/auth/apikey": {
"get": {
"description": "Get list of all API keys for a logged in user",
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"summary": "Get list of API keys for the current user",
"responses": {
"200": {
"description": "ok",
"schema": {
"type": "string"
}
},
"401": {
"description": "unauthorized",
"schema": {
"type": "string"
}
},
"500": {
"description": "internal server error",
"schema": {
"type": "string"
}
}
}
},
"post": {
"description": "Can create an api key for a logged in user, based on the provided label and scopes.",
"consumes": [
@@ -1130,6 +1160,9 @@
"api.APIKeyPayload": {
"type": "object",
"properties": {
"expirationDate": {
"type": "string"
},
"label": {
"type": "string"
},