Skip to content

Commit

Permalink
Fix examples in line with the latest models
Browse files Browse the repository at this point in the history
  • Loading branch information
cristian-recoseanu committed Sep 9, 2024
1 parent dccaa7c commit 1c22171
Showing 1 changed file with 6 additions and 11 deletions.
17 changes: 6 additions & 11 deletions docs/API requests.md
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ This is equivalent to invoking the generic [Set method](https://specs.amwa.tv/ms
The PUT verb MUST be used for setting a bulk properties data set.

The URL MUST target a specific role path.
The body of the request MUST include an object which includes an `arguments` object with `dataSet` and `recurse` sub elements.
The body of the request MUST include an object which includes an `arguments` object with `dataSet`, `recurse` and `propertyTraits` sub elements.

```json
{
Expand All @@ -125,7 +125,7 @@ The body of the request MUST include an object which includes an `arguments` obj
...
},
"recurse": true,
"allowIncomplete": true
"propertyTraits": null
}
}
```
Expand All @@ -134,17 +134,11 @@ If the `recurse` value is `true` then the device will attempt to use the provide

For a full schema of the required body object see the [bulkProperties-set-request](https://specs.amwa.tv/is-14/branches/v1.0-dev/APIs/schemas/bulkProperties-set-request.json) schema.

The response MUST be of type [NcMethodResultObjectPropertiesSetValidation](https://specs.amwa.tv/nmos-control-feature-sets/branches/publish-device-configuration/device-configuration/#ncmethodresultobjectpropertiessetvalidation). If the request encountered an error then the response result returned MUST inherit from [NcMethodResultError](https://specs.amwa.tv/ms-05-02/latest/docs/Framework.html#ncmethodresulterror) and include an errorMessage of type [NcString](https://specs.amwa.tv/ms-05-02/latest/docs/Framework.html#primitives). If devices cannot accept restore requests due to temporary internal constraints (e.g. requires to be in maintenance mode) then they MUST use a status of `NotReady` and supply further details on the reason for this in the errorMessage.
The response MUST be of type [NcMethodResultObjectPropertiesSetValidation](https://specs.amwa.tv/nmos-control-feature-sets/branches/publish-device-configuration/device-configuration/#ncmethodresultobjectpropertiessetvalidation). If the request encountered an error then the response result returned MUST inherit from [NcMethodResultError](https://specs.amwa.tv/ms-05-02/latest/docs/Framework.html#ncmethodresulterror) and include an errorMessage of type [NcString](https://specs.amwa.tv/ms-05-02/latest/docs/Framework.html#primitives). If devices cannot accept restore requests due to temporary internal constraints then they MUST use a status of `NotReady` and supply further details on the reason for this in the errorMessage.

This is equivalent to invoking the `SetPropertiesByPath` method inside the [Bulk properties manager object](https://specs.amwa.tv/nmos-control-feature-sets/branches/publish-device-configuration/device-configuration/#ncbulkpropertiesmanager).

Setting properties through the `bulkProperties` endpoint allows a user to perform a restore or a `selective restore`. The restore action can result in a `complete restore` or an `incomplete restore`.

A `complete restore` occurs when a [full backup](Backup%20&%20restore.md#definitions) is applied as a `PUT` to the `/bulkProperties` endpoint of the root block with the `recurse` argument set to true, and all the properties of all role paths in the data set are applied successfully (their returned validation status is `Ok`). A `complete restore` can also occur when a [partial backup](Backup%20&%20restore.md#definitions) is applied and all the properties of all role paths in the data set are applied successfully (their returned validation status is `Ok`). An [incomplete restore](Backup%20&%20restore.md#definitions) occurs when any of the properties restored returns a validation status other than `Ok`.

A `selective restore` is a restore in which a [full backup](Backup%20&%20restore.md#definitions) or a [partial backup](Backup%20&%20restore.md#definitions) is applied as a `PUT` to the `/bulkProperties` endpoint of a role path which is not the root block. A selective restore can also be achieved by a `PUT` operation to the `/bulkProperties` endpoint of the root block with the `recurse` query parameter set to false which will result in restoring the properties of the root block only.


Setting properties through the `bulkProperties` endpoint allows a user to perform a restore.

## PATCH

Expand Down Expand Up @@ -192,7 +186,8 @@ The body of the request MUST include an object which includes an `arguments` obj
"dataSet": {
...
},
"recurse": true
"recurse": true,
"propertyTraits": null
}
}
```
Expand Down

0 comments on commit 1c22171

Please sign in to comment.