The top seed was in command from the beginning of the match which lasted for two hours and 11 minutes. Medvedev started the match with a service break establishing his authority over the French player.
Williams, who is now 40 and holds the current ranking of No. 605, upset Estonia's Anett Kontaveit, the No. 2 seed, in a see-saw encounter, to advance to the third round of the US Open. This win keeps her pursuit of Margaret Court and the record 24 major victories alive.
Osaka has received a wild card into a court that already includes Wimbledon champion Elena Rybakina, World No.5 Ons Jabeur, American teen Coco Gauff and 2019 US Open champion Bianca Andreescu.
In a battle between two wildcard teams, the all-British pairing of Barnett and O'Mara edged former Doubles World No.1 players Williams and Murray, 3-6, 6-4, 7-6[18-16] in a two-hour and 12-minute clash on No.2 Court.
In her Centre Court debut, Anisimova dropped the first set from a winning position, but she bounced back in two hours, 7 minutes for a 6-7(4), 6-2, 6-1 win.