Skip to content

Commit

Permalink
use struct for notifications objects instead of just strings
Browse files Browse the repository at this point in the history
to be able easily extend API in the future return list of
trigger/template/service as list of structs

Signed-off-by: Pavel <aborilov@gmail.com>
  • Loading branch information
aborilov committed Aug 24, 2022
1 parent 7ecf6ab commit 08fca61
Show file tree
Hide file tree
Showing 7 changed files with 835 additions and 204 deletions.
48 changes: 36 additions & 12 deletions assets/swagger.json
Original file line number Diff line number Diff line change
Expand Up @@ -2150,7 +2150,7 @@
"200": {
"description": "A successful response.",
"schema": {
"$ref": "#/definitions/notificationServices"
"$ref": "#/definitions/notificationServiceList"
}
},
"default": {
Expand All @@ -2173,7 +2173,7 @@
"200": {
"description": "A successful response.",
"schema": {
"$ref": "#/definitions/notificationTemplates"
"$ref": "#/definitions/notificationTemplateList"
}
},
"default": {
Expand All @@ -2196,7 +2196,7 @@
"200": {
"description": "A successful response.",
"schema": {
"$ref": "#/definitions/notificationTriggers"
"$ref": "#/definitions/notificationTriggerList"
}
},
"default": {
Expand Down Expand Up @@ -4048,35 +4048,59 @@
"type": "object",
"title": "Generic (empty) response for GPG public key CRUD requests"
},
"notificationServices": {
"notificationService": {
"type": "object",
"properties": {
"services": {
"name": {
"type": "string"
}
}
},
"notificationServiceList": {
"type": "object",
"properties": {
"items": {
"type": "array",
"items": {
"type": "string"
"$ref": "#/definitions/notificationService"
}
}
}
},
"notificationTemplates": {
"notificationTemplate": {
"type": "object",
"properties": {
"templates": {
"name": {
"type": "string"
}
}
},
"notificationTemplateList": {
"type": "object",
"properties": {
"items": {
"type": "array",
"items": {
"type": "string"
"$ref": "#/definitions/notificationTemplate"
}
}
}
},
"notificationTriggers": {
"notificationTrigger": {
"type": "object",
"properties": {
"triggers": {
"name": {
"type": "string"
}
}
},
"notificationTriggerList": {
"type": "object",
"properties": {
"items": {
"type": "array",
"items": {
"type": "string"
"$ref": "#/definitions/notificationTrigger"
}
}
}
Expand Down

0 comments on commit 08fca61

Please sign in to comment.