← Protocols
Avail
01Description

Modular DA layer with KZG commitments and validity proofs. Rollups submit blobs via `data_availability.submitData`; Avail Nexus provides cross-rollup messaging and the Vector/Bridge brings DA attestations to Ethereum and other chains.

02Best for
  • 01rollup data availability
  • 02cross-rollup unification (Nexus)
  • 03OP Stack / Orbit / Polygon CDK DA
  • 04validity-proof-secured DA
  • 05lower DA costs vs Ethereum blobs
03Install
  • pnpm add avail-js-sdk
04Environment variables
VariableScopeDescription
AVAIL_RPC_URLServerAvail node WebSocket/HTTP RPC endpoint (e.g. wss://turing-rpc.avail.so/ws for testnet).
AVAIL_SEEDServerBIP39 seed phrase for the AVAIL account paying data submission fees.
AVAIL_APP_IDClientNumeric application ID registered on Avail for your rollup's namespace.
05Prompt snippet
Use Avail DA. Connect via `avail-js-sdk` to `AVAIL_RPC_URL`, build a keyring from `AVAIL_SEED`, and call `api.tx.dataAvailability.submitData(blob)` signed with the registered `AVAIL_APP_ID`. Persist the block hash, extrinsic index, and KZG data commitment as your inclusion proof. For Ethereum-side verification, use the Avail Vector bridge / attestation contract; for cross-rollup composition, use the Avail Nexus SDK.
06Gotchas
  • DA inclusion latency is ~20s (Avail block time) — design soft-finality and reorg windows around this.
  • Submission fees are paid in AVAIL tokens, not ETH — fund the submitter account and monitor balance.
  • App ID must be registered before first submission; reusing another project's App ID mixes namespaces.
  • Max extrinsic size limits per-blob bytes; large batches must be split across extrinsics or blocks.
  • Vector bridge attestations to Ethereum land on a delay (minutes) — fast L2 withdrawals need a separate fast-finality layer.
  • Nexus SDK is evolving; pin a version and watch for breaking changes between releases.
07Alternatives