Skip to content

Commit

Permalink
Added 404 and 400 HTTP error codes where missing
Browse files Browse the repository at this point in the history
  • Loading branch information
jonathan-r-thorpe committed May 8, 2024
1 parent 3c22ee6 commit 0fbbd45
Showing 1 changed file with 35 additions and 2 deletions.
37 changes: 35 additions & 2 deletions APIs/ConfigurationAPI.raml
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,11 @@ documentation:
body:
type: !include schemas/bulkProperties-get-response.json
example: !include ../examples/bulkProperties-get-200.json
404:
description: 'Returned when the requested Role Path does not exist. Corresponds to NcMethodStatus code 404.'
body:
type: !include schemas/ms05-error.json

options:
description: 'Validate an NcBulkValuesHolder object against the Device Model'
body:
Expand All @@ -71,6 +76,10 @@ documentation:
body:
type: !include schemas/bulkProperties-validate-response.json
example: !include ../examples/bulkProperties-validate-200.json
404:
description: 'Returned when the requested Role Path does not exist. Corresponds to NcMethodStatus code 404.'
body:
type: !include schemas/ms05-error.json
put:
description: 'Set a Bulk Properties object on the Device Model'
body:
Expand All @@ -81,6 +90,10 @@ documentation:
body:
type: !include schemas/bulkProperties-set-response.json
example: !include ../examples/bulkProperties-set-200.json
404:
description: 'Returned when the requested Role Path does not exist. Corresponds to NcMethodStatus code 404.'
body:
type: !include schemas/ms05-error.json
/descriptor:
displayName: 'Class Descriptor'
get:
Expand All @@ -90,6 +103,10 @@ documentation:
body:
example: !include ../examples/class-descriptor-get-200.json
type: !include schemas/descriptor-get.json
404:
description: 'Returned when the requested Role Path does not exist. Corresponds to NcMethodStatus code 404.'
body:
type: !include schemas/ms05-error.json
500:
description: 'Returned when the Class Descriptor of this object was unable to be retrieved. Corresponds to NcMethodStatus code 500.'
body:
Expand Down Expand Up @@ -123,7 +140,7 @@ documentation:
body:
type: !include schemas/ms05-error.json
404:
description: 'Returned when the requested Method does not exist. Corresponds to NcMethodStatus code 501.'
description: 'Returned when the requested Role Path or Method does not exist. Corresponds to NcMethodStatus codes 404 and 501.'
body:
type: !include schemas/ms05-error.json
500:
Expand Down Expand Up @@ -152,7 +169,7 @@ documentation:
example: !include ../examples/property-get-200.json
type: !include schemas/property.json
404:
description: 'Returned when the requested Property does not exist. Corresponds to NcMethodStatus code 502.'
description: 'Returned when the requested Role Path or Property does not exist. Corresponds to NcMethodStatus codes 404 and 502.'
body:
type: !include schemas/ms05-error.json
/descriptor:
Expand All @@ -164,6 +181,10 @@ documentation:
body:
example: !include ../examples/property-descriptor-get-200.json
type: !include schemas/property-descriptor.json
404:
description: 'Returned when the requested Role Path or Property does not exist. Corresponds to NcMethodStatus codes 404 and 502.'
body:
type: !include schemas/ms05-error.json
500:
description: 'Returned when the Datatype Descriptor of this object was unable to be retrieved. Corresponds to NcMethodStatus code 500.'
body:
Expand All @@ -177,6 +198,10 @@ documentation:
body:
example: !include ../examples/property-value-get-200.json
type: !include schemas/property-value-get.json
404:
description: 'Returned when the requested Role Path or Property does not exist. Corresponds to NcMethodStatus codes 404 and 502.'
body:
type: !include schemas/ms05-error.json
500:
description: 'Returned when the Property was unable to be retrieved. Corresponds to NcMethodStatus code 500.'
body:
Expand All @@ -191,6 +216,14 @@ documentation:
body:
example: !include ../examples/property-value-put-200.json
type: !include schemas/property-value-put-response.json
400:
description: 'Returned when the value arguments are invalid. Corresponds to NcMethodStatus code 417.'
body:
type: !include schemas/ms05-error.json
404:
description: 'Returned when the requested Role Path or Property does not exist. Corresponds to NcMethodStatus codes 404 and 502.'
body:
type: !include schemas/ms05-error.json
500:
description: 'Returned when the Property was unable to be set. Corresponds to the following NcMethodStatus codes: 405 if Property is read only, 417 if the value being PUT is invalid, 500 for all other reasons.'
body:
Expand Down

0 comments on commit 0fbbd45

Please sign in to comment.