I believe that the Slack API (if your company uses Slack) can be persuaded to give you the list of deactivated accounts. Then you just check this into git (on a daily basis), and you are done.
And, of course, in this AI Agentic world, you can probably ask your HR bot about the recent layoffs and get the information even more easily!