My daughter was similar and suffered really badly with this in sixth form. She had been the victim of bullying which had led to/exacerbated social anxiety which seemed to trigger IBS, and it got so bad that she was barely attending.
We saw a gastric consultant who said there was nothing he could do until the underlying anxiety was addressed and suggested a psychologist. The psychologist told us that the IBS was causing the anxiety and that this was what needed to be addressed. It was incredibly frustrating, and so awful for my daughter who was in pain daily.
We tried low FODMAP (such a faff!), gluten free, buscopan and countless other OTC medications, hypnotherapy, CBT but nothing seemed to work.
Eventually I took her to a psychiatrist, who was the one that made the formal diagnosis of social anxiety, and prescribed a low dose of setraline and this really helped. It did coincide with her making a lovely new group of friends, and one in particular was very caring and supportive so it is hard to separate the two factors, but there is lots of research supporting the link between the gut and the brain, and evidence that a low dose of antidepressants can help. I was reluctant to go down this road, but my daughter was very keen as she was so desperate to find something that worked. She hasn’t had any side effects.
From a point of complete despair in Y12 and thinking she would drop out, she has had the most fantastic summer. She traveled to Malaysia on a world challenge trip which she absolutely loved and is currently interrailing with a friend that she has become very close with. She’s doing the last bit solo which is something she would never have contemplated a year ago. She did really well in her A Levels, got her first choice (exceeded the grades) and is having a gap year as she wants to do more travelling. So I am very proud of all she has achieved, but I wanted to tell you this to give you a positive story. I know how debilitating stomach issues can be.