SDK reference · Python SDK
prov.identify.list_assessments
prov.identify.list_assessments in Python SDK. The recorded hosted checks, newest first.
Signature
prov.identify.list_assessments(outcome: Optional[str] = …, class_: Optional[str] = …, signed: Optional[bool] = …, bot_likelihood: Optional[str] = …, created_gte: Optional[str] = …, created_lte: Optional[str] = …, limit: Optional[int] = …, cursor: Optional[str] = …, **query: Any = …) -> AnyParameters
outcomeOptional[str]class_Optional[str]signedOptional[bool]bot_likelihoodOptional[str]created_gteOptional[str]created_lteOptional[str]limitOptional[int]cursorOptional[str]**queryAny
Request fields
limitintegerquery- Page size, 1–100 (default 20). Outside the range → 400 parameter_invalid.
cursorstringquery- Opaque; pass a response's
next_cursorback to get the next page. outcomearray of enumsquery- Only assessments with these decisions (
decision.action). One value, or several separated by commas. classarray of enumsquery- Only these classes. One value, or several separated by commas: an agent is
signed_agent,declared_botorsuspected_bot; a person islikely_human. signedenumquery- Only visits whose agent signature verified (
true), or didn't (false). One oftrue,false. bot_likelihoodarray of enumsquery- Only these bot likelihood bands. One value, or several separated by commas.
created_gtetimestampquery- Assessed at or after this time.
created_ltetimestampquery- Assessed at or before this time.
Returns
Any The assessments.
HTTP operation
GET /v1/identify/assessments: List traffic assessments
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"
}
}
}),
})).json();
const data = await (await fetch(`${process.env.PROVENANCE_API}/v1/identify/assessments`, {
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"
}
}
}).json()
data = httpx.get(f"{api}/v1/identify/assessments", headers={"Authorization": "Bearer prv_test_acct_P9xN2vQ7bT4mW8sYd3cFjLh6gAe1kR5"}).json()