You probably need to store user IPs to moderate.
At least on Mastodon, any instance stores IP, so....
At least on Mastodon, any instance stores IP, so....
You can target a list of suspected spammer IPs, though that's often a losing game of cat and mouse where you end up missing some spammers and catching legitimate users in the crossfire.
For Mastodon, all of this is manual, so it will be up to moderators on the server....