def _oauth_signature(consumer_token, method, url, parameters={}, token=None):
    parts = urlparse.urlparse(url)
    scheme, netloc, path = parts[:3]
    query = parts[4]
    normalized_url = scheme.lower() + '://' + netloc.lower() + path

    sig = (
        _oauth_escape(method),
        _oauth_escape(normalized_url),
        _oauth_escape(_get_normalized_parameters(parameters, query)),
    )

    key = '%s&' % _oauth_escape(consumer_token['secret'])
    if token:
        key += _oauth_escape(token['secret'])

    base_string = '&'.join(sig)
    hashed = hmac.new(key, base_string, hashlib.sha1)
    return binascii.b2a_base64(hashed.digest())[:-1]
Return the template data from the series_id passed in
dataset/ETHPy150Open moraes/tipfy/tipfy/auth/oauth.py/_oauth_signature--crossover with--dataset/ETHPy150Open sahana/eden/modules/s3db/survey.py/survey_getTemplateFromSeries