Subletting your home on Bnb platforms… how does it work?

It is tempting to sublet your home on Bnb rental platforms. But what are your rights and how does it work?