Skip to content

Feat/plasma bot integration#1

Open
0x3639 wants to merge 18 commits into
digitalSloth:mainfrom
0x3639:feat/plasma-bot-integration
Open

Feat/plasma bot integration#1
0x3639 wants to merge 18 commits into
digitalSloth:mainfrom
0x3639:feat/plasma-bot-integration

Conversation

@0x3639

@0x3639 0x3639 commented Jun 4, 2026

Copy link
Copy Markdown
Collaborator

Add plazma.bot to the Plasma tab of the wallet. The dialogue box will ONLY appear if the wallet has fewer than 10 QSR.

Workflow

Screenshot 2026-06-04 at 5 56 01 AM Screenshot 2026-06-04 at 5 56 09 AM Screenshot 2026-06-04 at 5 56 22 AM Screenshot 2026-06-04 at 5 59 06 AM

You can see test fusions here https://plazma.bot/

I exposed /api/health and /api/fuse to CORS *. It's still gated by anti-dos measures.

0x3639 and others added 18 commits June 3, 2026 20:40
Add a free-plasma faucet column to the Plasma tab backed by the
plasma.bot agent API, alongside the existing self-funded fusion.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Replace the always-visible two-column faucet with a conditional button +
dialog shown only when the account has 0 plasma and < 10 QSR.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Fetch /api/stats on dialog open to show bot status, disable unfundable
tiers, and auto-select a fundable tier. Fail-open if the check fails.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>

@digitalSloth digitalSloth left a comment

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is cool, it works well and looks good. Just a few minor things to tidy up.

Please can you also remove the superpower docs from this PR too.

<DialogHeader>
<DialogTitle>Get free plasma from plazma.bot</DialogTitle>
<DialogDescription>
plazma.bot fuses QSR to your account for free. No QSR or wallet unlock required.

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you change the text plazma.bot into a link to your site. People might want to see more about it.

Additionally Im not sure about the 2nd sentence maybe sometime like "No QSR required, just choose a tier and go." I dont really like the "or wallet unlock" wording.

:disabled="plasmaBot.isFusing.value || !isTierAvailable(tier.key)"
@click="selectedTier = tier.key"
>
{{ tier.label }} · {{ tier.qsr }}

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not sure we need the QSR amount here, keep it simple for new users. What do you think?

Comment thread src/config.ts
Comment on lines +54 to +72
// --- plasma.bot (free plasma faucet) ---
/** Base URL of the plasma.bot agent API (note: domain is spelled "plazma"). */
export const PLASMA_BOT_API_URL = 'https://plazma.bot'

export type PlasmaBotTierKey = 'low' | 'medium' | 'high'

export interface PlasmaBotTier {
key: PlasmaBotTierKey
label: string
/** QSR the bot fuses for this tier. */
qsr: number
}

/** Tiers offered by plasma.bot, matching its agent API. */
export const PLASMA_BOT_TIERS: readonly PlasmaBotTier[] = [
{ key: 'low', label: 'Low', qsr: 20 },
{ key: 'medium', label: 'Medium', qsr: 80 },
{ key: 'high', label: 'High', qsr: 120 }
] as const

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Id move all of this to the plasma-bot-service.ts although these values are configs they're not really global configs. Lets keep all the plasma bot config self contained in the service.

Another benefit of moving it is that we can remove the double export of PlasmaBotTierKey. Currently its defined here in the config, imported into the service then re-exported from the service to the core/index.ts

Comment on lines +121 to +124
await plasmaBot.fuse(props.activeAccountAddress, selectedTier.value)
emit('showToast', `plazma.bot fused ${qsr} QSR to your account!`, 'success')
emit('fused')
emit('update:open', false)

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could we poll the bot here and only close the modal when the fuse has happened? At the moment the toast shows the success message but it takes a bit of time for the plasma to come through

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants