POST data

Uppdaterad 29/5/20 av Stephan Hale

Upload / Edit data

To be able to create a prediction and especially an automated one Quinyx needs to have data to be able to calculate trends and patterns. To be able to have guidelines or budgets for different levels of the organisation this data needs to be added to Quinyx as well.

Api-docs for rc : https://api-rc.quinyx.com/v2/docs

Api-docs : https://api.quinyx.com/v2/docs

POST /raw-data

This is the actual data for the variable that you want to use and have configured a forecast for. Raw data is sent to Quinyx through REST API and a POST call will add the raw-data to Quinyx.

Optional appendData=false string can be used to override the existing data if sent with same timestamp

  • ​externalForecastVariableId​ - External ID for the variable set up in Account settingsForecastVariablesExternal ID
  • ​externalUnitId​ - External ID for a unit as set up for units in Classic → Settings → Tables → integration keys
  • ​externalSectionId​ - External ID for a section as set up for units in Classic → Settings → Tables → integration keys
  • ​forecastDataPayload​ - Array of data and timestamp that will be uploaded
  • data - the amount of the variable to be posted
  • timestamp - The time of where the data should be allocated to ex 2019-09-03T17:00:00.000Z (UTC time should be used for consistency when it comes to time handling and timezones)
The time allocation works depending on the resolution set on the variable. Eg you have chosen a 15 minute resolution. That would mean that data sent with timestamp sent as 2019-09-03T17:00:00.000Z will be allocated to the "slot" 17:00-17:15. Data sent with timestamp sent as 2019-09-03T17:15:00.000Z will be allocated to the "slot" 17:15-17:30
Limit is set for 366 payloads per request. If more than 366 is sent in you will receive an error stating input is too large. You are also not allowed to use more than 5 concurrent requests (eg. running more than 5 threads simultaneously).

​POST /forecast-data

This is the forecast to be used as a budget or a forecast coming from a third party supplies for the variable that you want to use and have configured a forecast for. External forecast data is sent to Quinyx through REST API and a POST call will add the forecast-data to Quinyx.

Optional appendData=false string can be used to override the existing data if sent with same timestamp

  • ​externalForecastVariableId​ - External ID for the variable set up in Account settingsForecastVariablesExternal ID
  • ​externalUnitId​ - External ID for a unit as set up for units in Classic → Settings → Tables → integration keys
  • ​externalSectionId​ - External ID for a section as set up for units in Classic → Settings → Tables → integration keys
  • ​forecastDataPayload​ - Array of data and timestamp that will be uploaded
  • data - the amount of the variable to be posted
  • timestamp - The time of where the data should be allocated to.
The time allocation works depending on the resolution set on the variable. Eg you have chosen a 15 minute resolution. That would mean that data sent with timestamp sent as 2019-09-03T17:00:00.000Z will be allocated to the "slot" 17:00-17:15. Data sent with timestamp sent as 2019-09-03T17:15:00.000Z will be allocated to the "slot" 17:15-17:30
Limit is set for 366 payloads per request. If more than 366 is sent in you will receive an error stating input is too large. You are also not allowed to use more than 5 concurrent requests (eg. running more than 5 threads simultaneously).

POST ../edit-forecast

With this operation you can edit the calculated forecast through the API. Usage for this is if you want to edit a forecast configuration for a specific time with data you have externally and not to amend through the GUI in Neo Forecast.

Full URL is : /forecast-variables/{externalForecastVariableId}/forecast-configurations/{externalForecastConfigurationId}/edit-forecast?externalUnitId={externalUnitId}?externalSectionId={externalSectionId}

  • ​externalForecastVariableId​ - External ID for the variable set up in Account settingsForecastVariablesExternal ID
  • externalForecastConfigurationId - External ID for the configuration as set up in Account settingsForecastConfigurationExternal ID
  • ​externalUnitId​ - External ID for a unit as set up for units in Classic → Settings → Tables → integration keys
  • ​externalSectionId​ (optional) - External ID for a section as set up for units in Classic → Settings → Tables → integration keys
  • forecastDataModifier​
    • startTime - timestamp from what full hour the edit should be made on
    • endTime - timestamp to what full hour the edit should be made to
    • percentageModification - if you want to modify with a percentage value
    • newValueForPeriod - to set a new value for the chosen period.
newValueForPeriod : If data exists the new value will replace the current value as a percentage of the already existing values. If no value exists it will allocate the data evenly over the resolution of the variable
You are not allowed to use more than 5 concurrent requests (eg. running more than 5 threads simultaneously).


Fick du hjälp?