Real had already qualified for the 32-team event in the United States by virtue of winning the 2022 Champions League.
Carlo Ancelotti has claimed Real Madrid and other clubs will “refuse” to play at Fifa’s expanded Club World Cup.
O’Shea’s Ireland side face Ronaldo’s Portugal in a friendly.
Carlo Ancelotti won the 2024 Champions League title with Real Madrid