Ducks dont tend to get worms as often as chickens- but they can still get them. I will occsionally give my ducks a precautionary dose when I am noticing a lot of wild birds visiting the yard- but I have yet to see any real evidence of noticeable infestations of worms in any of my birds over the years. Round worm is the most common but they can also get Gape, Gizzard and Tape worms.
Worming for poultry is recommended twice a year- once after the breeding season- and again at the end of winter before they come back into lay. Some products will have an egg withdrawal period as well- so worming when they are not laying prevents having to worry about how long after worming not to use eggs for. Also- each time you should give two does- one to kill any worms present- and again about three weeks later to kill of any that have hatched from eggs during that time.
Ivermectin is one product able to be used with ducks- but there is no specific dosage given. There are others that are ok for use with poultry- but you have to be fairly careful when calculating a dose- as they generally arent given on the packs. The product I buy are actually for caged birds and pigeons, active constituent is Piperazine Anhydrous. I just find it easier as its a small bottle- so less wastage - easier to calculate the dose at is is designed for birds- and a liquid that can be added to drinking water.