Get Correlation Results
Retrieve results of the correlation of our event data with your transactional demand data.
Enter your PredictHQ API key. The Bearer prefix is added automatically.
When calling the API directly, send: 'Authorization: Bearer <YOUR_API_KEY>' as documented at https://docs.predicthq.com/authentication
An existing Beam Analysis ID.
Filters results after the specified date (exclusive).
2017-01-01Filters results on or after the specified date.
2017-01-01Filters results before the specified date (exclusive).
2025-01-07Filters results on or before the specified date.
2025-01-07Offset the results.
0Limit the number of results.
10Successful Response
Missing/invalid date parameters or Feature impact is outdated. Analysis needs to be refreshed
Bearer token scope insufficient
Analysis or Derivative not found
Validation Error
Internal inconsistency detected. Please refresh the analysis
GET /v1/beam/analyses/{analysis_id}/correlate HTTP/1.1
Host: api.predicthq.com
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
{
"model_version": "text",
"version": 1,
"count": 1,
"dates": [
{
"date": "2021-01-01",
"baseline_demand": 1642.8505673206673,
"remainder": 4250.149432679333,
"actual_demand": 5893,
"impact_significance": "NO_IMPACT",
"impact_significance_score": 0
}
]
}Examples
curl -X GET "https://api.predicthq.com/v1/beam/analyses/$ANALYSIS_ID/correlate?date.gte=2022-01-01&date.lte=2022-12-31" \
-H "Accept: application/json" \
-H "Authorization: Bearer $ACCESS_TOKEN"import requests
response = requests.get(
url="https://api.predicthq.com/v1/beam/analyses/$ANALYSIS_ID/correlate",
headers={
"Authorization": "Bearer $ACCESS_TOKEN",
"Accept": "application/json"
},
params={
"date.gte": "2022-01-01",
"date.lte": "2022-12-31"
}
)
print(response.json())OpenAPI Spec
The OpenAPI spec for Beam API can be found here.
Guides
Below are some guides relevant to this API:
Last updated
Was this helpful?