Skip to Content
⚠️ Alert: Sylan is under active development—only trust contract/wallet addresses announced on our official channels; we will never DM you, ask for funds, or run surprise airdrops/presales.
ArchitectureComponents

Architecture — Components

This page maps the major building blocks of Sylan and how they fit together. It’s a structural view—contracts, off‑chain services, and their responsibilities. Implementation details (ABIs, addresses) live elsewhere.


High‑level view


On‑chain components

ComponentTypeResponsibilitiesEmitsReads/Calls
AccessRegistryRegistryStores API descriptors (URI, contentHash, updatedAt, version), plan metadata (PPC/Subscription, price, duration, callLimit), and per‑API consistency/freshness params (seqMonotonic, maxSkewMs, maxTtlMs, providerSigner).RequestCreated (PPC), descriptor/plan updatesRead by UI/Nodes/Consensus/Escrow.
APIEscrowPaymentHolds SYL for PPC locks and Subscription purchases; snapshots BPS fee splits; on success/failure performs settlement/refund; maintains pull‑payment balances.Locked, Settled, Refunded, WithdrawnReads plan/BPS from Registry; invoked by UI; called by Consensus on finalize.
APIConsensusFinalityTallies provider‑signed Snapshots from Nodes; enforces freshness, signer, quorum, and (optional) sequence monotonicity; finalizes success/failure and notifies Escrow.RequestRegistered, ResponseSubmitted, RequestFinalized, RequestFailed, ProviderEquivocationReads per‑API params from Registry; may consult NodeRegistry for eligibility.
NodeRegistryACL/Staking(Optional) Maintains active node set, stake, slashing and rewards for (mis)matching votes.Slashing/reward eventsQueried by Consensus for eligibility; holds/updates stakes.
EventLoggerUtilityCurates cross‑contract human‑readable logs for indexers/explorers.Contract‑specific log eventsCalled by trusted contracts; read by indexers.
SylanTokenERC‑20Payment token SYL used for Escrow, staking, fees, and ecosystem.Standard ERC‑20 eventsApproved/Transferred by Escrow.
SylanStakingIncentivesOptional staking for participants (Nodes/Providers) with reward logic separate from per‑request settlement.Stake/Unstake/Reward eventsInteracts with Token; may be referenced by NodeRegistry.
SylanVestingToken mgmtLinear/claiffed vesting schedules for team/investors; not in the request path.Grants/Release eventsInteracts with Token.
PresaleContractToken saleOptional presale/IDO mechanism for distributing SYL; not in the request path.Purchase/Claim eventsInteracts with Token; off‑path to Escrow.

All core contracts follow UUPS upgradeability with owner‑gated upgrades and pause/unpause circuit breakers.


Off‑chain components

ComponentRoleResponsibilities
Provider APIData originServes raw data; should be deterministic for a given request; publishes response artifacts (or bytes) that hash to contentHash.
Provider SignerAuthorityEIP‑712 signer for Snapshot { apiId, seqNo, providerTs, ttl, contentHash }; held in HSM/hardware wallet; rotated via Registry flow.
Sylan NodesExecution & votingFetch descriptor → build request → retrieve Provider data → verify artifact hash → submit snapshot to Consensus → (optionally) pin artifacts to IPFS.
Indexers / RelayersObservabilitySubscribe to on‑chain events, materialize request states, serve dashboards/alerts, and help UIs correlate requestId ↔ contentHash/pointerURI.
Dashboard / SDKsClient interfaceWallet connect; approve/lock/purchase flows; progress UI by following events; receipt & withdrawal UX.
IPFS/HTTP StorageContent addressingHost artifacts pointed to by contentHash. Hash, not location, provides integrity; multiple mirrors encouraged.

Cross‑component interactions (happy path)

  1. Read: Client reads descriptorOf(apiId) and apiPlan(apiId) from AccessRegistry.
  2. Lock/Purchase: Client approves SYL and either locks for PPC (lockForCall(apiId, requestHash, expiresAtMs)) or purchases a subscription.
  3. Register: Escrow/Consensus register the request; RequestCreated/Registered are emitted.
  4. Submit: Nodes submit provider‑signed Snapshots to APIConsensus.
  5. Finalize: Consensus finalizes (quorum or expiry+grace) and notifies Escrow.
  6. Settle: Escrow splits fee snapshot (Provider/NodePool/Platform) or refunds.
  7. Withdraw: Recipients call withdraw() to pull their balances.

Key identifiers & data

  • apiId (bytes32) — listing identifier across Registry/Consensus/Escrow.
  • descriptor { uri, contentHash, updatedAt, version } — off‑chain metadata integrity anchor.
  • requestHash (bytes32) — canonical payload hash (client side) for PPC.
  • requestId — deterministic id created when locking/creating a request.
  • contentHash (bytes32) — digest of the concrete response artifact (or Merkle root).
  • pointerURI — optional retrieval hint (IPFS/HTTPS) associated with a snapshot.

Event surface (for UIs/indexers)

Watch these to drive UI state and analytics:

  • Escrow: Locked, Settled, Refunded, Withdrawn
  • Consensus: RequestRegistered, ResponseSubmitted, RequestFinalized, RequestFailed, ProviderEquivocation
  • Registry: descriptor/plan updates (activation, signer rotations)

Out of scope for this page

  • Addresses & ABI details → Architecture → Addresses & ABIs
  • Event signatures → Architecture → Events
  • Per‑contract specifics → Contracts section
  • Operational runbooks → Node and Provider sections

See also

  • Request Lifecycle (phase orchestration)
  • Consensus (vote tally rules & safety)
  • Data Integrity (hashing/signing)
  • Plans & Pricing (economics)
Last updated on