Schedule a baseline forecast on Planning Analytics Local
Use these commands when scheduling a baseline forecast on Planning Analytics Local.
Procedure
-
To run the baseline endpoint:
curl --location --request POST 'http://<paw_local>/<baseline_url>' --header 'Authorization: Basic base64(<username>:<password>)'When SSL is configured, pass the certificates with the
curlcommand (recommended) or use the-koption to disable it. Once a baseline forecast is started, the status of the baseline asset changes to running. After the forecast is complete, it goes back to ready. While a forecast is running on a baseline asset, another forecast cannot be started unless the first one is complete and the asset returns to ready status. - To check the baseline status endpoint:
curl 'http:// <paw_local> /api/v0/predict/api/v1/BaselineStatus/<baselineID> ' --header 'Authorization: Basic base64(<username>:<password>)' - If a baseline forecast gets stuck while running, you can reset the status back to ready:
curl --location --request POST 'http://<paw_local>/api/v0/predict/api/v1/ResetBaseline/<baselineID>' --header 'Authorization: Basic base64(<username>:<password>)' - To override context members, statistical details cube slices, and sets, you must send a
payload (request body) with the RunBaseline endpoint. To run the basement endpoint:
curl --location --request POST 'http://<paw_local>/<baseline_url>' --header 'Authorization: Basic base64(<username>:<password>)' -H "Content-Type: application/json" -d ‘json_payload_containing_sets_and_context’The following is an example payload:
{ "serverName": "Planning Sample", "statCubeSlice": " [ForecastResultRun].[ForecastResultRun].[3]”, "sets": [ { "set": "all_leaves", "dimensionID": "Sample_members", "setIsOverridden": true, "hierarchyID": "Sample_members", "hierarchy": "Sample_members", "name": "Sample_members", "member": "all_leaves", "setType": "NAMED_SET", "mdx": "{{TM1FILTERBYLEVEL(TM1SUBSETALL([Sample_members].[Sample_members]) , 0)}}" } ], "context": [ { "dimensionID": "test_version", "hierarchyID": "test_version", "hierarchy": "test_version", "name": "test_version", "member": "Forecast", "contextIsOverridden": true, "setType": "UNNAMED_SET", "mdx": "{[test_version].[test_version].[Forecast]}" }, { "dimensionID": "Months-Consolidated", "hierarchyID": "Months-Consolidated", "hierarchy": "Months-Consolidated", "name": "Months-Consolidated", "member": "1", "contextIsOverridden": true, "setType": "UNNAMED_SET", "mdx": "{[Months-Consolidated].[Months-Consolidated].[1]}" } ] }