First of all - it`s just the URL with escaped special characters.
Python 3:
>>> from urllib.parse import unquote
>>> unquote('http%3A%2F%2F127.0.0.1%3A5000%2F')
'http://127.0.0.1:5000/'
Python 2:
>>> from urllib import unquote
>>> unquote('http%3A%2F%2F127.0.0.1%3A5000%2F')
'http://127.0.0.1:5000/'
So, I think, you should just unquote it when using it on Flask end.
Also, take in account that there are 2 versions of unquote - unquote()
and unquote_plus()
. As the manual says: unquote_plus()
is like unquote()
, but 'also replaces plus signs by spaces, as required for unquoting HTML form values.'
https://docs.python.org/2.7/library/urllib.html#urllib.unquote