First of all, clean your toilets more frequently... you're better than that. Second of all, I've got nothing. I'd probably pour some bleach in there and hope it would but him and get him to exit the toilet.
Its just a rat snake, great climbers. Im guessing it was on your roof and found an open vent, decided to get out of the ridiculous heat and climbed in. You can grab it, it cant hurt you. It may be angry and try to bite but the bite is like rubbing some angry Velcro, way easier than road rash.
Be a man, reach in and grab it. Put it in your yard so it can eat rodents and shit. Rodents are worse than snakes.
He’s probably out buying another case of shotgun shells, a new toilet, a fridge, hot water heater and a couple buckets of drywall mud to patch all the holes from trying to blast that snake with shotgun. I shot the tur-let 7 times but the snake got away! He was fast and shifty!
I closed all the toilets in the house and put cinderblocks on top of each one. I poked him with a barbecue prong (weird coincidence @dave3593 lol) and he disappeared up the pipe. Haven't seen him since, but I'm on septic, so he's still in there somewhere (and likely just a bit further down the P-trap). Next time I see it I'm not gonna be all "eww" softie, I'm just gonna stab the fucker to keep him from disappearing, and then... go from there. Yes, as other ppl have pointed out it's probably harmless and the nice thing to do would be release it outside... but I ain't keen on taking the chance. If I saw a random human squatting underneath my house they'd stand a decent chance of getting stabbed too.