English Translation
I am your friend, right?
What purpose does “doch” play in this sentence?
I am your friend, right?
What purpose does “doch” play in this sentence?
It is strongly suggestive, like “really” or “after all” or “whatever may have been” or “don’t you forget it”
In this case it makes the question from an open one to a suggestive one:
“Ich bin Dein Freund, oder?” = "I am your friend, or not?
The “right” in English combines the alternative and the suggestion.
The other situation/reason why you might use “doch” in this sentence is when you get the impression that the other person does not think of you as a friend, while you thought the whole time that you were their friend.
So the “oder?” requests confirmation (isn’t that true?),
while the “doch” expresses that something was not as you expected (do you not think so?).
See also my explanation about “doch” here: Du darfst duch dich doch über so etwas nicht so aufregen!