Quickstart

Get started with the B3 SDK in minutes and start building on the B3 ecosystem

Step 1: Install the B3 SDK

Install the SDK package

Choose your preferred package manager to install the B3 SDK:

npm install @b3dotfun/sdk

Tip
The B3 SDK includes TypeScript definitions out of the box!

Import CSS styles

Import the default styles in your application:

typescript
import "@b3dotfun/sdk/index.css";

Step 2: Add B3Provider

Wrap the B3Provider around your application's root:

tsx
import { B3Provider, SignInWithB3 } from "@b3dotfun/sdk/global-account/react"; function App() { return ( <B3Provider environment="production" partnerId="your-awesome-partner-id"> {children} </B3Provider> ); }

Step 3: Use the B3 SDK

Enable global accounts authentication with B3:

tsx
import { SignInWithB3 } from "@b3dotfun/sdk/global-account/react"; function App() { return ( <B3Provider environment="production" partnerId="your-awesome-partner-id"> <SignInWithB3 provider={{ strategy: "google" }} partnerId="your-partner-id" onLoginSuccess={(globalAccount) => { console.log("Authenticated:", globalAccount); }} /> </B3Provider> ); }

Enable cross-chain swaps & custom interactions with AnySpend:

tsx
import { AnySpend } from "@b3dotfun/sdk/anyspend/react"; function SwapPage() { return <AnySpend mode="page" />; }

Step 4: Explore the Ecosystem

Discover B3 Ecosystem

Learn about the complete B3 ecosystem, tools, and resources available for builders.

Learn More

What's Next?

Now that you have the B3 SDK installed, explore these powerful features:

Global Accounts

Seamless authentication and user management across the B3 ecosystem.

Learn More
Data API

Access blockchain data for tokens, NFTs, profiles, and analytics.

Learn More
AnySpend SDK

Cross-chain swaps, NFT minting, and blockchain operations.

Learn More
Examples & Demos

Ready-to-use examples and integration patterns.

Learn More

Platform Support

FeatureReact WebReact Native
AnySpend
Global Accounts
Headless Services
Note

Need help? Join our Discord community or check out the ecosystem introduction for comprehensive resources.

Ask a question... ⌘I