Skip to content

Commit

Permalink
Merge branch 'main' into add-tests
Browse files Browse the repository at this point in the history
  • Loading branch information
dineshpinto authored Dec 21, 2024
2 parents 1d2ae44 + ac11bcb commit 436cc13
Show file tree
Hide file tree
Showing 11 changed files with 156 additions and 110 deletions.
11 changes: 7 additions & 4 deletions docs/fassets/3-minting.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -51,13 +51,16 @@ The following fees are paid to mint FAssets:

### Collateral Reservation Fee

The **collateral reservation fee (CRF)** is paid in native tokens by the minter at the same time the [CRT](#minting-process) is made.
The **collateral reservation fee (CRF)** is paid in native tokens by the minter at the same time the [collateral reservation](#minting-process) is made.
The CRF is defined by governance as a percentage of the minted value, and the same fee applies to all agents.

When the minter does not pay on the underlying chain, this fee compensates the agent and the CPT holders for the time their collateral was locked while the mint processed.
If the minter pays on the underlying chain, the CRF is burned.
The purpose of the CRF is to compensate the agent and collateral pool token (CPT) holders for the time their collateral is locked during the minting process.

For underlying chains on which proving payments takes a long time, the fee might be higher than the fee on chains that quickly prove payments.
- If the minter does not pay on the underlying chain, the CRF is distributed to the agent and the pool in the same share as the minting fee.
- If the minter successfully pays on the underlying chain, the CRF is also distributed to the agent and the pool in the same manner.

For underlying chains where proving payments takes longer, the CRF might be set higher to account for the extended lock-up time.
The CRF percentage is defined by governance and may vary based on the performance of the underlying chain.

### Minting Fee

Expand Down
42 changes: 21 additions & 21 deletions docs/fassets/6-operational-parameters.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ keywords: [fassets, xrp, bitcoin, dogecoin, flare-network]
import Tabs from "@theme/Tabs";
import TabItem from "@theme/TabItem";

This page lists the current values for the most important parameters of the FAssets system on the Coston testnet. These values are subject to change as the system is further developed and tested.
This page lists the current values for the most important parameters of the FAssets system on **Songbird Canary-Network** and **Songbird Testnet Coston**. These values are subject to change as the system is further developed and tested.

## Minting and Redeeming

Expand All @@ -17,8 +17,8 @@ This page lists the current values for the most important parameters of the FAss
defaultValue="songbird"
groupId="operational-parameters"
values={[
{label: 'Songbird', value: 'songbird'},
{label: 'Coston', value: 'coston'},
{label: "Songbird Canary-Network", value: 'songbird'},
{label: "Songbird Testnet Coston", value: 'coston'},
]}>
<TabItem value="songbird">
| **Parameter** | **XRP** | **BTC** | **DOGE** |
Expand Down Expand Up @@ -50,8 +50,8 @@ This page lists the current values for the most important parameters of the FAss
defaultValue="songbird"
groupId="operational-parameters"
values={[
{label: 'Songbird', value: 'songbird'},
{label: 'Coston', value: 'coston'},
{label: "Songbird Canary-Network", value: 'songbird'},
{label: "Songbird Testnet Coston", value: 'coston'},
]}>
<TabItem value="songbird">
| **Parameter** | **XRP** | **BTC** | **DOGE** |
Expand Down Expand Up @@ -81,8 +81,8 @@ This page lists the current values for the most important parameters of the FAss
defaultValue="songbird"
groupId="operational-parameters"
values={[
{label: 'Songbird', value: 'songbird'},
{label: 'Coston', value: 'coston'},
{label: "Songbird Canary-Network", value: 'songbird'},
{label: "Songbird Testnet Coston", value: 'coston'},
]}>
<TabItem value="songbird">
| **Parameter** | **XRP** | **BTC** | **DOGE** |
Expand Down Expand Up @@ -126,8 +126,8 @@ This page lists the current values for the most important parameters of the FAss
defaultValue="songbird"
groupId="operational-parameters"
values={[
{label: 'Songbird', value: 'songbird'},
{label: 'Coston', value: 'coston'},
{label: "Songbird Canary-Network", value: 'songbird'},
{label: "Songbird Testnet Coston", value: 'coston'},
]}>
<TabItem value="songbird">
| **Parameter** | **XRP** | **BTC** | **DOGE** |
Expand Down Expand Up @@ -162,8 +162,8 @@ Agents are free to adjust these settings as they see fit.
defaultValue="songbird"
groupId="operational-parameters"
values={[
{label: 'Songbird', value: 'songbird'},
{label: 'Coston', value: 'coston'},
{label: "Songbird Canary-Network", value: 'songbird'},
{label: "Songbird Testnet Coston", value: 'coston'},
]}>
<TabItem value="songbird">
| **Parameter** | **XRP** | **BTC** | **DOGE** |
Expand Down Expand Up @@ -201,8 +201,8 @@ Agents are free to adjust these settings as they see fit.
defaultValue="songbird"
groupId="operational-parameters"
values={[
{label: 'Songbird', value: 'songbird'},
{label: 'Coston', value: 'coston'},
{label: "Songbird Canary-Network", value: 'songbird'},
{label: "Songbird Testnet Coston", value: 'coston'},
]}>
<TabItem value="songbird">
| **Parameter** | **XRP** | **BTC** | **DOGE** |
Expand Down Expand Up @@ -232,8 +232,8 @@ These settings are far shorter in the beta phases than in the final version, in
defaultValue="songbird"
groupId="operational-parameters"
values={[
{label: 'Songbird', value: 'songbird'},
{label: 'Coston', value: 'coston'},
{label: "Songbird Canary-Network", value: 'songbird'},
{label: "Songbird Testnet Coston", value: 'coston'},
]}>
<TabItem value="songbird">
| **Parameter** | **XRP** | **BTC** | **DOGE** |
Expand Down Expand Up @@ -273,8 +273,8 @@ These settings are far shorter in the beta phases than in the final version, in
defaultValue="songbird"
groupId="operational-parameters"
values={[
{label: 'Songbird', value: 'songbird'},
{label: 'Coston', value: 'coston'},
{label: "Songbird Canary-Network", value: 'songbird'},
{label: "Songbird Testnet Coston", value: 'coston'},
]}>
<TabItem value="songbird">
| **Parameter** | **XRP** | **BTC** | **DOGE** |
Expand All @@ -298,8 +298,8 @@ These settings are far shorter in the beta phases than in the final version, in
defaultValue="songbird"
groupId="operational-parameters"
values={[
{label: 'Songbird', value: 'songbird'},
{label: 'Coston', value: 'coston'},
{label: "Songbird Canary-Network", value: 'songbird'},
{label: "Songbird Testnet Coston", value: 'coston'},
]}>
<TabItem value="songbird">
| Parameter | XRP | BTC | DOGE |
Expand All @@ -323,7 +323,7 @@ These settings are far shorter in the beta phases than in the final version, in
defaultValue="songbird"
groupId="operational-parameters"
values={[
{label: 'Songbird', value: 'songbird'},
{label: "Songbird Canary-Network", value: 'songbird'},
]}>
<TabItem value="songbird">
| Parameter | XRP | BTC | DOGE |
Expand All @@ -343,7 +343,7 @@ These settings are far shorter in the beta phases than in the final version, in
defaultValue="songbird"
groupId="operational-parameters"
values={[
{label: 'Songbird', value: 'songbird'},
{label: "Songbird Canary-Network", value: 'songbird'},
]}>
<TabItem value="songbird">
| **Parameter** | XRP | BTC | DOGE |
Expand Down
40 changes: 13 additions & 27 deletions docs/fassets/7-songbird.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -6,33 +6,19 @@ keywords: [fassets, xrp, bitcoin, dogecoin, flare-network]

import JiraIssueCollector from "/src/components/JiraIssueCollector";

The launch of FAssets on the Songbird network demonstrates system behavior while paving the way for its next deployment on the Flare network. The primary goals of this test are to ensure the system operates as intended, identify edge cases, refine usability and automation, and incentivize whitehat security researchers to uncover potential code errors.

The test on Songbird will have the following characteristics:

- XRP will be tested first, followed by either BTC or DOGE;
- FAssets agents must be whitelisted by Flare Labs to perform their roles;
- Flare Labs will underwrite up to \$300,000 in FAsset issuance to cover any losses resulting from system issues, while imposing a cap of $2 million in issuance per asset.

## Duration of the Test

Each FAsset will be tested on Songbird for at least 6 weeks until no issues have been found.

## FAssets Minging dApps

FAssets system users can access the frontend web interface for minting and redeeming:

- [https://fasset.oracle-daemon.com/sgb](https://fasset.oracle-daemon.com/sgb)

## System Integrity and FAsset Pricing

During the Songbird test, restrictions and incentives may cause the FAsset price to deviate from the underlying currency's value.

The current focus is on testing system integrity, not price alignment.

## Vault Collateral

USDX will serve as collateral for FAsset agent vaults. To ensure sufficient support for FAsset issuance and possible liquidations on Songbird, a large amount of USDX has been minted.
The launch of FAssets on Songbird Canary-Network demonstrates system behavior while paving the way for its next deployment on Flare Mainnet. The primary goals of this test are to ensure the system operates as intended, identify edge cases, refine usability and automation, and incentivize whitehat security researchers to uncover potential code errors.

The test on Songbird Canary-Network will have the following characteristics:

| Parameters | Description |
| ----------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| FAsset Sequence | XRP will be tested first, followed by either BTC or DOGE. |
| Agent Whitelisting | FAssets agents must be whitelisted by Flare Labs to perform their roles. |
| Caps and Losses | Flare Labs will underwrite up to \$300,000 in FAsset issuance to cover any losses resulting from system issues, while imposing a cap of $2 million in issuance per asset. |
| Duration of the Test | Each FAsset will be tested on Songbird for at least 6 weeks until no issues have been found. |
| FAssets Minting dApps | FAssets system users can access the frontend web interface for minting and redeeming: <br/> - [`https://fasset.oracle-daemon.com/sgb`](https://fasset.oracle-daemon.com/sgb) <br /> - [`https://fassets.au.cc/`](https://fassets.au.cc/) |
| System Integrity and FAsset Pricing | During the Songbird test, restrictions and incentives may cause the FAsset price to deviate from the underlying currency's value. The current focus is on testing system integrity, not price alignment. |
| Vault Collateral | USDX will serve as collateral for FAsset agent vaults. To ensure sufficient support for FAsset issuance and possible liquidations on Songbird, a large amount of USDX has been minted. |

:::tip[Help improve FAssets]

Expand Down
68 changes: 68 additions & 0 deletions docs/fassets/8-reference.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,68 @@
---
title: FAssets Reference
description: Solidity reference for FAssets smart contracts.
keywords:
[
solidity,
reference,
fassets,
xrp,
bitcoin,
dogecoin,
flare-network,
smart-contracts,
]
---

import Tabs from "@theme/Tabs";
import TabItem from "@theme/TabItem";
import DocCardList from "@theme/DocCardList";
import SolidityReference from "@site/src/components/DataTables/SolidityReference";

## Deployed Contracts

<Tabs block>
<TabItem value="flare" label="Flare Mainnet">

| **Contract** | **Address** | **Description** |
| -------------------: | ----------- | --------------- |
| `AgentOwnerRegistry` | - | - |
| `FXRP` | - | - |
| `USDX` | - | - |


</TabItem>
<TabItem value="coston2" label="Flare Testnet Coston2">

| **Contract** | **Address** | **Description** |
| -------------------: | ----------- | --------------- |
| `AgentOwnerRegistry` | - | - |
| `FXRP` | - | - |
| `USDX` | - | - |


</TabItem>
<TabItem value="songbird" label="Songbird Canary-Network" default>

| **Contract** | **Address** | **Description** |
| -------------------: | ------------------------------------------------------------------------------------------------------------------------------------------ | ---------------------------------------------------------------------------------------------------------------------------------------- |
| `AgentOwnerRegistry` | [`0xa7f5d3C81f55f2b072FB62a0D4A03317BFd1a3c0`](https://songbird-explorer.flare.network/address/0xa7f5d3C81f55f2b072FB62a0D4A03317BFd1a3c0) | Manages agent whitelisting and allows setting and retrieving details such as work and management addresses, name, description, and icon. |
| `FXRP` | [`0xF9a84f4ec903F4EaB117A9c1098BeC078BA7027d`](https://songbird-explorer.flare.network/address/0xF9a84f4ec903F4EaB117A9c1098BeC078BA7027d) | The FAsset-wrapped TestXRP token, ready for use on Songbird. |
| `USDX` | [`0x4A771Cc1a39FDd8AA08B8EA51F7Fd412e73B3d2B`](https://songbird-explorer.flare.network/address/0x4A771Cc1a39FDd8AA08B8EA51F7Fd412e73B3d2B) | ERC-20 token used by FAssets. |

</TabItem>
<TabItem value="coston" label="Songbird Testnet Coston">

| **Contract** | **Address** | **Description** |
| -------------------: | ----------- | --------------- |
| `AgentOwnerRegistry` | - | - |
| `FXRP` | - | - |
| `USDX` | - | - |

</TabItem>

</Tabs>

## Interfaces

<DocCardList />
Loading

0 comments on commit 436cc13

Please sign in to comment.