DOCUMENTATION
Getting Started
Privexel is a stealth compression tool that utilizes zero-knowledge proofs to ensure privacy in transactions. Connect to the network, leverage zk-proof technology, and enhance confidentiality in your DeFi operations.
npm install @privexel/clientCore Concepts
ZK Compression
A method that employs zero-knowledge proofs to compress account and token states. This allows for privacy-preserving transactions while significantly lowering storage costs.
• Latency: 100-500ms for state verification
• Proof size: 1-5 KB per transaction
• Retention: On-demand historical state access
Privacy-Preserving Transactions
Ensures that transaction details remain confidential while still providing the necessary integrity and verification through zk-proof attestations. Each transaction maintains verifiable integrity without exposing sensitive data.
• Verification method: zk-proof attestation
• Confidence threshold: 3+ node confirmations
• Failure mode: Reject on proof mismatch
API Endpoints
/v1/compressed/:chain/:blockRetrieve the compressed state for a specific block on the target chain.
/v1/transactions/submitSubmit a transaction to the network with privacy-preserving zk-proof.
/v1/state/:chain/:addressQuery the compressed state for a contract address with zk-proof attestation.
/v1/verifySubmit zk-proof for independent verification against privacy standards.
Integration Guide
Basic Connection
import { PrivexelClient } from '@privexel/client'
const client = new PrivexelClient({
apiKey: process.env.PRVX_API_KEY,
network: 'mainnet'
})
// Query compressed state
const state = await client.getCompressedState('solana', 'your-address')
console.log(state.verified) // trueTransaction Submission
// Submit a transaction
const transaction = await client.submitTransaction({
chain: 'solana',
data: { /* transaction details */ }
})
console.log('Transaction submitted:', transaction.id)
console.log('Proof:', transaction.proof)Developer Notes
Rate Limits
Free tier: 100 transactions/minute. Staked tier (10K+ $PRVX): 1000 transactions/minute. Enterprise: Unlimited (custom $PRVX stake required).
Proof Verification
All zk-proofs include verification parameters. Client SDK verifies locally by default. Disable with verifyLocal: false to trust network consensus.
Error Handling
Network rejects invalid transactions immediately. Failed proofs return verified: false with detailed rejection reason. Always validate zk-proof data.