FidemarkBadge
A 4 KB embed that renders the verification status of any Fidemark attestation as a compact pill, click-through to the full verify page.
npm install @fidemark/badgeimport { FidemarkBadge } from "@fidemark/badge";
<FidemarkBadge uid="0xabc…" theme="light" />Props:
| Name | Type | Default |
|---|---|---|
uid | string | required |
apiBase | string | https://verify.fidemark.dev |
theme | "light" | "dark" | "light" |
The component fetches ${apiBase}/api/attestation/${uid} once per uid. While loading: shows “verifying…”. On success: pill with status. On error: red pill with the error message.
Web Component (vanilla HTML / Vue / Svelte / etc.)
Section titled “Web Component (vanilla HTML / Vue / Svelte / etc.)”The Web Component bundle is published to npm as @fidemark/badge and can be loaded straight from a public CDN. The snippet below pins to a major version on jsDelivr, so patch and minor releases land automatically while breaking changes do not:
<script type="module" src="https://cdn.jsdelivr.net/npm/@fidemark/badge@^0.1/dist/web-component.js"></script>
<fidemark-badge uid="0xabc…" theme="dark"></fidemark-badge>Pin to an exact version (@fidemark/[email protected]) if you prefer reproducible deploys, or self-host the file from your own bundler / static origin if you would rather not depend on a public CDN, the package ships a ready-to-serve dist/web-component.js (ESM) and dist/web-component.global.js (IIFE for plain <script> tags).
Attributes:
| Name | Default |
|---|---|
uid | required |
api-base | https://verify.fidemark.dev |
theme | light |
The web component is fully self-contained: its styles live in a Shadow DOM root and don’t leak into the host page. No React or framework runtime needed.
What it shows
Section titled “What it shows”| Attestation state | Pill content |
|---|---|
| Valid Human Proof | ✓ Human Proof |
| Valid Human Proof, ENS-verified | ✓ Human Proof (ENS) |
| Valid AI Proof | ✓ AI Proof · <modelId> |
| Revoked | ✗ Revoked |
| Lookup error | ⚠ <error message> |
Clicking the badge opens the verify page in a new tab.