def METHOD_NAME(resource_id: str):
    results = {}
    for user in (users := redis.from_url(
            current_app.config["REDIS_URL"],
            decode_responses=True).hgetall("users")):
        user = json.loads(users[user])
        for q in (request.form.get("user_name"),
                  request.form.get("user_email")):
            if q and (q in user.get("email_address", "") or
                      q in user.get("full_name", "")):
                results[user.get("user_id", "")] = user
    return json.dumps(tuple(results.values()))