Skip to content

Commit 1c36f46

Browse files
committed
docs/tests: scrub internal merchant references + private test default
- agentscore_commerce/identity/policy.py: drop the "extracted from <internal merchant>" attribution paragraph - examples/per_product_policy_merchant.py: drop the same attribution - tests/test_integration.py: integration tests now require both AGENTSCORE_API_KEY and AGENTSCORE_BASE_URL to be set; no default to a private (`*.internal`) endpoint
1 parent ee2347a commit 1c36f46

3 files changed

Lines changed: 7 additions & 10 deletions

File tree

agentscore_commerce/identity/policy.py

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -21,10 +21,8 @@
2121
return a structured :class:`GateResult`.
2222
2323
All three are additive — vendors that don't need per-product policy can keep
24-
using ``AgentScoreGate(...)`` directly. The pattern was extracted from the
25-
``agentscore/store`` merchant; see its ``store/routes/purchase.py`` for the
26-
full per-request flow including shipping checks (which most merchants will
27-
implement adjacent to the gate).
24+
using ``AgentScoreGate(...)`` directly. Most merchants will implement shipping
25+
checks adjacent to the gate per-request.
2826
"""
2927

3028
from __future__ import annotations

examples/per_product_policy_merchant.py

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -17,10 +17,6 @@
1717
- shipping_country_allowed / shipping_state_allowed
1818
Per-product shipping allowlists (NULL = ship anywhere).
1919
20-
The pattern was extracted from agentscore/store. See its
21-
``store/routes/purchase.py`` for the full per-request flow including code
22-
redemption + order persistence.
23-
2420
Peer deps:
2521
pip install agentscore-commerce[fastapi]
2622

tests/test_integration.py

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,13 @@
44
import pytest
55

66
API_KEY = os.environ.get("AGENTSCORE_API_KEY")
7-
BASE_URL = os.environ.get("AGENTSCORE_BASE_URL", "http://api.dev.agentscore.internal")
7+
BASE_URL = os.environ.get("AGENTSCORE_BASE_URL")
88
TEST_ADDRESS = "0x339559a2d1cd15059365fc7bd36b3047bba480e0"
99

10-
pytestmark = pytest.mark.skipif(not API_KEY, reason="AGENTSCORE_API_KEY not set")
10+
pytestmark = pytest.mark.skipif(
11+
not (API_KEY and BASE_URL),
12+
reason="AGENTSCORE_API_KEY and AGENTSCORE_BASE_URL must both be set",
13+
)
1114

1215

1316
def _assess(body=None):

0 commit comments

Comments
 (0)