Update Multiple Statuses for One or More KPIs, Quarter Priorities, Annual Priorities, or Winning Moves

Update one or more statuses in a single call. Each status can be for a different KPI, Quarter Priority, Annual Priority, or Winning Move, or you can include multiple statuses (each for a different time period) for a single KPI, Quarter Priority, Annual Priority, or Winning Move, or any combinations thereof.

Method Details

HTTP Methods: POST

HTTP Methods: https://api.rhythm.cloud/api/public/goal/status

Content Type: application/json

Response Format: json

Requires Authentication? Yes

Headers User-Agent

Required Parameters

Http header: Bearer {token}

In Body JSONArray of JSONObjects, each JSONObject containing (all values as strings):

id: ID of the KPI, Quarter Priority, Annual Priority, or Winning Move that the status is for

year: 4 digit year

quarter: 1 - 4

week: 1 - 13

date: yyyy-MM-dd (required for KPIs and Quarter Priorities if year/quarter/week is not supplied, and for all Annual Priorities and Winning Moves)

(Note: if year, quarter, and week are all specified, the date field will be ignored; if either year, quarter, or week is not specified, date will be used to derive the year, quarter, and week for the status)

color: supergreen|green|yellow|red|s|g|y|r (case insensitive)

projected: the projected value for the week

actual: the actual value for the week

variance: the variance for the week

(Note: All settings for KPIs, Quarter Priorities, Annual Priorities, and Winning Moves will be respected. E.g. if it is set for Auto Status Color, then color will be ignored and auto derived by Rhythm; or if Variance is set to Auto, the variance will be ignored and auto calculated by Rhythm)

comment: a comment to be created together with the update.

Any field not supplied will not be affected by the update. If you want to set a field to null, then a "NULL" string must be passed in explicitly.

Response

If all items in the request were processed successfully, you will receive a http code 200 (OK), with a JSON of {"success":true} in the response body.

If the access token has expired, you will receive a http code 401 (unauthorized).

If some items in the request processed successfully, and some failed, you will receive a http code 202 (Accepted). If all items in the request failed, the API call will result in a http code 400 (bad request). In both these instances, the response body will contain a JSON array, where each JSON Object contains additional information about the failed item, the following format:

[{

"error": "error code used by Rhythm Systems for further trouble shooting",

"error_description": "description of the error encountered in the API call",

"data": "{the data received by Rhythm in your API call}"

},

{

"error": "error code used by Rhythm Systems for further trouble shooting",

"error_description": "description of the error encountered in the API call",

"data": "{the data received by Rhythm in your API call}"

}]

Request Body Sample

[{

  "id": "XXX",

  "year":"2022",

  "quarter":"4",

  "week":"12",

  "date":"2022-12-21",

  "color":"red",

  "projected":"13.2",

  "actual":"5.2",

  "variance":"-7",

  "comment":"red comment"

},

{

  "id": "YYY",

  "year":"2022",

  "quarter":"4",

  "week":"12",

  "date":"2022-12-21",

  "color":"red",

  "projected":"13.2",

  "actual":"5.2",

  "variance":"-7",

  "comment":"red comment"

}]