def _get_describefeaturetype_url(url, version, typename):
    """Get url for describefeaturetype request

    :return str: url
    """

    query_string = []
    if url.find('?') != -1:
        query_string = cgi.parse_qsl(url.split('?')[1])

    params = [x[0] for x in query_string]

    if 'service' not in params:
        query_string.append(('service', 'WFS'))
    if 'request' not in params:
        query_string.append(('request', 'DescribeFeatureType'))
    if 'version' not in params:
        query_string.append(('version', version))

    query_string.append(('typeName', typename))

    urlqs = urlencode(tuple(query_string))
    return url.split('?')[0] + '?' + urlqs
dataset/ETHPy150Open geopython/OWSLib/owslib/feature/schema.py/_get_describefeaturetype_url/original