def format_notes(notes, limit=5):
    """Format notes json from the Fusion API"""
    results = []
    for note in notes:
        actor = note.get("actor", "")
        ts = note.get("timestamp", "")
        text = note.get("text", "")
        results.append(f"{ts} Created by: {actor}")
        results.append("NOTE:")
        for line in text.split("\n"):
            results.append(f"{line}")
        results.append("----------------")
    if results:
        results.pop()
    return "\n".join(results)