import requests


def word_freq(urn, words):
    """ Find frequency of words within urn """
    params = {'urn':urn, 'words':words}
    r = requests.post("https://api.nb.no/ngram/freq", json=params)
    return dict(r.json())