-
Notifications
You must be signed in to change notification settings - Fork 7
/
Copy pathlicense-management.yaml
285 lines (272 loc) · 9.9 KB
/
license-management.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
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
openapi: 3.0.1
info:
title: API Control Plane License Management Service
description: |
## Overview
License management API allows you to manage the following entities
- license
*A user with the **API Administrator** functional privilege can manage the
Licenses in Ingress and UMC.*
## Supported functionalities
License Management API supports the following functionalities for:
### License
1. List all the License in the system.
2. Add a new license.
3. Delete a license with a specific serial number.
version: '11.00'
servers:
- url: "{protocol}://{hostname}:{port}/api/ingress/v1"
description: This is the endpoint where the Ingress API is accessible from the server.
variables:
protocol:
default: https
enum:
- http
- https
description: The protocol supported by the server - HTTP or HTTPS. Default is HTTPS.
hostname:
default: localhost
description: The domain name of the server where the API is hosted. The hostname must be resolvable by the DNS lookup.
port:
default: "443"
description: The port number where the REST API is running on the server. The default port for HTTPS is 443 and HTTP is 80 but it can also be any valid port.
paths:
/license:
get:
summary: Listing all the licenses in the system.
description: |
This method lists all the available licenses in the system for that tenant.
**Restriction**: Restricted in control plane Cloud, Requires control plane administrator privilege.
tags:
- license
responses:
'200':
description: This status code indicates the successful retrieval of licenses available in the system.
content:
application/json:
schema:
description: Collection of licenses in the response
type: object
properties:
result:
description: Collection of licenses
type: array
items:
$ref: '#/components/schemas/ALicense'
examples:
LicenseListing:
description: License object to list the Licenses.
value:
- ALicense:
name: cloud_license.xml
licenseType: TEN
serialNumber: 0000037081
licenseKey: admin
customerName: SoftwareAGInternal
expirationDate: 2024-08-18T23:59:59.218+00:00
licenseQuantity: 1000
freeLicenseQuantity: 1000
created: 2021-03-24 08:15:23.345 IST
modified: 2021-03-24 09:15:23.345 IST
productVersion: 10.16
licenseXml: content of xml
expiringUnlimited: false
product: WCOC1
- ALicense:
name: license.xml
licenseType: TEN
serialNumber: 0000037345
licenseKey: admin
customerName: SoftwareAGInternal
expirationDate: 2024-08-18T23:59:59.218+00:00
licenseQuantity: 1000
freeLicenseQuantity: 1000
created: 2021-03-24 08:15:23.345 IST
modified: 2021-03-24 09:15:23.345 IST
productVersion: 10.16
licenseXml: content of xml
expiringUnlimited: false
product: WCOC1
'401':
$ref: '#/components/responses/Unauthorized'
'500':
$ref: '#/components/responses/internal_server_error'
post:
summary: Add a new license
description: |-
This method allows you to add a new license in control plane.
**Restriction**: Access is restricted to **authorized** individuals with administrator privilege. Restricted in control plane Cloud.
tags:
- Licenses
requestBody:
content:
multipart/form-data:
schema:
type: object
properties:
file:
type: string
format: binary
responses:
'200':
description: license added. Response for the license added.
content:
application/json:
schema:
$ref: '#/components/schemas/ALicense'
example:
- name: cloud_license.xml
licenseType: TEN
serialNumber: 0000037081
licenseKey: admin
customerName: SoftwareAGInternal
expirationDate: 2024-08-18T23:59:59.218+00:00
licenseQuantity: 1000
freeLicenseQuantity: 1000
created: 2021-03-24 08:15:23.345 IST
modified: 2021-03-24 09:15:23.345 IST
productVersion: 10.16
licenseXml: content of xml
expiringUnlimited: false
product: WCOC1
'400':
description: This status code indicates that the license file is not valid or already present.
content:
application/json:
examples:
License already used:
description: This will be sent when the passed license is already being used.
value:
errorDetails:
- 'The license is already being used for this tenant.'
'401':
$ref: '#/components/responses/Unauthorized'
'500':
$ref: '#/components/responses/internal_server_error'
delete:
summary: Delete a existing license
description: |-
This method allows you to delete a existing license in control plane.
**Restriction**: Access is restricted to **authorized** individuals with administrator privilege. Restricted in control plane Cloud.
tags:
- Licenses
parameters:
- name: serialNumber
in: query
description: The serial number of the license to be deleted.
schema:
type: integer
responses:
'200':
description: license Deleted Sucessfully.
'401':
$ref: '#/components/responses/Unauthorized'
'500':
$ref: '#/components/responses/internal_server_error'
components:
schemas:
ALicense:
description: The license definition for all the operations.
type: object
properties:
name:
description: License file name.
type: string
example: license.xml
serialNumber:
description: Serial number of license.
type: string
example: 0000037080
licenseType:
description: |
Type of the license.
- NUC - Named users.
- CUC - Concurrent users.
- ADU - Cross tenant, handled like NUC for multiple tenants.
- INV - instance volume.
- SCE - scenario
- ST - Tenant wide
- SER - Server wide
- TEN - Tenant wide
- VWR - named viewer
- VWC - concurrent viewer
- TXN - transaction based
- MTA - metric based
- INVALID - Invalid
type: string
enum:
- NUC
- CUC
- ADU
- INV
- SCE
- ST
- SER
- TEN
- VWR
- VWC
- TXN
- MTA
- INVALID
example: MTA
licenseKey:
description: License key of license.
type: string
example: 7080ATDC
customerName:
description: Name of the customer.
type: string
example: SoftwareAGInternal
expirationDate:
description: Date of expiry of license.
type: string
example: 2024-08-18T23:59:59.783+00:00
licenseQuantity:
description: The quantity of the license issued.
type: number
example: 150
freeLicenseQuantity:
description: The quantity of the free license issued.
type: number
example: 100
productVersion:
description: The version number of the product license is issued for.
type: string
example: 10.16
licenseXml:
description: String containing the content of license file.
type: string
example: content of licens.xml
expiringUnlimited:
description: flag for unlimited expiry license.
type: boolean
example: false
product:
description: Product code of the license.
type: string
example: WCOS1
ErrorMessage:
description: Common Error Response across all APIs
required: [ "errorDetails" ]
type: object
properties:
errorDetails:
type: array
items:
type: string
example: This response indicates that the server encountered an error.
responses:
Unauthorized:
description: This status code indicates that either the user did not provide valid user credentials or the user does not have privileges to perform the requested action.
internal_server_error:
description: Internal server error
content:
application/json:
schema:
$ref: "#/components/schemas/ErrorMessage"
examples:
Internal Server Error:
description: Internal Server Error occurred.
value:
errorDetails:
- This response indicates that the server encountered an error.