I've had them, my kids have had them - clean all the things and take a medication called Pyrantel.
The stuff from Reese (probably what you'd find in most pharmacies), tastes like banana chalk. The one below was a much more tolerable vanilla-ish flavor plus cheaper overall and per ounce.
Take a dose every 1-2 weeks until everything clears up (and a few more after that if you want to be double sure).
https://www.amazon.com/Oral-Pyrantel-Pamoate-Suspension-Ounce/dp/B0771WYDR5/
Yeah I was irritated when I didn’t get information about the dosing but I didn’t push because she seemed irritated for some reason.
What type of worms did your dog have? I believe this is sold for human use, though it can be used on pets as well.