Commit 33525ce
committed
feat(adagents): directory inverse-lookup + divergence detector (Parts 2+3 of #749)
Squashed onto main to resolve conflicts with #753 (publisher_domains compact
form, revoked_publisher_domains) and main HEAD. Final state of this PR:
- fetch_agent_authorizations_from_directory: async wrapper for GET /v1/agents/
{agent_url}/publishers (per adcp#4823 / adcp#4828). Returns AgentDirectoryLookup
with spec-conformant envelope (agent_url, directory_indexed_at, publishers,
next_cursor). Accepts include=["properties"] to request per-publisher
property_ids[] (per adcp#4894).
- detect_publisher_properties_divergence: full (publisher_domain, property_id)
set-diff when directory returns property_ids[]; falls back to count-only
comparison against directories that haven't deployed adcp#4894 yet.
max_concurrency=20 default semaphore caps concurrent fetches at managed-
network scale. sample_size=200 default opt-in for full sweep.
- AgentPublisherEntry / AgentDirectoryLookup / PublisherDivergence /
DivergenceReport dataclasses; DiscoveryMethod / PublisherStatus Literal enums.
- AAO_PUBLISHER_DIRECTORY_URL env var supported (matches salesagent convention).
- Tests use respx.mock against spec-shaped JSON payloads.
Closes #749 Parts 2 and 3. Companion to #750 (Part 1: inline-resolution).1 parent 7545424 commit 33525ce
4 files changed
Lines changed: 1317 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
16 | 16 | | |
17 | 17 | | |
18 | 18 | | |
| 19 | + | |
| 20 | + | |
19 | 21 | | |
20 | 22 | | |
| 23 | + | |
21 | 24 | | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
22 | 28 | | |
23 | 29 | | |
24 | 30 | | |
25 | 31 | | |
| 32 | + | |
26 | 33 | | |
27 | 34 | | |
28 | 35 | | |
| |||
821 | 828 | | |
822 | 829 | | |
823 | 830 | | |
| 831 | + | |
| 832 | + | |
824 | 833 | | |
| 834 | + | |
825 | 835 | | |
| 836 | + | |
826 | 837 | | |
827 | 838 | | |
828 | 839 | | |
829 | 840 | | |
| 841 | + | |
830 | 842 | | |
| 843 | + | |
| 844 | + | |
831 | 845 | | |
832 | 846 | | |
833 | 847 | | |
| |||
0 commit comments