RAILGUN SDKs

The RAILGUN SDKs are written in TypeScript and comes in 3 forms depending on the integrating dApps needs:
  • RAILGUN Cookbook - Easily integrate RAILGUN into any existing dApp to enable private features such as private lending, private trading, private minting, etc.
  • Wallet SDK – Toolkit to integrate RAILGUN as an incognitio mode for wallets.
  • RAILGUN Engine – Low-level version of the SDK for advanced use cases such as forking the RAILGUN system or specialized product requirements.
RAILGUN Cookbook is suitable for most dApp developers integrating RAILGUN. It enables users to call your public smart contract from a private 0zk address. Calls can also be linked together in "Recipes" such that users can combine multiple DeFi actions together in 1 transaction. For example, a user might be able to go from stablecoins in a 0zk address to providing liquidity in a DEX and depositing that liquidity into a yield optimizer like Beefy Finance in the same Cookbook Recipe.
With Wallet SDK, developers can quickly and simply add RAILGUN privacy to their wallets to perform the following RAILGUN actions:
  • Generate private keys and 0zk addresses
  • Generate deposits into private balances
  • Scan transaction history and sync balances through the QuickSync API
  • Generate ZK proofs for withdrawals, send transactions, and to initiate and complete cross-contract calls
The above actions are all that is required for a fully featured RAILGUN privacy. The generateDeposit() and transact() functions are contained within the Wallet SDK and are callable by dApps once integrated.
The RAILGUN Engine is the low-level version of the RAILGUN SDK. Engine is a dependency of Quickstart, with Quickstart being a ready out of the box version of Engine. By interacting with Engine directly, developers can build specialized product use cases, such as forking Engine for their own purposes.
Links: