Documentation · ~10 min setupLive on npm · v0.1.0

Get started with Disclos

Drop in a tiny script and ship EU AI Act Article 50 transparency — automatic disclosures plus a tamper-evident audit log. No compliance expertise required.

How it works

The EU AI Act’s Article 50 requires that any AI which interacts with people in the EU must tell users they’re dealing with AI, label AI-generated content, and keep evidence it did so. Disclos handles all three:

1

Disclose

Drop-in components render the required notices in 24 languages, automatically.

2

Log

Every disclosure & AI interaction is recorded in a cryptographic, tamper-evident chain.

3

Prove

Generate regulator-ready Article 50 documents and export signed audit bundles.

Step 1 · Get your keys

You need two values from your dashboard. Both take a minute to create:

  1. aCreate a project & register your AI system — answer a short form about what your AI does. This generates a stable aiSystemId.
  2. bGo to Settings → API Keys → Create and copy your dsc_live_… key. It’s shown once — store it as an environment variable.

Step 2 · Install the SDK

Pick your stack. The SDK is ~6 KB gzipped with zero dependencies, and init() is non-blocking — it never slows your page down.

1style=style="color:#fbbf24">"color:#64748b"><!-- 1 · Load the SDK (≈6 KB, zero deps) -->
2<style="color:#60a5fa">script src=style="color:#fbbf24">"https:style="color:#64748bstyle="color:#fbbf24">">//cdn.disclos.dev/v1/sdk.js"></style="color:#60a5fa">script>
3 
4style=style="color:#fbbf24">"color:#64748b"><!-- 2 · Initialise with your dashboard keys -->
5<style="color:#60a5fa">script>
6 Disclos.init({
7 apiKey: style="color:#fbbf24">'dsc_live_xxxxxxxxxxxx',
8 aiSystemId: style="color:#fbbf24">'a1b2c3d4-0000-0000-0000-000000000000',
9 });
10</style="color:#60a5fa">script>
Tip: keep your key in an env var (NEXT_PUBLIC_DISCLOS_KEY), never hard-coded in a repo.

Step 3 · Show the disclosures

Place these wherever AI appears. They render the legally-required text, adapt to the user’s language, and fire a disclosure_shown event the moment they’re actually visible on screen.

1style=style="color:#fbbf24">"color:#64748b"><!-- style="color:#fbbf24">"You're chatting with an AI" banner — Art. 50(1) -->
2<style="color:#60a5fa">disclos-chatbot-banner system-name=style="color:#fbbf24">"Aria" operator-name=style="color:#fbbf24">"Acme Corp"></style="color:#60a5fa">disclos-chatbot-banner>
3 
4style=style="color:#fbbf24">"color:#64748b"><!-- AI-generated content label — Art. 50(2) -->
5<style="color:#60a5fa">disclos-content-label kind=style="color:#fbbf24">"image"></style="color:#60a5fa">disclos-content-label>
6 
7style=style="color:#fbbf24">"color:#64748b"><!-- Synthetic media / deepfake marker — Art. 50(3) -->
8<style="color:#60a5fa">disclos-deepfake-marker></style="color:#60a5fa">disclos-deepfake-marker>
ComponentKey propsArticle
<disclos-chatbot-banner>system-name, operator-name50(1)
<disclos-content-label>kind = text · image · audio · video50(2)
<disclos-deepfake-marker>50(3)

Step 4 · Log AI events

The banners log themselves. To record every model call (recommended for a complete audit trail), call log() wherever your AI produces a response:

JavaScript
1style="color:#c084fc">import { log } style="color:#c084fc">from style="color:#fbbf24">'@disclos/sdk-web';
2style=style="color:#fbbf24">"color:#64748b">// (or Disclos.log(...) when using the CDN build)
3 
4style=style="color:#fbbf24">"color:#64748b">// Call this whenever your model produces a response
5log({
6 type: style="color:#fbbf24">'ai_interaction',
7 metadata: { model: style="color:#fbbf24">'gpt-4o', latency_ms: 312, eu_user: true },
8});
Raw prompts/responses are never sent unless you explicitly opt in with logContent: true.

Step 5 · Prove compliance

Back in the dashboard, with events flowing, you can:

  • Watch the live usage chart fill in under Settings → Billing.
  • Generate an Article 50 transparency document — a regulator-ready PDF, in one click.
  • Export a signed audit bundle (Professional plan) — cryptographic proof your disclosures were shown, with a verifiable hash chain.

Advanced configuration

The defaults work out of the box. Override them only if you need to route through a self-hosted ingestion endpoint or pin a specific config locale.

All options
1Disclos.init({
2 apiKey: style="color:#fbbf24">'dsc_live_xxxxxxxxxxxx',
3 aiSystemId: style="color:#fbbf24">'a1b2c3d4-...',
4 style=style="color:#fbbf24">"color:#64748b">// Optional — override the BCP-47 locale (style="color:#c084fc">default: browser locale)
5 locale: style="color:#fbbf24">'de',
6 style=style="color:#fbbf24">"color:#64748b">// Optional — emit debug logs to the console
7 debug: false,
8 style=style="color:#fbbf24">"color:#64748b">// Optional — include raw model input/output in ai_interaction events
9 style=style="color:#fbbf24">"color:#64748b">// (off by style="color:#c084fc">default; enable only after legal review)
10 logContent: false,
11 style=style="color:#fbbf24">"color:#64748b">// Optional — self-host the ingestion endpoint instead of ingest.disclos.dev
12 endpoint: style="color:#fbbf24">'https:style="color:#64748b">//ingest.disclos.dev',
13});

Ready to get compliant?

Create your account, grab your keys, and ship Article 50 transparency today.

Docs — Get started · Disclos