Show HN: StarkZap – Gasless Bitcoin Payments SDK for TypeScript(github.com)
github.com
Show HN: StarkZap – Gasless Bitcoin Payments SDK for TypeScript
https://github.com/keep-starknet-strange/starkzap
27 comments
We wrote a deeper technical breakdown of the architecture here: https://dev.to/akashneelesh/bring-bitcoin-to-your-app-now-in...
High-level architecture: Accounts are smart contract wallets on Starknet Fees are covered via a paymaster contract It's meant for any builder, you don't have to be a blockchain expert to build with it. Transactions are batched and submitted atomically, so you keep the UX of your existing app.
High-level architecture: Accounts are smart contract wallets on Starknet Fees are covered via a paymaster contract It's meant for any builder, you don't have to be a blockchain expert to build with it. Transactions are batched and submitted atomically, so you keep the UX of your existing app.
Happy to answer questions about the trust model, custody assumptions, gas economics, or why Starknet vs other Ethereum layer-2s approaches :)
Wow, it looks very interesting, you are saying that now web2 apps can have crypto functionalities in minutes?
yeah that's the goal of the sdk. I've seen a couple do it already and it's pretty interesting
Excited to see this. Is this just for Bitcoin-related assets, or does it also help with e.g. stablecoins?
It actually works with any asset that is listed onchain. So tokens such as ETH and others also work. As long as the token is live on the Starknet network, it can be used. I think the cool thing is that some tokens have interesting yield strategies, so you can cherry-pick the strategies you like the most and want to add to your app.
That’s awesome!and how long does it take to go from npm install to first working transaction roughly?
it really depends on what you're building, but when I tested it out I had a simple webapp that tracks how often I blink, and it took me 30min to everything live and deployed on Starknet.
That’s pretty impressive!is there a simple hello world example somewhere? would love to try this tonight
we have a quick-start here: https://docs.starknet.io/build/starkzap/quick-start
Happy to know how the integration goes, if you have feedback, suggestions, etc.
Happy to know how the integration goes, if you have feedback, suggestions, etc.
Thanks a lot for sharing this!i will! btw one more question,i’m just getting into blockchain development.does this require a crypto wallet to start testing?
So this is basically an SDK to remove blockchain complexity and add new revenue streams to an app.
Interesting.
Interesting.
yep, noticed many web2/SaaS devs struggle with blockchain integrations. So it's in Typescript to make it easy to ship. In theory, you can cherry-pick the blockchain features you need for your app (e.g., you're a tradFi stock exchange app and want to add perpetual contracts for index and tradFi assets, so you select the 'perps' module in the SDK) and you don't have to re-design or architect yourself smart-contracts
i have never worked on blockchain, can i still be able to use this easily ?
[deleted]
```import { StarkZap, StarkSigner, Amount, fromAddress, getPresets } from "starkzap";
const sdk = new StarkZap({ network: "sepolia" }); const wallet = await sdk.connectWallet({ account: { signer: new StarkSigner("0xYOUR_PRIVATE_KEY") } });
await wallet.ensureReady({ deploy: "if_needed" });
const { STRK } = getPresets(wallet.getChainId()); const balance = await wallet.balanceOf(STRK);
if (balance.gte(Amount.parse("10", STRK))) { const tx = await wallet.transfer(STRK, [ { to: fromAddress("0xRECIPIENT"), amount: Amount.parse("10", STRK) } ]); await tx.wait(); console.log(tx.explorerUrl); } ```
Key properties: - Gas sponsorship via paymaster (users don’t need gas tokens) - Multiple auth strategies (email/social via Privy, passkeys via Cartridge) - Batch transfers and contract calls in a single atomic transaction - Works in Node, browser, and React Native
The SDK abstracts account management, fee handling, and wallet popups. This won’t make sense for every app (e.g., if you only need fiat checkout). It’s for existing apps that want programmable onchain assets without the wallet UX.
Would appreciate feedback on the API design and whether this abstraction makes sense.