Convert AttributedString to Markdown?

Is there a way of converting AttributedString or NSAttributedString to Markdown?