Here are two reason for green (pea soup) diarrhea in dogs. I'm sure there are more!
Giardia
Infectious Enteritis
One cause is eating grass or leaves. Many dogs do this to help clear out their gut when they have a stomach problem. The green stool itself isn't the problem, it is a symptom of the dog's 'home...
High wheat levels in the diet.
Green Stool indicates that your food has passed through your intestines faster then normal, before it can be changed to green to brown.
It may be cause by liver problems. You must watch out for this condition and go to vet immediately.
Excess of B vitamins, commonly from supplements with very high levels of B-group. It's harmless and should sort itself out. Drink plenty of water.