'Returns whether or not the user has exceeded their throttle limit. If
throttled, can return either True, and int specifying the number of
seconds to wait, or a datetime object specifying when to retry the
request.
Maintains a list of timestamps when the user accessed the api within
the cache.
Returns ``False`` if the user should NOT be throttled or ``True`` if
the user should be throttled.'

def should_be_throttled(self, identifier, **kwargs):

    key = self.convert_identifier_to_key(identifier)
    now = int(time.time())
    timeframe = int(self.timeframe)
    throttle_at = int(self.throttle_at)
    minimum_time = (now - timeframe)
    times_accessed = [access for access in cache.get(key, []) if (access >= minimum_time)]
    cache.set(key, times_accessed, self.expiration)
    if (len(times_accessed) >= throttle_at):
        return (timeframe - (now - times_accessed[(- throttle_at)]))
    return False
