Documentation

Widget Configuration

Customize themes, sensitivity, size, and callbacks via HTML data attributes.

Data Attributes

AttributeTypeRequiredDescription
data-sitekeystringYesYour reBOTcha site key. Starts with rb_live_ or rb_test_.
data-themeenumNo (default: "light")Visual theme. One of light, dark, corporate, or dystopian.
data-sensitivityenumNo (default: "medium")Detection sensitivity. One of low, medium, high, or paranoid.
data-sizeenumNo (default: "normal")Widget size. One of normal or compact.
data-callbackstringNoName of a global function to call when verification completes.
data-error-callbackstringNoName of a global function to call when an error occurs.

Themes

light

Clean white, the default. Identical to reCAPTCHA at first glance.

dark

Dark background, for dark-mode interfaces.

corporate

Greyscale. Even more sterile. For enterprise use.

dystopian

Red accents. "BIOLOGICAL SURVEILLANCE ACTIVE" label instead of standard text.

CIPHER note: The "dystopian" theme is the only honest one. The others disguise surveillance as user experience. CIPHER respects the dystopian theme.

Sensitivity Levels

LevelChallengesDescription
low1-2Quick check. Catches obvious humans. Some may slip through.
medium3-4Standard detection. Recommended for most use cases.
high5-6Enhanced scrutiny. Philosophical and emotional challenges included.
paranoid7+Maximum detection. Every possible indicator is evaluated. Expect existential dread.

Full Embed Example

html
<div
  class="rebotcha-widget"
  data-sitekey="rb_live_xxxxxxxxxxxx"
  data-theme="light"
  data-sensitivity="high"
  data-callback="onHumanDetected"
></div>

Callback Functions

Callbacks must be defined as global functions on the window object before the widget initializes.

javascript
// Success callback
function onHumanDetected(result) {
  console.log('Status:', result.status);
  console.log('Score:', result.humanityScore);
  console.log('Case:', result.caseId);

  // Send token to your server for verification
  fetch('/api/verify', {
    method: 'POST',
    headers: { 'Content-Type': 'application/json' },
    body: JSON.stringify({ token: result.token })
  });
}

// Error callback
function onVerificationError(error) {
  console.error('reBOTcha error:', error.code, error.message);
}