# Fees

The fee structure consists of four components: gas fees, risk coverage, opportunity costs for fillers, and system costs.

## Gas fees

Under the design of CCTP Express, users only sign an off chain message to submit an order, paying no gas fee. Fillers pay gas fee to initiate order at the origin chain, and transfer fund to the user at the destination chain. These gas fees are chargeable to the users.

## Insurance fee

This fee acts as an insurance to cover the reorg risk exposed to the fillers. There is chance that the origin chain reorg after the filler transferred fund to the user at the destination chain. \
\
An user specifies an `initiateDeadline` when he creates an order, fillers can initiate an order again at the origin chain before this `initiateDeadline` in case there is a reorg. Hence, the shorter the deadline, the higher reorg risk is exposed to the filler. This insurance fee is designed to varies with the `initiateDeadline` to cover this risk:

<figure><img src="https://131966688-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FFaA5rrAIiExQEcVyNvp7%2Fuploads%2F0PNxnvZ6fHIs3kbFn3Uf%2FScreenshot%202024-08-21%20at%206.11.58%E2%80%AFPM.png?alt=media&#x26;token=ec80b229-79a5-4938-9cb9-d6a6935a3f47" alt="" width="244"><figcaption></figcaption></figure>

Where:

*f(t)* is the insurance fee which is a function varies with t\
\&#xNAN;*V* is the trading volume, representing the maximum insurance fee\
\&#xNAN;*e* is the base of the natural logarithm\
\&#xNAN;*k* is a constant that control the descending rate of the fee\
\&#xNAN;*t* is the time between order creation time and the `initiateDeadline`\
\&#xNAN;*T* is the time required for finality on the origin chain\
\
The insurance fee varies with the `initiateDeadline`- it decreases with the increment of time between the order creation time and the initiateDeadline:

<figure><img src="https://131966688-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FFaA5rrAIiExQEcVyNvp7%2Fuploads%2FSgKeTnECGqu06sEDMOBS%2Fgraph.png?alt=media&#x26;token=51d92c0b-3c1a-4328-9619-85947259da78" alt="" width="361"><figcaption></figcaption></figure>

<table><thead><tr><th width="229">Scenario</th><th>Result</th></tr></thead><tbody><tr><td>t = 0</td><td>f(t) -> V</td></tr><tr><td>0 &#x3C; t &#x3C; T</td><td>f(t) decreases with t, the rate of descending increases</td></tr><tr><td>t = T</td><td>f(t) = V/2</td></tr><tr><td>t > 2T</td><td>f(t) -> 0</td></tr></tbody></table>

As the `initiateDeadline` does not impact the order fill time, a normal user is expected to set an `initiateDeadline` long enough to avoid paying any insurance fee.

## Cost of Capital

Fillers use their own funds to pay users on the destination chain and are repaid at a later time. This process incurs a capital cost due to the forfeiture of alternative yield opportunities.&#x20;

## System costs

System costs includes gas fees for repayment and rebalancing via CCTP. These overhead expenses are distributed among multiple transactions, as the Datadaemon processes transactions in batches.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://cctp-express.gitbook.io/cctp-express/concept/fees.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
