Hello,
They are both reply sentences when someone says thank you. Both are okay to use. We'd prefer rica ederim when we are replying formally (though bir şey değil would not be rude to use). It is perfectly okay to say rica ederim to a close friend as well.
I hope this helps.