a.sreekumar | e756dc9 | 2021-02-19 17:29:40 +0000 | [diff] [blame] | 1 | { |
| 2 | "swagger": "2.0", |
| 3 | "info": { |
| 4 | "title": "The APIs listed here are used to fetch status of policies in PdpGroups", |
| 5 | "version": "v1" |
| 6 | }, |
| 7 | "basePath": "/", |
| 8 | "tags": [ |
| 9 | { |
a.sreekumar | e2528a7 | 2021-02-22 14:56:27 +0000 | [diff] [blame] | 10 | "name": "Policy Status" |
a.sreekumar | e756dc9 | 2021-02-19 17:29:40 +0000 | [diff] [blame] | 11 | } |
| 12 | ], |
| 13 | "schemes": [ |
| 14 | "http", |
| 15 | "https" |
| 16 | ], |
| 17 | "consumes": [ |
| 18 | "application/json", |
| 19 | "application/yaml" |
| 20 | ], |
| 21 | "produces": [ |
| 22 | "application/json", |
| 23 | "application/yaml" |
| 24 | ], |
| 25 | "paths": { |
| 26 | "/policy/pap/v1/policies/status": { |
| 27 | "get": { |
| 28 | "tags": [ |
Ram Krishna Verma | 6f96b34 | 2021-02-22 14:44:33 -0500 | [diff] [blame^] | 29 | "Policy Status" |
a.sreekumar | e756dc9 | 2021-02-19 17:29:40 +0000 | [diff] [blame] | 30 | ], |
| 31 | "summary": "Queries status of policies in all PdpGroups", |
| 32 | "description": "Queries status of policies in all PdpGroups, returning status of policies in all the PDPs belonging to all PdpGroups", |
| 33 | "operationId": "queryAllPolicies", |
| 34 | "produces": [ |
| 35 | "application/json", |
| 36 | "application/yaml" |
| 37 | ], |
| 38 | "parameters": [ |
| 39 | { |
| 40 | "name": "X-ONAP-RequestID", |
| 41 | "in": "header", |
| 42 | "description": "RequestID for http transaction", |
| 43 | "required": false, |
| 44 | "type": "string", |
| 45 | "format": "uuid" |
| 46 | } |
| 47 | ], |
| 48 | "responses": { |
| 49 | "200": { |
| 50 | "description": "successful operation", |
| 51 | "headers": { |
| 52 | "X-MinorVersion": { |
| 53 | "type": "string", |
| 54 | "description": "Used to request or communicate a MINOR version back from the client to the server, and from the server back to the client" |
| 55 | }, |
| 56 | "X-PatchVersion": { |
| 57 | "type": "string", |
| 58 | "description": "Used only to communicate a PATCH version in a response for troubleshooting purposes only, and will not be provided by the client on request" |
| 59 | }, |
| 60 | "X-LatestVersion": { |
| 61 | "type": "string", |
| 62 | "description": "Used only to communicate an API's latest version" |
| 63 | }, |
| 64 | "X-ONAP-RequestID": { |
| 65 | "type": "string", |
| 66 | "format": "uuid", |
| 67 | "description": "Used to track REST transactions for logging purpose" |
| 68 | } |
| 69 | }, |
| 70 | "schema": { |
| 71 | "type": "array", |
| 72 | "items": { |
| 73 | "$ref": "#/definitions/PdpPolicyStatus" |
| 74 | } |
| 75 | } |
| 76 | }, |
| 77 | "401": { |
| 78 | "description": "Authentication Error" |
| 79 | }, |
| 80 | "403": { |
| 81 | "description": "Authorization Error" |
| 82 | }, |
| 83 | "500": { |
| 84 | "description": "Internal Server Error" |
| 85 | } |
| 86 | }, |
| 87 | "security": [ |
| 88 | { |
| 89 | "basicAuth": [] |
| 90 | } |
| 91 | ], |
| 92 | "x-interface info": { |
| 93 | "api-version": "1.0.0", |
| 94 | "last-mod-release": "Honolulu" |
| 95 | } |
| 96 | } |
| 97 | }, |
| 98 | "/policy/pap/v1/policies/status/{pdpGroupName}": { |
| 99 | "get": { |
| 100 | "tags": [ |
Ram Krishna Verma | 6f96b34 | 2021-02-22 14:44:33 -0500 | [diff] [blame^] | 101 | "Policy Status" |
a.sreekumar | e756dc9 | 2021-02-19 17:29:40 +0000 | [diff] [blame] | 102 | ], |
| 103 | "summary": "Queries status of policies in a specific PdpGroup", |
| 104 | "description": "Queries status of policies in a specific PdpGroup, returning status of policies in all the PDPs belonging to the PdpGroup", |
| 105 | "operationId": "queryAllPoliciesInPdpGroup", |
| 106 | "produces": [ |
| 107 | "application/json", |
| 108 | "application/yaml" |
| 109 | ], |
| 110 | "parameters": [ |
| 111 | { |
| 112 | "name": "pdpGroupName", |
| 113 | "in": "path", |
| 114 | "description": "Name of the PdpGroup", |
| 115 | "required": true, |
| 116 | "type": "string" |
| 117 | }, |
| 118 | { |
| 119 | "name": "X-ONAP-RequestID", |
| 120 | "in": "header", |
| 121 | "description": "RequestID for http transaction", |
| 122 | "required": false, |
| 123 | "type": "string", |
| 124 | "format": "uuid" |
| 125 | } |
| 126 | ], |
| 127 | "responses": { |
| 128 | "200": { |
| 129 | "description": "successful operation", |
| 130 | "headers": { |
| 131 | "X-MinorVersion": { |
| 132 | "type": "string", |
| 133 | "description": "Used to request or communicate a MINOR version back from the client to the server, and from the server back to the client" |
| 134 | }, |
| 135 | "X-PatchVersion": { |
| 136 | "type": "string", |
| 137 | "description": "Used only to communicate a PATCH version in a response for troubleshooting purposes only, and will not be provided by the client on request" |
| 138 | }, |
| 139 | "X-LatestVersion": { |
| 140 | "type": "string", |
| 141 | "description": "Used only to communicate an API's latest version" |
| 142 | }, |
| 143 | "X-ONAP-RequestID": { |
| 144 | "type": "string", |
| 145 | "format": "uuid", |
| 146 | "description": "Used to track REST transactions for logging purpose" |
| 147 | } |
| 148 | }, |
| 149 | "schema": { |
| 150 | "type": "array", |
| 151 | "items": { |
| 152 | "$ref": "#/definitions/PdpPolicyStatus" |
| 153 | } |
| 154 | } |
| 155 | }, |
| 156 | "401": { |
| 157 | "description": "Authentication Error" |
| 158 | }, |
| 159 | "403": { |
| 160 | "description": "Authorization Error" |
| 161 | }, |
Ram Krishna Verma | 6f96b34 | 2021-02-22 14:44:33 -0500 | [diff] [blame^] | 162 | "404": { |
| 163 | "description": "Resource not found" |
| 164 | }, |
a.sreekumar | e756dc9 | 2021-02-19 17:29:40 +0000 | [diff] [blame] | 165 | "500": { |
| 166 | "description": "Internal Server Error" |
| 167 | } |
| 168 | }, |
| 169 | "security": [ |
| 170 | { |
| 171 | "basicAuth": [] |
| 172 | } |
| 173 | ], |
| 174 | "x-interface info": { |
| 175 | "api-version": "1.0.0", |
| 176 | "last-mod-release": "Honolulu" |
| 177 | } |
| 178 | } |
| 179 | }, |
| 180 | "/policy/pap/v1/policies/status/{pdpGroupName}/{policyName}": { |
| 181 | "get": { |
| 182 | "tags": [ |
Ram Krishna Verma | 6f96b34 | 2021-02-22 14:44:33 -0500 | [diff] [blame^] | 183 | "Policy Status" |
a.sreekumar | e756dc9 | 2021-02-19 17:29:40 +0000 | [diff] [blame] | 184 | ], |
| 185 | "summary": "Queries status of all versions of a specific policy in a specific PdpGroup", |
| 186 | "description": "Queries status of all versions of a specific policy in a specific PdpGroup, returning status of all versions of the policy in the PDPs belonging to the PdpGroup", |
| 187 | "operationId": "queryAllVersionPolicy", |
| 188 | "produces": [ |
| 189 | "application/json", |
| 190 | "application/yaml" |
| 191 | ], |
| 192 | "parameters": [ |
| 193 | { |
| 194 | "name": "pdpGroupName", |
| 195 | "in": "path", |
| 196 | "description": "Name of the PdpGroup", |
| 197 | "required": true, |
| 198 | "type": "string" |
| 199 | }, |
| 200 | { |
| 201 | "name": "policyName", |
| 202 | "in": "path", |
| 203 | "description": "Name of the Policy", |
| 204 | "required": true, |
| 205 | "type": "string" |
| 206 | }, |
| 207 | { |
| 208 | "name": "X-ONAP-RequestID", |
| 209 | "in": "header", |
| 210 | "description": "RequestID for http transaction", |
| 211 | "required": false, |
| 212 | "type": "string", |
| 213 | "format": "uuid" |
| 214 | } |
| 215 | ], |
| 216 | "responses": { |
| 217 | "200": { |
| 218 | "description": "successful operation", |
| 219 | "headers": { |
| 220 | "X-MinorVersion": { |
| 221 | "type": "string", |
| 222 | "description": "Used to request or communicate a MINOR version back from the client to the server, and from the server back to the client" |
| 223 | }, |
| 224 | "X-PatchVersion": { |
| 225 | "type": "string", |
| 226 | "description": "Used only to communicate a PATCH version in a response for troubleshooting purposes only, and will not be provided by the client on request" |
| 227 | }, |
| 228 | "X-LatestVersion": { |
| 229 | "type": "string", |
| 230 | "description": "Used only to communicate an API's latest version" |
| 231 | }, |
| 232 | "X-ONAP-RequestID": { |
| 233 | "type": "string", |
| 234 | "format": "uuid", |
| 235 | "description": "Used to track REST transactions for logging purpose" |
| 236 | } |
| 237 | }, |
| 238 | "schema": { |
| 239 | "type": "array", |
| 240 | "items": { |
| 241 | "$ref": "#/definitions/PdpPolicyStatus" |
| 242 | } |
| 243 | } |
| 244 | }, |
| 245 | "401": { |
| 246 | "description": "Authentication Error" |
| 247 | }, |
| 248 | "403": { |
| 249 | "description": "Authorization Error" |
| 250 | }, |
Ram Krishna Verma | 6f96b34 | 2021-02-22 14:44:33 -0500 | [diff] [blame^] | 251 | "404": { |
| 252 | "description": "Resource not found" |
| 253 | }, |
a.sreekumar | e756dc9 | 2021-02-19 17:29:40 +0000 | [diff] [blame] | 254 | "500": { |
| 255 | "description": "Internal Server Error" |
| 256 | } |
| 257 | }, |
| 258 | "security": [ |
| 259 | { |
| 260 | "basicAuth": [] |
| 261 | } |
| 262 | ], |
| 263 | "x-interface info": { |
| 264 | "api-version": "1.0.0", |
| 265 | "last-mod-release": "Honolulu" |
| 266 | } |
| 267 | } |
| 268 | }, |
| 269 | "/policy/pap/v1/policies/status/{pdpGroupName}/{policyName}/{policyVersion}": { |
| 270 | "get": { |
| 271 | "tags": [ |
Ram Krishna Verma | 6f96b34 | 2021-02-22 14:44:33 -0500 | [diff] [blame^] | 272 | "Policy Status" |
a.sreekumar | e756dc9 | 2021-02-19 17:29:40 +0000 | [diff] [blame] | 273 | ], |
| 274 | "summary": "Queries status of a specific version of a specific policy in a specific PdpGroup", |
| 275 | "description": "Queries status of a specific version of a specific policy in a specific PdpGroup, returning status of the policy in the PDPs belonging to the PdpGroup", |
| 276 | "operationId": "querySpecificVersionPolicy", |
| 277 | "produces": [ |
| 278 | "application/json", |
| 279 | "application/yaml" |
| 280 | ], |
| 281 | "parameters": [ |
| 282 | { |
| 283 | "name": "pdpGroupName", |
| 284 | "in": "path", |
| 285 | "description": "Name of the PdpGroup", |
| 286 | "required": true, |
| 287 | "type": "string" |
| 288 | }, |
| 289 | { |
| 290 | "name": "policyName", |
| 291 | "in": "path", |
| 292 | "description": "Name of the Policy", |
| 293 | "required": true, |
| 294 | "type": "string" |
| 295 | }, |
| 296 | { |
| 297 | "name": "policyVersion", |
| 298 | "in": "path", |
| 299 | "description": "Version of the Policy", |
| 300 | "required": true, |
| 301 | "type": "string" |
| 302 | }, |
| 303 | { |
| 304 | "name": "X-ONAP-RequestID", |
| 305 | "in": "header", |
| 306 | "description": "RequestID for http transaction", |
| 307 | "required": false, |
| 308 | "type": "string", |
| 309 | "format": "uuid" |
| 310 | } |
| 311 | ], |
| 312 | "responses": { |
| 313 | "200": { |
| 314 | "description": "successful operation", |
| 315 | "headers": { |
| 316 | "X-MinorVersion": { |
| 317 | "type": "string", |
| 318 | "description": "Used to request or communicate a MINOR version back from the client to the server, and from the server back to the client" |
| 319 | }, |
| 320 | "X-PatchVersion": { |
| 321 | "type": "string", |
| 322 | "description": "Used only to communicate a PATCH version in a response for troubleshooting purposes only, and will not be provided by the client on request" |
| 323 | }, |
| 324 | "X-LatestVersion": { |
| 325 | "type": "string", |
| 326 | "description": "Used only to communicate an API's latest version" |
| 327 | }, |
| 328 | "X-ONAP-RequestID": { |
| 329 | "type": "string", |
| 330 | "format": "uuid", |
| 331 | "description": "Used to track REST transactions for logging purpose" |
| 332 | } |
| 333 | }, |
| 334 | "schema": { |
| 335 | "type": "array", |
| 336 | "items": { |
| 337 | "$ref": "#/definitions/PdpPolicyStatus" |
| 338 | } |
| 339 | } |
| 340 | }, |
| 341 | "401": { |
| 342 | "description": "Authentication Error" |
| 343 | }, |
| 344 | "403": { |
| 345 | "description": "Authorization Error" |
| 346 | }, |
Ram Krishna Verma | 6f96b34 | 2021-02-22 14:44:33 -0500 | [diff] [blame^] | 347 | "404": { |
| 348 | "description": "Resource not found" |
| 349 | }, |
a.sreekumar | e756dc9 | 2021-02-19 17:29:40 +0000 | [diff] [blame] | 350 | "500": { |
| 351 | "description": "Internal Server Error" |
| 352 | } |
| 353 | }, |
| 354 | "security": [ |
| 355 | { |
| 356 | "basicAuth": [] |
| 357 | } |
| 358 | ], |
| 359 | "x-interface info": { |
| 360 | "api-version": "1.0.0", |
| 361 | "last-mod-release": "Honolulu" |
| 362 | } |
| 363 | } |
a.sreekumar | e2528a7 | 2021-02-22 14:56:27 +0000 | [diff] [blame] | 364 | } |
a.sreekumar | e756dc9 | 2021-02-19 17:29:40 +0000 | [diff] [blame] | 365 | }, |
| 366 | "securityDefinitions": { |
| 367 | "basicAuth": { |
| 368 | "description": "", |
| 369 | "type": "basic" |
| 370 | } |
| 371 | }, |
| 372 | "definitions": { |
| 373 | "PdpPolicyStatus": { |
| 374 | "type": "object", |
| 375 | "properties": { |
| 376 | "pdpGroup": { |
| 377 | "type": "string" |
| 378 | }, |
| 379 | "pdpType": { |
| 380 | "type": "string" |
| 381 | }, |
| 382 | "pdpId": { |
| 383 | "type": "string" |
| 384 | }, |
| 385 | "policy": { |
| 386 | "$ref": "#/definitions/ToscaConceptIdentifier" |
| 387 | }, |
| 388 | "policyType": { |
| 389 | "$ref": "#/definitions/ToscaConceptIdentifier" |
| 390 | }, |
| 391 | "deploy": { |
| 392 | "type": "boolean" |
| 393 | }, |
| 394 | "state": { |
| 395 | "type": "string" |
| 396 | } |
| 397 | } |
| 398 | }, |
| 399 | "ToscaConceptIdentifier": { |
| 400 | "type": "object", |
| 401 | "properties": { |
| 402 | "name": { |
| 403 | "type": "string" |
| 404 | }, |
| 405 | "version": { |
| 406 | "type": "string" |
| 407 | } |
| 408 | } |
| 409 | } |
| 410 | } |
| 411 | } |