light-protocol

Implement ZK Compression and Light Token operations on Solana using TypeScript SDKs.

6|20|Updated Mar 14, 2026
One-click install
npx skills add https://github.com/andresdefi/cryptoskills --skill light-protocol-andresdefi
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: light-protocol
Source: https://github.com/andresdefi/cryptoskills/tree/main/skills/light-protocol
Command: npx skills add https://github.com/andresdefi/cryptoskills --skill light-protocol-andresdefi

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires @lightprotocol/stateless.js, @lightprotocol/compressed-token, @solana/web3.js, @solana/spl-token, dotenv, and includes references (resource) components.

What problem does it solve? Solana token accounts require rent-exemption deposits and standard SPL operations carry high storage costs, making large-scale token distributions and account-heavy applications expensive to build and operate. ## Core Features & Use Cases - ZK Compression: Create rent-free compressed token mints, mint and transfer compressed tokens, and compress or decompress SPL tokens using zero-knowledge validity proofs. - Light Token Program: Use a high-performance token standard with wrap/unwrap interoperability with SPL and Token-2022, reducing mint and account costs by roughly 200x. - RPC & Querying: Query compressed accounts, token balances, holders, validity proofs, and indexer health through 21 specialized JSON RPC methods via Helius endpoints. - Use Case: Airdrop tokens to thousands of wallets by batching mintTo calls (4 accounts per transaction) with compressed tokens, avoiding rent costs for every recipient account. ## Quick Start Set up a Light Protocol client with a Helius RPC endpoint, create a compressed token mint, and mint tokens to a recipient wallet.

Frequently Asked Questions about light-protocol

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I create a compressed token mint on Solana?

Use the createMint function from @lightprotocol/compressed-token with an RPC connection, fee payer, mint authority, and decimals. It returns the mint public key and transaction signature, and the mint includes a built-in token pool for compression.

How to compress SPL tokens into compressed tokens?

Call compress from @lightprotocol/compressed-token with the mint, amount, owner, recipient, and source SPL token account. If the mint lacks a token pool, create one first with createTokenPool, which does not require mint authority.

What is the difference between ZK Compression and the Light Token Program?

ZK Compression uses zero-knowledge proofs and Merkle trees for rent-free compressed tokens and PDAs, while the Light Token Program is an optimized token standard with lower compute usage and wrap/unwrap interoperability with SPL and Token-2022.

Does Light Protocol work with standard Solana RPC endpoints?

No, standard RPC endpoints do not support compression methods and return method-not-found errors. You need a ZK Compression-enabled RPC such as Helius, passing the endpoint to createRpc from @lightprotocol/stateless.js.

Why do compressed token transactions fail with too many accounts?

Compressed token transactions are limited to roughly 4 accounts per transaction. Split large mints or distributions into batches of 4 recipients and add delays between transactions to avoid rate limiting.

Why are my compressed accounts not appearing after a mint or transfer?

The compression indexer may not have processed the transaction yet. Poll getCompressedTokenAccountsByOwner with a retry loop, or check indexer status using the getIndexerHealth RPC method.