Buying Bitcoin IS political activism - activism that works.

BitcoinDevelopmentNostr

Another “Aha” AI Moment: Building a Bitcoin Crowdfunding Widget in 60 Minutes from a Tatkal Train Seat

2 Mins read

So today, I was travelling by train from Pudukkottai to Chennai on Indian Railways. After boarding the train, I started thinking about this fundraiser component that is in the roadmap of my Nostr Components project.

Then the idea grew. What if I somehow hack geyser.fund campaigns into this?

If that works, I should be able to embed my own Geyser project for nostr-components directly into my website.

But so far all nostr-components depend purely on relays for data. That is the whole idea. They are actually nostr-components. Not generic web components that fetch data from some random server.

This geyser fundraiser idea is a bit twisted though. Instead of relying on relays, it would rely on geyser.fund APIs, assuming they are publicly accessible. So technically speaking. it is not even a nostr-component anymore.

But fk it.

Technicalities aside, this would actually be useful. Atleast to me!

Though I am not sure the geyser.fund team would be happy about someone hacking around their APIs like this, making a component that let their data to be embedded anywhere on the internet.

So many questions and ideas started running in my mind.

Mainly is it feasible?

I immediately opened ChatGPT on my mobile and checked the feasibility.

It quickly explored the GraphQL queries used by geyser.fund by looking at their GitHub repo and showed me the endpoint and request/response structure.

That means… this is actually feasible.

Now I am fired up.

I opened my laptop and started Cursor AI. Selected Opus 4.6. Asked the same questions again.

Same confirmation. This should work.

For the actual funding part, I realised something.

Geyser already provides a Lightning Address / LNURL for each project. Instead of hacking their payment flow, I can simply let users donate to that.

No need to interfere with their system. Ideally, they should get their commission and they shouldn’t be mad at me for doing this.

Open protocols FTW.

Time for actually testing this idea:

At this point I couldn’t stop my excitement. I asked Cursor to build a minimal PoC:

Just fetch the project with this slug: nostrcomponents and render it.

I already have the project structure for the components and a storybook test setup, so that helped.

Cursor started working. Meanwhile more questions started popping up in my head. What if:

  • geyser.fund restricts CORS to their own domain?
  • LNURL donation flow behaves differently than I expect?
  • their API changes tomorrow?
  • some hidden authentication exists?

While my brain was busy generating problems, Cursor just kept building.

Ten minutes later. Boom. The PoC was running.

And of course it hit a CORS issue. Expected. Cursor quickly used Vite proxy to bypass it.

And then it worked. Damn. Now I am super fired up.

But Vite proxy only works in local dev. That won’t work everywhere. So I asked Cursor to spin up a small proxy endpoint on Firebase that anyone can call from anywhere.

Cursor is doing that right now.

And while it is doing its thing, I am here writing this post to share my excitement.

Building something like this while travelling on a IRCTC train between Pudukkottai and Chennai, and seeing an idea turn into a working prototype in minutes…

That is a pretty wild feeling.

Now the blog is published, let me get back to cursor!



Leave a Reply

Your email address will not be published. Required fields are marked *