As howdelightfull says okagesamade means literally "thanks to you".
It is actually used to express one's gratitude when someone is helped, like "okagesamade mise no basho ga wakarimashita", meaning "thanks to your help I finally found the store."
But in this context, unless the listener is a doctor or a nurse, there is usually no connection between that the speaker is fine and that the listener did something. So here it means nothing and the speaker just shows politeness. If I am spoken to this way by a non-native speaker of Japanese, I would feel he (or she) is not a beginner at least .