diff --git a/agentscore/types.py b/agentscore/types.py index c1ef3a9..dea6acb 100644 --- a/agentscore/types.py +++ b/agentscore/types.py @@ -3,7 +3,7 @@ from typing import Literal, TypedDict Grade = Literal["A", "B", "C", "D", "F"] -EntityType = Literal["agent", "service", "hybrid", "wallet", "bot", "unknown"] +EntityType = Literal["agent", "service", "hybrid", "wallet", "bot", "unknown", "individual", "entity"] ReputationStatus = Literal["scored", "stale", "known_unscored"] VerificationLevel = Literal["none", "wallet_claimed", "kyc_verified"] @@ -146,6 +146,18 @@ class OperatorVerification(_OperatorVerificationRequired, total=False): verified_at: str | None +class PolicyCheck(TypedDict, total=False): + rule: str + passed: bool + required: object + actual: object + + +class PolicyResult(TypedDict): + all_passed: bool + checks: list[PolicyCheck] + + class DecisionPolicy(TypedDict, total=False): min_grade: Grade min_score: int @@ -176,3 +188,4 @@ class AssessResponse(_AssessResponseRequired, total=False): operator_verification: OperatorVerification resolved_operator: str verify_url: str + policy_result: PolicyResult | None diff --git a/pyproject.toml b/pyproject.toml index 4e09ae7..0403c36 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -4,7 +4,7 @@ build-backend = "hatchling.build" [project] name = "agentscore-py" -version = "1.4.0" +version = "1.4.1" description = "Python client for the AgentScore trust and reputation API" readme = "README.md" license = "MIT" diff --git a/uv.lock b/uv.lock index 125e147..1f335d4 100644 --- a/uv.lock +++ b/uv.lock @@ -8,7 +8,7 @@ resolution-markers = [ [[package]] name = "agentscore-py" -version = "1.4.0" +version = "1.4.1" source = { editable = "." } dependencies = [ { name = "httpx" },