# Off-Chain Tracker

Fluxity API tracks all streams and stores them in the database. This way, it will be easier for users to access their data on the dashboard. Other than that, each data entry on the Soroban network has a TTL (time to live), and if nobody extends that TTL, the data will expire from the ledger. The API is responsible for extending all streams' TTLs to make sure that all streams and everything related to them will stay on the ledger for a long.

Also, the server checks whether each stream is fully settled, and if so, the server would call the `withdraw_stream` function for that stream, and the receiver would get their remaining tokens. This is possible because anyone can call `withdraw_stream` every stream, even if they are not the receiver.

The motivation behind withdrawing someone else's stream is that after a stream is marked as "settled", then there would not be a need to extend its TTL anymore. This way, the API would not be spending XLM, and the receivers would automatically get their remaining tokens.


---

# 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://docs.fluxity.finance/features/off-chain-tracker.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.
