All they needed to do was change how they handled the API for third party apps. Charging for it isn't the issue, it's the prohibitive cost they decided to attach to essentially ALL API access regardless of use, as a response to Large Language Models scrapping the site.
They could have introduced separate pricing for confirmed 3rd party app usage for individuals. Or they could have introduced individual API tokens for 3rd party app use, and locked it behind something like a reddit gold subscription. Even that would be better than effectively killing all of it off.
It's clear they did absolutely no brainstorming about other options before deciding to nuke it all.