This is the core SDK that powers everything in the Gridlock system—including the Gridlock CLI and the Gridlock mobile app. It handles user creation, guardian management, signing, and recovery using Gridlock's distributed architecture.
To understand how the full system works, see SystemOverview.md.
Related: Orch Node | Guardian Node | SDK
For full CLI and SDK documentation see the developer docs.
Install the SDK:
npm install gridlock-sdk
Then in your code:
import { Gridlock } from "gridlock-sdk";
const gridlock = new Gridlock({
apiKey: "your-api-key",
baseUrl: "https://api.gridlock.network",
debug: true,
});
For full SDK documentation, check out the developer docs.
If you're cloning this repo, you're likely doing development work. Here's how to get started:
- Install dependencies, build, and link the package:
npm install
npm run build
npm link
- In any project where you want to test your local changes (e.g. gridlock-cli):
npm link gridlock-sdk
- Start the development server to automatically rebuild when you make changes:
npm run dev
For general usage instructions, see the Quick Start section above.
All further usage is documented in the developer docs.
You don't need to clone this repo unless you're modifying behavior or building on top of the core SDK.
Use this repo if:
- You want to customize how Gridlock works
- You're developing features or extensions
- You need to test SDK changes locally in other projects
- You want to contribute to Gridlock's core infrastructure
For general use, just run:
npm install gridlock-sdk
This SDK is the backbone of Gridlock. If you want to improve developer experience, add features, or clean up internals—this is the place.
- Tighten up error handling
- Extend support for new flows
- Improve config and types
- Help document edge cases
This code is yours to use — but it’s even better when you’re part of the official Gridlock network.
By running guardian nodes, you can earn rewards while helping secure the network.
Join the community: gridlock.network/join