Stone extraction baskets are used for the endoscopic removal of bile duct stones and foreign bodies.