Earlier quoted context omitted.
Don't mention a lawyer casually. Just have the lawyer send a letter. Don't give them the option to call your bluff. People casually mention a lawyer so frequently it means nothing. Receiving a letter from an actual lawyer means everything.
Having a lawyer send a letter isn't an automatic win. Once you turn it into a legal threat you force them to escalate to their legal team. Reasonable lawyers would likely roll their eyes and talk the university back from this weird move, but you're not guaranteed reasonable lawyers on the other end. If they feel threatened they might start looking even deeper into into contracts you signed as a way to protect themsel…
Sure. But I'd love to see what a legal defense would say to this situation of soft-expelling a student who was making use of a school provided API. then potentially extorting him with his graduation as leverage.