summaryrefslogtreecommitdiffstats
path: root/openapi/components.yml
diff options
context:
space:
mode:
Diffstat (limited to 'openapi/components.yml')
-rw-r--r--openapi/components.yml78
1 files changed, 46 insertions, 32 deletions
diff --git a/openapi/components.yml b/openapi/components.yml
index cdf4c1c0..aa0827a5 100644
--- a/openapi/components.yml
+++ b/openapi/components.yml
@@ -16,6 +16,7 @@ components:
properties:
cmHandles:
type: array
+ example: ["cmHandleId1","cmHandleId2","cmHandleId3"]
items:
type: string
@@ -37,9 +38,11 @@ components:
type: object
properties:
name:
- $ref: '#/components/schemas/name'
+ type: string
+ example: my-name
revision:
- $ref: '#/components/schemas/revision'
+ type: string
+ example: my-revision
cmHandleProperties:
$ref: '#/components/schemas/cmHandleProperties'
@@ -53,10 +56,13 @@ components:
properties:
moduleName:
type: string
+ example: my-module-name
revision:
- $ref: '#/components/schemas/revision'
+ type: string
+ example: my-revision
namespace:
type: string
+ example: my-namespace
YangResources:
type: array
@@ -68,10 +74,13 @@ components:
properties:
yangSource:
type: string
+ example: my-yang-source
moduleName:
type: string
+ example: my-module-name
revision:
- $ref: '#/components/schemas/revision'
+ type: string
+ example: my-revision
DataAccessRequest:
type: object
@@ -79,10 +88,13 @@ components:
operation:
type: string
enum: [ read, create, update, delete ]
+ example: read
dataType:
type: string
+ example: my-data-type
data:
type: string
+ example: my-data
cmHandleProperties:
$ref: '#/components/schemas/cmHandleProperties'
@@ -92,60 +104,60 @@ components:
type: string
example: {"prop1":"value1","prop2":"value2"}
- name:
- type: string
- example: someName
-
- revision:
- type: string
- example: someRevision
-
responses:
- NotFound:
- description: The specified resource was not found
+ NoContent:
+ description: No Content
+ content: {}
+ BadRequest:
+ description: Bad Request
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorMessage'
+ example:
+ status: 400
+ message: Bad Request
+ details: The provided request is not valid
Unauthorized:
description: Unauthorized
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorMessage'
+ example:
+ status: 401
+ message: Unauthorized request
+ details: This request is unauthorized
Forbidden:
description: Forbidden
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorMessage'
- BadRequest:
- description: Bad Request
+ example:
+ status: 403
+ message: Request Forbidden
+ details: This request is forbidden
+ NotFound:
+ description: The specified resource was not found
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorMessage'
+ example:
+ status: 404
+ message: Resource Not Found
+ details: The requested resource is not found
Conflict:
description: Conflict
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorMessage'
- Ok:
- description: OK
- content:
- application/json:
- schema:
- type: object
- Created:
- description: Created
- content:
- text/plain:
- schema:
- type: string
- NoContent:
- description: No Content
- content: {}
+ example:
+ status: 409
+ message: Conflicting request
+ details: The request cannot be processed as the resource is in use.
parameters:
cmHandleInPath:
@@ -155,6 +167,7 @@ components:
required: true
schema:
type: string
+ example: my-cm-handle
resourceIdentifierInQuery:
name: resourceIdentifier
@@ -164,6 +177,7 @@ components:
allowReserved: true
schema:
type: string
+ example: my-schema:my-node
acceptParamInHeader:
name: accept
@@ -190,4 +204,4 @@ components:
options: (key1=value1,key2=value1/value2)
sample3:
value:
- options: (key1=10,key2=value2,key3=[val31,val32]) \ No newline at end of file
+ options: (key1=10,key2=value2,key3=val31,val32) \ No newline at end of file