LOS ANGELES, July 13 (UPI) -- Taylor Swift was indeed the creative mastermind behind ex-boyfriend Calvin Harris' latest hit.
The 26-year-old singer's rep confirmed Swift wrote Harris and Rihanna's song "This is What You Came For" in a statement to People Wednesday.
"Taylor Swift wrote 'This is What You Came For' under the pseudonym Nils Sjoberg," the rep told the magazine.
TMZ had reported Swift's rumored involvement earlier in the day. Sources told the website the singer wrote the song for Harris during their relationship and recorded a full demo with the DJ in the studio.
Insiders said Swift and Harris ultimately agreed to keep the collaboration secret, but that the singer kept publishing rights to the song. Harris instead released the track with Rihanna in April and the song became an instant hit.
Swift and Harris announced their split just weeks after the song's debut. Sources now say "the breaking point" came when Harris publicly dismissed the idea of working with Swift the day their secret collaboration was released.
"You know, we haven't even spoken about [working together]," the DJ had told On Air with Ryan Seacrest. "I can't see it happening, though."
Swift has since started dating actor Tom Hiddleston. The pair were spotted kissing shortly after the singer's split from Harris and made their Instagram debut as a couple last week.