By the mid-18th century, they aspired to rule the North Indian empire and influenced the Mughal court.