Twilight Sparkle always had a feeling that ponies were not alone in the universe. When he arrived in Equestria, she was proven right.
After he uncovered and subsequently overthrew a plot to kill the two princesses, they sent him back to his world. However, the curiosity of Princess Celestia was still unsatisfied. She had a glimpse of this other world through the mind of this one man, this agent of a service known as 'MI6', but wanted to know more. To this end, she resolved to send her former student there, in an effort to understand more of the human race and, perhaps, meet their mutual friend once again.
Who was this friend, you ask?
Bond. James Bond.
After disastrous events in Istanbul, 007 ends up in Equestria.
A few months after a conspiracy to overthrow the princesses of Equestria was thwarted, with the help of an unlikely ally, Celestia sends the newly crowned Princess Twilight, alongside one of her friends, to the world from which their ally came.