That's actually an interesting question. Because the narrator can go to heaven and learn what is happening there, we would have to suppose the story is told by a supernatural being. It could be, therefore, that an angel is narrating the story. So much of the story revolves around the statue of the Happy Prince that it would be logical to assume the the story is told from the point of view of a guardian angel who has been sent to watch over the Happy Prince.
An angelic or supernatural narrator would also understand "swallow" talk and "statue" talk, which would not be readily discernible to human beings. An angel would, as well, have the ability to fly invisibly after the swallow and witness his good deeds. Additionally, an angel, as a messenger between God and humans, would have access to heaven.
That this is a children's story adds credence to this idea. Wilde could very well be wanting to tell children that angels watch over us and reward good deeds of kindness and compassion.