Skip to Content
DocsFlowsCreate distribution

Create distribution

This walkthrough is written for the person who actually presses “Create distribution” in the dashboard or calls the API. Follow it when you’re ready to turn a cohort + split template into a live, funded vault.

Before you start

  • A cohort that already passed review (see Cohorts & CSV uploads).
  • A split template that describes how the tokens should be divided.
  • A token mint and total budget you’re comfortable funding right now.
  • A wallet or server signer that is allowed to deploy in the chosen environment.

What Sync builds for you

  • Compute budget bump. Keeps the transaction from stalling during high-fee windows.
  • newDistributor. Creates the distributor PDA, clawback PDA, and vault ATA, then stores the Merkle metadata and vesting schedule.
  • Vault funding. Deposits maxTotalClaim tokens into the new ATA so claims have something to pull from day one.
  • Assertions. Optional Lighthouse checks confirm the payer’s lamports and known owners before anything hits chain.

Typical account rent clocks in around 0.00460056 SOL (≈ $0.51 USD when SOL is $110). The API response echoes this estimate so you can bake it into your approvals.

Requesting the transaction

import { useSyncApi } from "@fractalshq/sync/react"; import { useTxAuth } from "@fractalshq/auth/react"; const { distributions } = useSyncApi(); const { signAndSend } = useTxAuth(); async function launchDistribution() { const { transaction, summary } = await distributions.create({ cohortId: "ecosystem-weekly", splitTemplateId: "weekly-linear", mint: "GEOD...", schedule: { startVestingTs: 1_763_056_306, endVestingTs: 1_763_142_706, clawbackStartTs: 1_763_229_106, }, memo: "fractals:distribution:23:fund", }); await signAndSend(transaction); console.info(summary.estimatedCostUsd); }

distributions.create returns:

  • transaction — base64 v0 payload you can pass to any wallet adapter.
  • summary — IDs, estimated USD + lamport cost, and Merkle metadata for logging.
  • dashboardUrl — deep link so teammates can monitor claims once the vault opens.

After funding

  1. Sync indexes the on-chain signature and flips the distribution into “Serving proofs.”
  2. Recipients can request proofs immediately if the vesting window is open.
  3. Your team will see live stats (funded amount, pending claims, clawback timer) in the dashboard and via API.

If anything feels off—wrong cohort, bad totals—hit the clawback button before clawbackStartTs and re-run the flow with the corrected data.

⚠️ Clawback buffer: The contract enforces a 24-hour delay after clawbackStartTs before reclaim transactions execute. Don’t plan to unlock and claw back in the same minute—schedule the timestamp accordingly and remind operators they’ll regain control a full day after the window opens.

Last updated on