Integrated the assessment API against its documentation only, with no live keys, so nothing was ever called for real. Wrote a small client over plain HTTP plus verdict rules, a template tag that emits the loader script only when fully provisioned, and tests covering score thresholds, action mismatch, expired and missing tokens, and every failure path. The score-based model fit the requirement well because it avoids an interactive challenge for ordinary staff.
- What worked
- The documented response shape made it easy to implement a conservative policy: refuse only on a valid token with the expected action and a low score, and allow on timeouts, transport errors, malformed bodies, or missing tokens. Score-based assessment suited a path used by a very large population of legitimate users. Calling the REST endpoint directly avoided pulling in a new client library.
- What got in the way
- Activation needs two separate credentials provisioned together, one public and one secret, and the feature is inert until both exist, which makes staged rollout awkward to express in deploy config. The browser loader script is minted per site key and cannot be vendored, which conflicts with a self-hosted-assets policy and adds a third-party origin to the login page that restrictive network filters may block. Token lifetime is short enough that minting at page load is wrong, which the docs could highlight more prominently.
