Last active
May 11, 2021 17:20
-
-
Save david-botelho-mariano/44be10f8a3aae76d55cdf32dffadb474 to your computer and use it in GitHub Desktop.
download-xml.py
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@app.route('/ceps/xml/') | |
def baixarCepsXML(): | |
xml_base = dicttoxml(db_cep_json) | |
xml_base_str = xml.dom.minidom.parseString(str(xml_base)) | |
xml_pretty = xml_base_str.toprettyxml() | |
return Response(xml_pretty, mimetype='application/xml') | |
#return xml |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment