Sounds similar to a form of human colitis except in a dog. Polyps or ulcers in the intestines could be causing the bleeding and the mucus. You should take your dog to a vet, perhaps even call ahead of time and see if they'll need you to bring a stool sample.
There is also good information about this online here: en.allexperts.com
There is also good information about this online here: en.allexperts.com