Hi there.....was it a red tissue ? Have you always watched when he poos, and this seemed different to you , or did you just happen to be watching this time ? It's most likely nothing harmful, but keep an eye on it. If you saw a slight pointy tissue at the side of his vent it may have been a hemi pene [ one of his sex organs ] This does happen at times but is not anything to worry about unless it does not retract. Sometimes a sperm plug may pop out , but these are a tan/yellowish looking thing. [ Google bearded dragon sperm plug for pics ] A vet can't do anything for an " almost prolapse , " but some things you can do are to make sure the prey items he eats aren't too large, make sure he stays
hydrated, has good calcium supplementation, but not so much that it causes hard urates, and you can always have a fecal test done to rule out high numbers of parasites. But he should be fine.