Menu

1 / 2

Embed Badge Verification on Your Website (No Iframe, No SDK)

DEV Community: api·Nacho@BWS·3 days ago
#qm06HwLn
#devtoapi#devto#dev#assertion#badge
Long article (1522 words) — no AI summary yet.
Reading 0:00
15s threshold

If you issue credentials, sooner or later someone asks: "how do I know this badge is real?" The honest answer should never be "trust the PNG." Open Badge v2.0 solves this with a public, machine-readable verification endpoint, and putting a "Verified" widget on your own site takes about ten lines of code. No iframe, no third-party embed script, no SDK.

This post shows how to call the endpoint and render the result in vanilla JavaScript, Node, and Python. It also covers what "verification" actually checks, and the mistakes that make a widget look done while proving nothing.

What "verified" actually means

An Open Badge v2.0 assertion is a JSON-LD document with a fixed shape: the assertion itself (who received it, when), a reference to the BadgeClass (what it is, who defines the criteria), and a reference to the issuer profile (who is vouching for it). Verifying a badge means checking three separate things:

Does the assertion exist and resolve.…

Continue reading — create a free account

Join HashtagPLUS to read full articles, follow hashtags, vote, and join the conversation.