flare-ftso

Guide Flare FTSO integration for Solidity, TypeScript, and wagmi feed consumption.

Updated Apr 8, 2026
One-click install
npx skills add https://github.com/mashharuki/flare-sample --skill flare-ftso
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: flare-ftso
Source: https://github.com/mashharuki/flare-sample/tree/main/.claude/skills/flare-ftso
Command: npx skills add https://github.com/mashharuki/flare-sample --skill flare-ftso

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires web3, @flarenetwork/flare-periphery-contract-artifacts, and includes scripts (resource) components.

What problem does it solve?

Flare FTSO integration can be subtle and error-prone: developers need clear guidance to read block-latency feeds, verify scaling (anchor) Merkle proofs, calculate and supply any required fees, and implement secure offchain/onchain consumption without exposing keys or misinterpreting raw RPC data. This skill collects architecture explanation, contract interfaces, example scripts, and security guidance to reduce integration mistakes and ensure correct, auditable feed consumption.

Core Features & Use Cases

  • Architectural Overview: Explains FTSO components (block-latency feeds, scaling anchor feeds, VRF selection, incremental delta updates, volatility incentives).
  • Onchain Integration: Guidance for Solidity consumers including resolving FtsoV2 via ContractRegistry, calling getFeedByIdInWei/getFeedsById, fee calculation via IFeeCalculator, and verifyFeedData for anchor proofs.
  • Offchain & Frontend: Examples for JavaScript/TypeScript and wagmi/viem frontends that dynamically resolve contract addresses, poll feeds, and format wei-scaled values for display.
  • Security & Data Handling: Rules for treating feed values as typed ABI outputs, never exposing private keys to AI, and ensuring human-in-the-loop for payable operations.
  • Use Case: Read FLR/USD and BTC/USD block-latency feeds offchain, derive a BTC/ETH cross-quote, or verify a scaling anchor proof onchain before storing a proven value.

Quick Start

Ask the skill to explain how to read FLR/USD and BTC/USD using ContractRegistry and FtsoV2, convert wei-scaled values to human-readable prices, and verify a scaling anchor Merkle proof with verifyFeedData while keeping all signing in your local environment.

Frequently Asked Questions about flare-ftso

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

FAQPage Schema
How do I read Flare FTSO price feeds in a Solidity smart contract?

To read Flare FTSO price feeds in Solidity, dynamically resolve the FtsoV2 contract address via ContractRegistry, then call the getFeedByIdInWei or getFeedsById methods to retrieve block-latency feed values as typed numeric ABI outputs.

What is a Flare FTSO scaling anchor Merkle proof and how do I verify it?

A Flare FTSO scaling anchor Merkle proof verifies the integrity of feed data on-chain. You verify it by calling the verifyFeedData method on the FtsoV2 interface before storing or consuming the proven value.

Can I consume Flare FTSO price feeds using a wagmi frontend integration?

Yes, you can consume Flare FTSO price feeds using wagmi or viem frontends by dynamically resolving contract addresses and polling feeds to format wei-scaled values for human-readable display.

How do I calculate required fees for Flare FTSO feed consumption?

You calculate required fees for Flare FTSO feed consumption by interfacing with the IFeeCalculator contract to ensure correct fee supply before requesting or verifying feed data.

What security precautions should I take when integrating Flare FTSO off-chain readers?

When integrating Flare FTSO off-chain readers, ensure all signing and key management remain in user-controlled environments, never expose private keys to AI, and maintain human-in-the-loop oversight for payable operations.