A Graze API POST request that applies a list of external services to a specified Situation. Any other services already associated with the Situation are removed.
Back to Graze API EndPoint Reference.
Endpoint setSituationServices
takes the following request arguments:
Name | Type | Required | Description |
---|---|---|---|
| String | Yes | A valid |
| Number | Yes | Situation ID. |
| Array of Strings | Yes | A Javascript array of service names as text strings. If any services supplied do not exist in the database, the request creates them and assigns them to the Situation. |
Endpoint setSituationServices
returns the following response:
The behavior of this endpoint depends on whether the relevant alert or Situation is open, closed and still in the active database, or closed and archived to the historic database. This endpoint updates the alert or Situation as follows:
See API Update Behavior for more information on Situation statuses.
The following examples demonstrate typical use of endpoint setSituationServices
:
Example cURL request to [complete]:
curl -X POST -u graze:graze -k -v "https://localhost/graze/v1/setSituationServices" -H "Content-Type: application/json; charset=UTF-8" -d '{"sitn_id" : 8, "service_list" : ["Knowledge Management", "90nm Manufacturing"]}'