Common Usage

TRON DAO
TRON
Published in
2 min readOct 11, 2019

Add a File

Run the btfs add command:

Get a File

Run the btfs get command:

File Pinning

In the default configuration, BTFS nodes garbage collect their cache when the storage exceeds the max capacity threshold set in the configuration file. Pinned files, however, are exempt from the garbage collection process.

You can also publish the uploaded file for your local BTFS node to host:

Check your local BTFS node’s peer ID to see which file is hosted:

View your hosted file through the gateway at https://gateway.btfssoter.io/btns/<PeerID>.

Domain Binding

Domain binding allows you to display the hosted file path as a standard URL domain rather than the peer ID of your BTFS node. For example, assuming you own “www.heart.com", domain binding allows you to create a URL path like https://gateway.btfssoter.io/btns/heart.com/.

To bind the domain, the domain DNS settings must be changed by adding a DNS TXT record of the form “dnslink=/btfs/<peerID>”.

--

--