You can export your article from Medium in account settings. Then you need a HTML to Markdown converter. I found this thing quite helpful.
However, remember that Markdown is meant to be rendered as HTML, not the other way around. So, the conversion to markdown will not be completely successful. You still need to review your article before you post it.