Well, it is possible to broach on a lathe, but it’s non-trivial. Assuming you have a proper broaching tool in there, you’ll want to start at least an inch away from the part to give it room to accelerate inwards, then drop away from the part before retracting it for the next pass. You’re looking at taking roughly 0.001” per pass with a feed in the 200–500 IPM range, so it will take a while. And you better be damn sure that chuck is locked because you don’t want that part rotating on you. I’ve also seen broaching with a boring bar
Now, I don’t know if there is a Mazak macro for it. Odds are that you’re looking at a user-defined canned cycle, but I’m only familiar with Fanuc, Haas, Siemens, and Mitsubishi controllers so I can’t tell you how it’d work on a Mazak and am hesitant to give you code that’d work on the machines I’m familiar with in case Mazak does something different.