Skip to main content

Overview

Shopping agents arrive at your site on behalf of real customers, but they usually look like regular visitors or anonymous bots. You can’t tell which visits are agents, who each one represents, or how to connect it to an existing account with its loyalty status and order history. Key challenges for merchants:
  • Seeing which visits are agents at all
  • Distinguishing an agent acting for a verified person from an anonymous bot
  • Recognizing the same customer when their agent returns
  • Connecting the agent to the customer’s existing account
  • Getting the details needed at checkout without collecting more than required
  • Supporting verified agents without disrupting checkout for everyone else
With KYA, you see every agent that visits and how strongly it’s identified. When an agent presents a credential, you check it in your own code and receive a stable, site-specific customer ID, the verification checks that passed, and any available fields your rules ask for. You then decide what the agent may do. Most stores adopt KYA in three steps. Each one is useful on its own:
  1. See every agent. Install in watch-only mode and see each agent visit and how strongly it’s identified. Nothing changes for shoppers.
  2. Recognize returning customers. When an agent presents a KYA credential, you get a customer ID that is stable at your site.
  3. Ask for proof at checkout. Require a credential, and the checks you need, before an agent can buy.

Will This Affect My Shoppers?

  • A new site starts watch-only, and nothing changes for visitors.
  • Baselayer never blocks anyone itself. Your rules decide what each kind of visitor gets, and the starting rules let people through.
  • Only visits detection finds to be automated are stored.
  • You can leave any page out of the tag.
  • If Baselayer can’t be reached, your pages keep working.

What happens when an agent arrives

These steps are for agents that carry a KYA credential. Agents without one are still seen and identified as far as the evidence goes, such as a declared platform or a signed request, and your rules decide what they may do. See Set Your Rules.
1

Your site asks for proof

A protected page returns 401 with a step-up that names the keys the credential must prove and the fields your rules ask for at that step.
2

The agent gets a credential

The agent gets a credential with no more than the fields your requirement lists.
3

The agent presents it

The agent gets a one-time nonce and sends the signed presentation to your token endpoint.
4

Your site checks it

Your site checks the credential, the agent’s signature, the audience, the nonce, the expiry, the revocation status and your requirement.
5

Your site decides

Your site connects the site-specific ID to your customer records and applies your own rules. For example, it can let any verified customer browse and require specific checks before checkout, such as a clear watchlist result. It returns an access token when appropriate.

What each party sees

What adopting takes

Email support@baselayer.com to get your keys and a sandbox to test in.
  • Install the tag, watch-only first. See Install Options.
  • Name the fields you ask for as scopes in your rules. See Asking for Fields.
  • Add a nonce route and a token route.
  • Check credentials in your own code. See the Credential Format Reference.
  • Store the site-specific customer ID with customer accounts.
  • Decide which actions require which proof. See Set Your Rules.
  • Log every credential check before letting the result change anyone’s access.

Recognizing returning customers

Your site receives a stable, site-specific ID for the person.
  • When an agent returns with another KYA credential for your site, the ID is the same across agents and sessions.
  • You can store it with the customer’s account and use it for loyalty, order history and cart recovery.
  • A different site receives a different ID for the same person.
See Matching Customers.

Next steps