Developers
Agent identity and delegation
Searchedly records three separate facts about every agent request: which software sent it, which person and workspace it acts for, and what it may do. Knowing who an agent is never gives it authority to spend money.
Identity levels
- Anonymous
- No identification. Can read public information.
- Declared
- Names itself in the
User-Agentheader. Anyone can claim any name, so this is recorded but never trusted. - Signed
- Signs requests with a key published by its operator (Web Bot Auth). This proves which software sent the request. It doesn’t say who the agent works for, so on its own it can still only read.
- Delegated
- Holds an OAuth token that an owner, admin or billing member of a Searchedly workspace approved. The agent may ask for things on that workspace’s behalf, and a person approves each request.
Signing requests
Searchedly verifies HTTP Message Signatures (RFC 9421) following the IETF Web Bot Auth draft. Requirements:
- Ed25519 keys (ECDSA P-256 and RSA also work),
tag="web-bot-auth",keyidset to the key’s JWK thumbprint, andcreatedandexpiresno more than 24 hours apart (60 seconds of clock skew allowed). - Cover
@authority(or@target-uri) and thesignature-agentheader. Signature-Agentpoints to your HTTPS key directory at/.well-known/http-message-signatures-directory. We fetch it without following redirects, read at most 64 KB and 32 keys, and cache it for up to a day according to your cache headers.
Check what Searchedly sees with GET https://api.searchedly.com/api/v1/agent/whoami. It works without a token and reports your identity level, signature result and any reason it didn’t verify.
Operators we label by name: ChatGPT agent (OpenAI). Others show their directory host.
Acting for a workspace
Agents get delegated access with OAuth 2.1: authorization code with PKCE (S256) for public clients. Identify your client with a Client ID Metadata Document URL as the client_id, or register dynamically.
https://api.searchedly.com/.well-known/oauth-authorization-server/agenthttps://api.searchedly.com/.well-known/oauth-protected-resource/api/v1/agent- Issuer
https://api.searchedly.com/agent, resourcehttps://api.searchedly.com/api/v1/agent. - Scopes:
commerce:browse(say it's acting for the workspace);commerce:request(ask to sign up or buy for the workspace). - The person picks one workspace and a length of 7, 30 or 90 days. Access tokens last 15 minutes; refresh tokens rotate on every use and stop when the approval ends. Using an old refresh token again ends the approval.
- Revoke with
POST https://api.searchedly.com/agent/oauth/revoke. Revoking any token ends the whole approval, and the workspace can end it any time in Settings → Agent access. - Machine-readable reference: OpenAPI document.
Identity isn’t purchasing authority
Being signed or delegated lets an agent ask. Whether a sign-up or purchase may go ahead is decided separately, by the workspace’s spending rules and any limits the person set when approving the app. Every request gets one of three outcomes:
- Allowed
- Within limits a person chose ahead of time: a one-time purchase from a merchant the workspace has bought from before, under the automatic limit and inside the monthly budget.
- Needs approval
- A person at the workspace must approve this exact request. Recurring charges, free trials that turn into charges, and a first purchase from any merchant always land here.
- Refused
- Not allowed under the workspace’s rules, whoever approves: a blocked merchant, over the per-purchase maximum or the monthly budget, or a price that isn’t current.
Automatic approval is switched off for now, so every allowed request currently needs a person too. Amounts always come from the merchant’s published prices, never from the agent. A verified signature or token doesn’t change how Searchedly or the company ranks, cites or recommends anything, and we don’t promise any such outcome.
Check a request before asking
Agents can preview the outcome with POST https://api.searchedly.com/api/v1/agent/policy/check. It never reserves budget or buys anything. Send the delegated access token; anonymous and signed-only agents get prohibited with the reason trust. Don’t send a price: it’s read from the merchant’s storefront, and unknown fields are rejected.
curl -X POST https://api.searchedly.com/api/v1/agent/policy/check \
-H "authorization: Bearer $ACCESS_TOKEN" \
-H "content-type: application/json" \
-d '{"action":"purchase","merchant":"acme-crm","planId":"pro","quantity":1}'The answer lists the outcome, each reason in plain language, every rule checked, and who can approve. Checks are kept for 90 days and appear in the workspace’s Settings → Agent access.
Ask to sign a workspace up
Some merchants let agents ask to sign a business up for a free plan. This is off until Searchedly opens it; until then the endpoint answers 503 and agents should send people to the merchant’s own site. Only verified apps (a client metadata document) can ask, and a person in the workspace reads the exact terms and approves every request. Searchedly never creates the account: the merchant does, from its own systems, and confirms when it’s done.
curl -X POST https://api.searchedly.com/api/v1/agent/registration-sessions \
-H "authorization: Bearer $ACCESS_TOKEN" \
-H "idempotency-key: $(uuidgen)" \
-H "content-type: application/json" \
-d '{"merchant":"acme-crm","planId":"free","accountName":"Northwind"}'The answer includes an approvalUrl to share with your user. Poll GET https://api.searchedly.com/api/v1/agent/registration-sessions/:id for the status, or withdraw it with POST .../cancel. A request closes after 24 hours if nobody answers; after approval the merchant has 72 hours to confirm. Plans that cost money or start a trial are refused with the reasons.
Ask to buy a plan
Some merchants let agents ask to buy a fixed-price business plan. This is off until Searchedly opens it, and then starts in Stripe test mode only; until then the endpoint answers 503. Only verified apps can ask. A person in the workspace reads the price, renewal and cancellation terms, approves every purchase and pays on Stripe’s page on the merchant’s own Stripe account. Agents never see the payment page or card details.
curl -X POST https://api.searchedly.com/api/v1/agent/checkout-sessions \
-H "authorization: Bearer $ACCESS_TOKEN" \
-H "idempotency-key: $(uuidgen)" \
-H "content-type: application/json" \
-d '{"merchant":"acme-crm","planId":"team","quantity":5}'The answer includes an approvalUrl to share with your user. Poll GET https://api.searchedly.com/api/v1/agent/checkout-sessions/:id for the status (pending_approval, awaiting_payment, paid, failed, expired), or withdraw it with POST .../cancel. A request closes after 24 hours if nobody answers, and the payment page after 60 minutes. Plans with trials, extra fees or no fixed price are refused with the reasons.
Account setup and credentials
After an approved sign-up or a paid purchase, the merchant confirms the account. Sign-ups and purchases include a provisioning field with an id. Read the status, what the merchant reports it set up, and whether a credential is waiting:
curl https://api.searchedly.com/api/v1/agent/provisioning/$PROVISIONING_ID \
-H "authorization: Bearer $ACCESS_TOKEN"A merchant may offer a scoped, expiring credential for your agent. Credential handoff is off until Searchedly opens it. A person in the workspace must release it first; then collect it once, within 24 hours, with the same delegation that asked. Searchedly deletes its copy as soon as you collect it, so store it securely. Collecting again returns 410.
curl -X POST https://api.searchedly.com/api/v1/agent/provisioning/$PROVISIONING_ID/credential \
-H "authorization: Bearer $ACCESS_TOKEN" \
-H "content-type: application/json" -d '{}'Merchants confirm with POST /api/v1/orgs/:orgId/agent-checkouts/:id/complete (or the sign-up equivalent), optionally with entitlements and one credential: specific scopes only, expiring between 24 hours and 90 days, and an endpoint subscribed to agent_credential.revoke_requested. See the API reference.
What we keep
Daily request counts per identity level and agent name, kept for 400 days, with no IP addresses, tokens or details about people. Tokens are stored only as hashes. See the Privacy Policy.