SDK reference · Python SDK
prov.identify.summary
prov.identify.summary in Python SDK.
Signature
prov.identify.summary(window: str = …) -> AnyParameters
windowstr
Request fields
windowenumquery- The window. One of
24h,7d,30d. bucketenumquery30mwithwindow=24h: 48 points of 30 minutes each instead of 24 of an hour. One of30m.
Returns
Any The summary.
HTTP operation
GET /v1/identify/decisions/summary: Summarize traffic
Errors
Example
const step1 = await (await fetch(`${process.env.PROVENANCE_API}/v1/identify/assessments`, {
method: "POST",
headers: { Authorization: "Bearer prv_test_acct_P9xN2vQ7bT4mW8sYd3cFjLh6gAe1kR5", "Content-Type": "application/json" },
body: JSON.stringify({
"request": {
"method": "GET",
"url": "https://harborbean.example/products",
"headers": {
"user-agent": "curl/8.7.1"
}
},
"ip": "35.180.4.77"
}),
})).json();
const trafficDecisionId = step1.id;
const data = await (await fetch(`${process.env.PROVENANCE_API}/v1/identify/decisions/summary?window=24h`, {
headers: { Authorization: "Bearer prv_test_acct_P9xN2vQ7bT4mW8sYd3cFjLh6gAe1kR5" },
})).json();import os
import httpx
api = os.environ["PROVENANCE_API"]
step1 = httpx.post(f"{api}/v1/identify/assessments", headers={"Authorization": "Bearer prv_test_acct_P9xN2vQ7bT4mW8sYd3cFjLh6gAe1kR5"}, json={
"request": {
"method": "GET",
"url": "https://harborbean.example/products",
"headers": {
"user-agent": "curl/8.7.1"
}
},
"ip": "35.180.4.77"
}).json()
traffic_decision_id = step1["id"]
data = httpx.get(f"{api}/v1/identify/decisions/summary?window=24h", headers={"Authorization": "Bearer prv_test_acct_P9xN2vQ7bT4mW8sYd3cFjLh6gAe1kR5"}).json()