O'Henry used irony in "The Gift of the Magi". This tool was essential to developing the story's theme by showing that the couple bought gifts for each other that they could not actually use at the moment. In addition, the author used this fact to show that people of the society should treasure the things they've received from others, because you may never know if they sacrificed THEIR most treasured possession to aquire the gift.