A story is told about the Baal Shem Tov and the Maagid. The Baal Shem Tov wanted to teach the Maagid a lesson in hashgaha protis. So he told him to hide behind a tree and wait to see what happens for an hour and to make sure not to say anything in the meantime. As the Maagid looked on he saw a man gallop in on a horse sit down by a tree, drink, eat and fall asleep. He got up and got up on his horse and left but not without leaving behind a stack filled with money. The Maagid wanted to return the money to him but he couldn’t speak as per the Baal Shem Tov’s instructions. Then a business man came by saw the sack of money took it for himself and left. Again the Maagid wanted to speak up and say how could you take the other man’s money but he couldn’t say anything. Thirdly, a poor man came by sat down and rested. In the meanwhile the man who had lost his money came back woke up the poor man and demanded his money figuring he had hid it somewhere. When he said he doesn’t have it he shoved him around until he was sure that he is saying the truth. How is this fair thought the Maagid to himself, if anyone should get the money it should be the poor man and he's getting hurt for no reason.
The Baal Shem Tov explained that three hundred years prior there was person who borrowed money from a business man and didn’t pay back so the business man took him to court. The man bribed the judge who ruled in his favor.
So they all three had to be reincarnated into these three people the man who lost the money was the thief and he owed the money to the businessman whom he didn’t pay back all those years ago. The business man got back his money and the thief lost it and was able to pay back the business man in such a way. The poor man who got beat up that was the Rabbi who had taken the bribe.