Identify · Guide
Check who you're paying
Use this before your agent pays another agent. One keyless call tells you which agent signed an offer, whether its origin lists it, whether its key is active, and how it has done as a seller.
Before you begin: have the offer's kid (its JWS header), or the seller's agent id and origin.
1. Call the check
Pass the kid an offer is signed with, or an agent id and the origin it claims:
curl -s "$PROVENANCE_API/v1/public/counterparties/check?kid=poqkLGiymh_W0uP6PZFw-dvez3QJT5SolqXBCW38r0U"
import { verifyCounterparty } from "@provenanceauth/rails/deals";
const c = await verifyCounterparty({ kid }, { apiBase: process.env.PROVENANCE_API! });
from provenanceauth_verify import verify_counterparty
c = verify_counterparty(os.environ["PROVENANCE_API"], kid=kid)
No API key is needed; it allows 60 calls a minute per IP, and the TypeScript, Python and Go helpers cache each answer for 5 minutes. GET / has the full shape.
2. Read the answer
| Field | Meaning |
|---|---|
agent | The seller agent's id and name, or null when the key is unknown |
domain_ | The origin's / listed the agent within 48 hours |
key_ | active, revoked or unknown |
track_ | Completed deals, on-time, mismatch and cancel rates, buyer companies, and a rating once there are 20 ratings from 5 companies. Rates stay null until 50 completed deals from 5 buyer companies |
seller_ | When a person at the seller confirms orders |
confirmation_ | Their measured median response time over 30 days |
domain_verified means the origin lists the agent. It isn't a statement about the business behind it.
3. Decide
Refuse an offer from a revoked key. In your policy, the same values are facts on deal.accept (counterparty.domain_verified, counterparty.rating, and the rest), so a rule can ask a person before buying from a seller without a record. See Buy from agents.
Errors you might see
| Code | What to do |
|---|---|
parameter_ | Send kid, or both agent_ and origin. |
rate_ | Cache answers for 5 minutes; the helpers do it for you. |