That depends. The usual recommendation from suppliers is a huge number of critters, which will quickly starve when they run out of food. The sustainable number depends on a lot of factors and I would suggest ramping up the number slowly, seeing what works, rather than relying on a magic formula.
Note that crabs or all types are opportunist feeders. For best biodiversity, avoid crabs, including hermits.
As starting suggestions... maybe a dozen Astrea snails to keep the glass clean. For catching food, perhaps a serpent star and a dozen Nassarius snails. A small yellow cucumber is nice for keeping the sand clean.