Hi Daren,
Sounds exciting!
Yes if you’re in the UK you would need a waste carrier license to collect coffee grounds (though I’m not sure if there is a certain amount you’d need to be collecting before you need a license)
You’d also need to register with your local council as a food producer and undergo some basic food hygiene training before selling the mushrooms. In our experience the council are very supportive and often offer the neccessary training themselves or can point you in the right direction (you can do the training online I think as well).
You’d also need to make sure any packaged products meet with the labelling and weights & measures regulations.
It all sounds more difficult than it is in practice. The environmental health department at your local council should provide you with all the info you’ll need to adhere to the law.
Best of luck with it all,
Adam