It can be between any two people of which one has previously helped the other, and the other acknowledges it.
Example 1: Your car breaks down and your friend comes with a mechanic and we fix your car. You would say Thanks, I am much obliged.
Example 2: You cannot solve a math problem at work and you are in a hurry. A coworkers comes to your desk, sits down, explains the problem so you can finish the math and turn in your report on time. You are very happy and later you tell your boss that you are thankful and obliged to the coworker.