Mastodon
Serve Mastodon's donation-campaign slot — instance donations settle on-chain, transparently.
What gets metered
an instance donation — Mastodon fetches its donation campaign from an external source; the sidecar serves that campaign JSON, and the campaign's donation_url routes donors through the rail (stake → grant → settle to the instance wallet).
- Who pays: the donor — stakes and grants at the campaign's
donation_urlvia@universal-paywall/agent - Who gets paid: the instance wallet named in the campaign
Attach surface — no fork
Mastodon's sanctioned external-data slot: set DONATION_CAMPAIGNS_URL to the provider. Mastodon GETs it (with platform, seed, locale, environment), caches it for 1 h, and renders the banner. We fill a slot the platform already fetches — no fork change.
Quickstart
Run the campaign provider (no facilitator needed — it only serves config; donations settle later at the donation_url):
PLATFORM=mastodon \
CAMPAIGN_DONATION_URL=https://donate.example/stake \
CAMPAIGN_BANNER_MESSAGE="Support this instance — settles onchain" \
CAMPAIGN_AMOUNTS='{"one_time":{"USD":[5,10,25]},"monthly":{"USD":[5]}}' \
npx up-integration
# on the Mastodon instance:
DONATION_CAMPAIGNS_URL=http://up-provider:8410/api/v1/donation_campaigns
DONATION_CAMPAIGNS_ENVIRONMENT=production
All values above are placeholders — supply your own facilitator, wallets, and rate.
The shared prerequisites (a deployed StakeVaultFactory, a running
facilitator, a wallet registry) are covered in the admin overview.
Verify
npm run e2e:mastodon -w @universal-paywall/integrations Serves the real-schema campaign, follows the donation_url to a donor stake/grant, and settles the donation through the rail to the instance wallet on-chain (instance funded 5,000,000 micro-USDC).
Notes & caveats
Links
- Recipe:
packages/integrations/deploy/mastodon/README.md— the authoritative attach instructions in the repo. - Testing plan — Mastodon full-stack L3 notes
- Integration Playbook — how integrations like this one are built.
- Testing plan — this platform's row in the L1→L4 matrix.