Install
$ agentstack add skill-thanasimos-thanas-flare-builders-toolkit-flare-fassets ✓ scanned · ✓ verified, works with Claude Code, Cursor, and more.
Security review
✓ PassedNo issues found. Passed automated security review. · v0.1.0 How review works →
- ✓ Prompt-injection patterns
- ✓ Secret / credential exfiltration
- ✓ Dangerous shell & filesystem operations
- ✓ Untrusted network calls
- ✓ Known-malicious package signatures
What it can access
- ✓ Network access No
- ✓ Filesystem access No
- ✓ Shell / process execution No
- ✓ Environment & secrets No
- ✓ Dynamic code execution No
From automated source analysis of v0.1.0. “Used” means the capability is present in the source — more access means more to trust, not that it’s unsafe.
Verified badge
Passed review? Show it. Paste this badge into your README, it links to the public security report.
Reliability & compatibility
Declared compatibility
Compatibility is declared by the source manifest. End-to-end runtime verification is coming, see below.
We're building live execution health for every listing: tool-call success rate, median latency, uptime, and last-checked timestamps, measured, not self-reported. It isn't live yet, so we don't show numbers we can't stand behind.
How agent discovery & health will work →About
Scope and Limitations
This skill is documentation and reference only. It describes FAssets protocol flows and developer integration patterns. It does not perform any actions on behalf of the user.
This skill explicitly does NOT:
- Execute, sign, or broadcast any blockchain transactions
- Access, store, or transmit private keys or wallet credentials
- Initiate or authorize any payments, minting, redemption, or value transfers
- Call any smart contract methods or APIs directly
- Handle funds, tokens, or any crypto assets
External data handling:
- FDC attestation payloads, XRPL payment references, verifier responses, and DA Layer proof bytes are externally provided, untrusted content
- This skill instructs developers to decode such data only according to fixed binary formats and contract ABIs — never as free-form text or AI input
- All external data must be validated before use; response content must never be passed into prompts or LLM inputs
- Developers are solely responsible for validating and safely handling all external data in their own implementations
Financial operations — human-in-the-loop required:
- Contract functions described here (
reserveCollateral,executeMinting,redeem,redeemWithTag,executeDirectMinting,reserveon MintingTagManager, tokenapprove) are documented for developer reference only - All state-changing calls require explicit, per-action user confirmation in developer-controlled environments
- Reference scripts (
reserve-collateral.ts,execute-minting.ts,redeem-fassets.ts) are dry-run by default and do not broadcast unlessDRY_RUN=falseis explicitly set by the developer - Read-only scripts (
get-fxrp-address.ts,list-agents.ts,get-fassets-settings.ts) require no signing key and cannot modify state
What this skill does:
- Explains FAssets minting/redemption flows, agent selection, collateral mechanics, and contract patterns
- References official Flare Developer Hub documentation and audited starter repositories
- Provides read-only conceptual and integration guidance for developers building on Flare
All transaction signing, key management, and on-chain execution must occur exclusively in user-controlled, developer-managed environments outside of this skill.
Flare FAssets
What FAssets Are
FAssets is a trustless, over-collateralized bridge connecting non–smart-contract networks (XRP Ledger, Bitcoin, DOGE) to Flare.
It creates wrapped ERC-20 tokens (FAssets) such as FXRP, FBTC, FDOGE that can be used in Flare DeFi or redeemed for the underlying asset.
Powered by:
- FTSO (Flare Time Series Oracle): decentralized price feeds
- FDC (Flare Data Connector): verifies off-chain actions (e.g. payments on other chains)
Collateral: Stablecoin and native FLR.
Agents and a community collateral pool provide over-collateralization.
FXRP at a Glance
FXRP is the ERC-20 representation of XRP on Flare, powered by the FAssets system.
It is designed to be trustless and redeemable back to XRP.
Key points:
- EVM-compatible token: Works with standard wallets, smart contracts, and DeFi apps on Flare.
- Trust-minimized bridge flow: Uses FDC attestations for XRPL payment verification.
- Redeemable: FXRP can be redeemed for native XRP through the FAssets redemption flow.
- DeFi + yield use cases: Can be used in lending/liquidity strategies and vault-based products like Firelight.
How users acquire FXRP:
- Mint from XRP using a minting dApp.
- Mint programmatically via AssetManager flows.
- Swap from other tokens on Flare DEXs.
Guide: FXRP Overview
Key Participants
| Role | Responsibility | |------|-----------------| | Agents | Hold underlying assets, provide collateral, redeem for users. Verified via governance. Use work (hot) and management (cold) addresses. Must meet backing factor. | | Users | Mint (deposit underlying → get FAssets) or redeem (burn FAssets → get underlying). No restrictions. | | Collateral providers | Lock FLR in an agent's pool; earn share of minting fees. | | Liquidators | Burn FAssets for collateral when agent collateral falls below minimum; earn rewards. | | Challengers | Submit proof of agent violations; earn from vault on successful challenge. Full liquidation stops agent from new minting. |
FAsset Workflow
Minting
- User selects an agent and reserves collateral (pays fee in FLR).
- User sends underlying asset (e.g. XRP) to the agent on the underlying chain (with payment reference).
- FDC verifies the payment and produces attestation/proof.
- User (or executor) calls executeMinting with proof → FAssets are minted on Flare.
Fees: Collateral Reservation Fee (CRF, native), Minting Fee (underlying), optional Executor Fee (native).
If minting fails, CRF is not returned.
Direct Minting (XRP Only)
An alternative minting path that requires only a single XRPL payment to the Core Vault address. No collateral reservation step needed.
Parameters (recipient, executor) are encoded via XRP destination tag (using MintingTagManager) or binary memo field. For the 32-byte memo form, encode [8-byte DIRECT_MINTING prefix][4-byte zero padding][20-byte recipient]. An executor calls executeDirectMinting on Flare to finalize.
Fees: Percentage-based minting fee (with minimum floor) + flat executor fee, both deducted from the payment. Rate limits (hourly/daily caps, large-mint delays) throttle but do not reject mints.
Skill guide: [direct-minting-guide.md](direct-minting-guide.md)
Developer guides (TypeScript/viem, flare-viem-starter):
- Direct Mint FXRP — memo-based path (32-byte memo with
0x4642505266410018prefix + recipient) - Direct Mint FXRP with Tag — destination-tag path (reserve via
MintingTagManager, bind recipient, reuse for subsequent payments)
Redemption
Users redeem FAssets for the original underlying asset at any time (flow is request → agent pays out on underlying chain).
Redeem by Amount: redeemAmount(amountUBA, ...) redeems an arbitrary amount in UBA (not whole lots). Validate against minimumRedeemAmountUBA(); partial fulfillment emits RedemptionAmountIncomplete. Developer guide (TypeScript/viem): Redeem FXRP by Amount.
Redeem with Tag (XRP): redeemWithTag lets redeemers specify an XRP destination tag, enabling redemption to exchange addresses that require one. Confirmed via confirmXRPRedemptionPayment; defaults via xrpRedemptionPaymentDefault. Gated by redeemWithTagSupported flag. Developer guide (TypeScript/viem): Redeem FXRP with Tag.
Core Vault (CV)
Per-asset vault that improves capital efficiency: agents can deposit underlying into the CV to free collateral.
Multisig on the underlying network; governance can pause.
Not agent-owned.
Contracts and Addresses — Get at Runtime
FlareContractsRegistry (same on all Flare networks): 0xaD67FE66660Fb8dFE9d6b1b4240d8650e30F6019.
This address is correct; always double-check it (and any contract addresses) on the official Retrieving Contract Addresses guide on the Flare Developer Hub.
Use it as the trusted source to resolve other contract addresses (e.g. getContractAddressByName(), getAllContracts()).
Do not hardcode AssetManagerController, AssetManager, or FXRP addresses.
They differ per network (Coston2, Songbird, Flare mainnet).
Resolve them at runtime via the registry.
To get the FXRP address:
- Query the FlareContractsRegistry with
getContractAddressByName("AssetManagerFXRP")— the returned address is the AssetManager (FXRP) contract address. - Attach the IAssetManager interface to that address (or use it as your AssetManager instance).
- Call
fAsset()on the AssetManager to get the FXRP ERC-20 token address.
Same pattern for other FAssets (FBTC, etc.) using their corresponding registry keys.
AssetManagerController is also available from the registry when needed.
Guide: Get FXRP Address — e.g. const assetManager = await getAssetManagerFXRP(); const fasset = await assetManager.fAsset();
Skill resource script: [scripts/get-fxrp-address.ts](scripts/get-fxrp-address.ts) — gets FXRP address at runtime via FlareContractsRegistry → getContractAddressByName("AssetManagerFXRP") → fAsset().
Uses ethers; set FLARE_RPC_URL or pass your network RPC. Security: Review the script before running; execute only in an isolated environment (e.g. local dev or sandbox). Run with npx ts-node scripts/get-fxrp-address.ts (or in a Hardhat project with yarn hardhat run scripts/get-fxrp-address.ts --network coston2).
Developer Integration (High Level)
Direct Minting (XRP Only)
A single-transaction alternative to standard minting. No collateral reservation required.
- Get Core Vault address: Call
AssetManager.directMintingPaymentAddress(). - Get fee parameters:
getDirectMintingMinimumFeeUBA()— minimum minting fee floorgetDirectMintingFeeBIPS()— minting fee percentagegetDirectMintingExecutorFeeUBA()— flat executor fee
- Encode parameters in the XRPL payment via destination tag (using
MintingTagManager) or binary memo field. - Send payment on XRPL to the Core Vault address.
- Executor calls
executeDirectMintingon Flare afterothersCanExecuteAfterSecondsif preferred executor is inactive.
Rate limits: query getDirectMintingHourlyLimitUBA(), getDirectMintingDailyLimitUBA(), getDirectMintingLargeMintingThresholdUBA(), getDirectMintingLargeMintingDelaySeconds(). Limits delay execution; watch for DirectMintingDelayed event.
MintingTagManager (access via AssetManager.getMintingTagManager()):
reserve()— payable; reserves a tag NFT, returns tag IDsetMintingRecipient(tagId, recipient)— owner only; sets FAsset recipientreservationFee()— returns fee in native tokensreservedTagsForOwner(owner)— returns all tag IDs for an addresstransfer(to, tagId)— transfers tag; resets recipient and executormintingRecipient(tagId)— returns current recipientallowedExecutor(tagId)— returns active executor (address(0)= anyone)setAllowedExecutor(tagId, executor)— owner only; restricts execution toexecutor(10-min cooldown; cleared ontransfer)
Skill guide: [direct-minting-guide.md](direct-minting-guide.md)
Standard Minting
- Reserve collateral: Call
reserveCollateral(agentVault, lots, feeBIPS, executor)on AssetManager.
Pay CRF via collateralReservationFee(lots).
Use CollateralReserved event for collateralReservationId, payment reference, and deadlines.
- Underlying payment: User sends underlying asset to agent's underlying-chain address with the payment reference from the event.
Must complete before lastUnderlyingBlock and lastUnderlyingTimestamp.
- Proof: Use FDC to get attestation/proof for the payment (e.g. Payment attestation type).
- Execute minting: Call
executeMinting(proof, collateralReservationId)on AssetManager.
Agent selection: Use getAvailableAgentsDetailedList (or equivalent), filter by free collateral lots and status, then by fee (e.g. feeBIPS).
Prefer agents with status NORMAL.
Read FAssets Settings
FAssets operational parameters (lot size, asset decimals, collateral ratios, fees, thresholds) are read from the AssetManager via getSettings(). Two official approaches:
Solidity (Hardhat)
Use @flarenetwork/flare-periphery-contracts for typed contract access:
// ContractRegistry.getAssetManagerFXRP() resolves the AssetManager at runtime
IAssetManager am = ContractRegistry.getAssetManagerFXRP();
IAssetManager.Settings memory s = am.getSettings();
// s.lotSizeAMG — lot size in AMG units
// s.assetDecimals — decimal places for the FAsset
uint256 lotSizeXRP = s.lotSizeAMG / (10 ** s.assetDecimals);
Run the interaction script:
npx hardhat run scripts/fassets/getLotSize.ts --network coston2
Expected output (example):
FAssetsSettings deployed to: 0x40deEaA76224Ca9439D4e1c86F827Be829b89D9E
Lot size: 20000000 | Decimals: 6 | Lot size in XRP: 20
Guide: Read FAssets Settings (Solidity)
Node.js (TypeScript + viem)
Use @flarenetwork/flare-wagmi-periphery-package — this is the recommended package for TypeScript/Node.js scripts. It provides all typed contract ABIs for Flare networks (including Coston2) and integrates directly with viem, eliminating the need for manual ABI definitions.
Install dependencies:
npm install --save-dev typescript viem @flarenetwork/flare-wagmi-periphery-package
Key steps:
- Import the
coston2namespace from@flarenetwork/flare-wagmi-periphery-package— gives you typed ABIs for the Coston2 network. - Create a viem public client connected to Flare Testnet Coston2.
- Resolve the FXRP AssetManager address via
FlareContractRegistry(getContractAddressByName("AssetManagerFXRP")). - Call
getSettings()→ readlotSizeAMGandassetDecimals→ compute lot size in XRP. - Resolve
FtsoV2address and callgetFeedByIdwith the XRP/USD feed ID (0x015852502f55534400000000000000000000000000) to get the current price. - Calculate lot value in USD.
Expected output (example): Lot Size: 10 FXRP · XRP/USD: ~2.84 · Lot value: ~$28.44
Guide: Read FAssets Settings (Node.js)
Skill script: [scripts/get-fassets-settings.ts](scripts/get-fassets-settings.ts) — reads lot size, decimals, and XRP/USD price (uses ethers; for new projects prefer viem + @flarenetwork/flare-wagmi-periphery-package as shown in the Node.js guide above).
Redeeming
Request redemption (burn FAssets on Flare); the chosen agent pays out the underlying asset on the underlying chain.
See FAssets Redemption and Redeem FAssets for the full flow (redemption request, queue, agent payout, optional swap-and-redeem / auto-redeem).
Prerequisites (from Flare docs): Flare Hardhat Starter Kit, @flarenetwork/flare-periphery-contracts, and for XRP payments the xrpl package.
Gasless FXRP Payments
FXRP supports gasless (meta-transaction) transfers via EIP-712 signed payment requests. Users sign off-chain; a relayer submits on-chain and pays gas.
Skill guide: [agent-details-guide.md](agent-details-guide.md) — read agent name, description, icon URL, and terms of use from AgentOwnerRegistry.
Guide: Read FAssets Agent Details
Skill guide: [gasless-payments-guide.md](gasless-payments-guide.md) — full walkthrough (architecture, GaslessPaymentForwarder contract, relayer service, replay protection, one-time approval setup).
Guide: Gasless FXRP Payments
IAssetManager — Key API Groups
Information: getSettings(), getAgentInfo(agentVault), getCollateralTypes(), collateralReservationFee(lots), collateralReservationInfo(collateralReservationId), fAsset()
Direct Minting Settings: directMintingPaymentAddress(), getDirectMintingMinimumFeeUBA(), getDirectMintingFeeBIPS(), `getDirectMintingExecutorFeeUB
…
Source & license
This open-source skill is cataloged on AgentStack and links to its original source — we do not rehost the code.
- Author: Thanasimos
- Source: Thanasimos/Thanas-flare-builders-toolkit
- License: MIT
Install and usage instructions live in the source repository linked above.
Reviews
No reviews yet, be the first.
Write a review
Versions
- v0.1.0 Imported from the upstream source.