Skip to content

Platforms

However your site is built, the widget itself is the same — a few lines of code loading pybara-donate.iife.js. What differs is how those lines get in, and whether your site’s address can hold the DNS record the widget needs.

A site built by an AI agent — on Lovable, Replit, Base44, Caffeine, Bolt, … — is edited by prompting it, which is all the widget needs. A sentence is enough:

Add a Pybara donation widget.

and, if it matters, where: “…in the footer”, “…on my /support page”, “…in my brand colour”. The builder finds the widget here and on npm (@pybara/donate-widget), adds its script tag and its PybaraDonate.init() call with your site’s values, and lists the steps only you can do: your site in Pybara Wallet, its DNS record, and the terms (Setup).

For an exact result, use the prompt Pybara Wallet gives you instead: the last step of Setup shows your site’s snippet, with your principal and address already filled in, and a ready-made prompt to paste into your builder.

Two things to know on these platforms:

  • Custom domain required. A *.replit.app or *.lovable.app address cannot hold the _pybara-payto record. Attach your own domain first — every builder offers this — then set the site up in Pybara Wallet.
  • Content Security Policy. If the generated app sets one, point the agent at the allowances in the widget’s README.
  • Every option, machine-readable. The init options have a JSON Schema at /donate-widget/options.schema.json — an agent can validate the config it writes against it.

Site builders with embed blocks — Webflow, Squarespace

Section titled “Site builders with embed blocks — Webflow, Squarespace”

These take the same snippet in a custom-code or embed block:

  • Per page: an Embed element holding the <div>, the <script> tag and the PybaraDonate.init(…) call.
  • Site-wide: the builder’s custom-code setting (on Webflow, Site settings → Custom code), which usually needs a paid plan.

Any page, no platform:

<div id="pybara-donate"></div>
<script src="https://cdn.jsdelivr.net/npm/@pybara/donate-widget@beta/dist/pybara-donate.iife.js"></script>
<script>
PybaraDonate.init({
target: '#pybara-donate', // where the widget renders
recipientPrincipal: 'xxxxx-xxxxx-...', // your Pybara Wallet's principal
siteUrl: 'https://example.com', // your site's address
siteName: 'Example Charity', // the name donors see
});
</script>

Every option and its default is in Options.