HostDeFi › Features › Integrate
Put a token risk read — or a whole swap — inside your product
The integrate hub is one page with four self-serve surfaces: an embeddable safety badge, a swap buy button, a keyless risk API, and a fee-share referral program. Nothing here needs a sales call.
If you run a token page, a dashboard, a blog or a bot, there is a HostDeFi surface sized to the slot you have: a 20-pixel shield that cites a graded risk score, a full swap widget that pays you per trade, an API your backend can call with no key at all, and a referral link that turns distribution into revenue. All four are documented below — what each one is, when to reach for it, and what it costs (mostly: nothing).
Which surface answers which need
| What your page needs | Use | Weight |
|---|---|---|
| "Show readers this token's risk grade" | Safety badge — SVG shield, iframe card or JSON | One img tag |
| "Let readers buy the token right here" | Buy button — the embedded swap, your contract pinned | One iframe |
| "Score tokens inside my own app" | Risk API — keyless scans, graded verdicts, batch on paid | One fetch |
| "Get paid for the traders I bring" | Referrals — 50% of the swap fee, up to 80% at volume | One link |
The safety badge — a grade that cites its source
An embeddable shield showing a token's stored HostDeFi grade, A+ to F, scored openly from on-chain data. It renders as a plain image (READMEs and forums included), as a small iframe card carrying the authority flags and liquidity figure, or as JSON for your own UI. Ungraded tokens get an honest "not graded" — the badge never invents a score. The badge page has the formats and the rules; the builder on /integrate writes your snippet, and deep links like /integrate?chain=base&address=0x… land with it pre-filled.
The buy button — the swap, framed
An iframe of the real swap — Jupiter-routed on Solana, KyberSwap-routed on EVM chains — with your token's contract pinned so the buy side can't be flipped to a lookalike. The visitor's wallet signs inside the frame; your site never touches funds. Add your wallet to the builder and the same embed earns the referral share. Details and caveats (including the cookie caveat on Solana attribution) are on the buy-button page.
The risk API — keyless first, paid when you outgrow it
POST /api/scan answers a free live scan (100 checks per day per IP, honest 429s after that), and /v1/token-risk serves the graded verdict — numeric score, A+–F grade, what is known and what isn't — CORS-open for browser and backend alike. When a bot or dashboard needs more, paid keys are bought the crypto-native way: send SOL from any wallet, paste the transaction signature, and the key mints once the payment confirms on-chain — no card form, no account. Builder runs 0.15 SOL for 7 days of 10,000 calls; Pro is 0.5 SOL for 30 days at 60,000 plus batch scoring; Scale is 1.5 SOL for a year at 750,000 plus batch. Endpoints and response shapes live in the API docs; the product story is on the API page.
Referrals — the surface that pays you
Every trader you bring earns you half of the flat 1% swap fee — 0.5% of their volume — stepping up to 80% of the fee as your referred volume climbs tiers. On Solana the share accrues to your wallet through the referrals ledger; on referral-enabled EVM chains it's paid on-chain inside the swap itself, so there is no claim step. The badge and the buy button both bind your wallet the same way — integration and monetization are one paste. The math and the tiers are on the referrals page.
Open data — citable by design
The weekly safety snapshot ships as a CC BY 4.0 dataset — every graded token's score, flags and liquidity, free to cite or build on. If your work needs the evidence rather than the badge, that is the file.
The honest limit: badges and the graded endpoints serve the stored corpus grade — a weekly snapshot, dated, not a same-second audit. If your integration needs the read now (a fresh launch, a flag that flipped an hour ago), call the scanner — POST /api/scan is the live path. And whatever surface you embed: never alter a badge to imply a grade the corpus didn't give. The trust is the product.
Choosing what to embed?
Start with the token's own grade — scan it here, then pick the surface that fits your page.
Frequently asked
Do any of these integrations need an account or API key?
The badge, the buy button and the free API tier are all keyless — no signup, no dashboard, nothing to provision. Only the paid API tiers issue a key, and even that is bought on-chain: send SOL, paste the transaction signature, the key mints.
Which integration should I pick for a token page?
For a token team's own page the pair works best together: the safety badge shows the graded risk read up top, and the buy button lets a convinced reader act without leaving. Add your wallet to the buy button and the same embed also pays you the referral share on every swap.
How does the fee share actually pay out?
On Solana your referral wallet accrues half of the 1% swap fee through the referrals program — climbing to 80% as the volume you refer climbs. On referral-enabled EVM chains the share is paid on-chain inside the swap transaction itself, so there is nothing to claim. Monad is the exception: it pays no referral share today.
Is there a paid tier, and what does it add?
Yes — paid API keys bought in SOL raise quota and unlock batch scoring for bots and dashboards. Builder is 0.15 SOL for 7 days (10,000 calls), Pro is 0.5 SOL for 30 days (60,000 calls plus batch), Scale is 1.5 SOL for a year (750,000 calls plus batch). The free tier never lies about why it says no — it just rate-limits honestly.
Can I white-label the widgets?
Themed or badge-free builds are a conversation, not a self-serve button — everything you can generate on the integrate page ships with HostDeFi attribution, which is what makes the grade trustworthy to your readers in the first place.
What data can I use for free?
All of it: the keyless scanner endpoint, the graded token JSON, the badge images, and the weekly safety snapshot dataset published under CC BY 4.0 — cite it, remix it, build on it.