There was a conspicuous addition to the cast during the Season 7 premiere of “Game of Thrones.” As Arya Stark made her way on horseback through the Riverlands after murdering the entire Frey clan, she was captivated by the sound of harmonic cheesiness floating on the breeze. She had stumbled upon a musically inclined group of soldiers, including one played by pop star Ed Sheeran, who was leading a folk song.

It was a little jarring to see the ginger megastar — a Taylor Swift bestie with copious tattoos — wearing armor and a red cape passing around blackberry wine and a charred rodent. But, hey, Harry Styles plays a soldier in Christopher Nolan’s new war movie “Dunkirk,” so who are we to judge? The question is: What was Sheeran doing there? Because the show doesn’t usually resort to stunt casting. It doesn’t need to.

[Ed Sheeran concert packs Bangor waterfront]

It’s actually a sweet story. Twenty-year-old actress Maisie Williams, who plays Arya, is a huge fan of the “Shape of You” hitmaker, so showrunners David Benioff and D.B. Weiss recruited him for an episode as a surprise for her. Growing up in the limelight is no picnic, as Williams and her onscreen sister Sophie Turner can attest, but it does have its perks.

Sheeran had warned fans that it wasn’t much of a scene. In an April interview, he broke the cardinal rule of “Game of Thrones” actor interviews by revealing what would happen during his scene.

“I don’t die in it,” he explained. “I’m only in it for like five minutes.”

He also said he’d rather portray a “Game of Thrones” character who has sex than one who dies, but he didn’t get to do either. He had only a couple of lines.

After Arya told him she liked his song, he said, “It’s a new one.” Then he mostly just sat around while more experienced actors did the talking. It wasn’t entirely a throwaway scene. The soldiers are important simply because they’re nice to Arya, offering her food and booze, before explaining their role as peacemakers in the Riverlands. The young assassin hasn’t met many kind-hearted people in her short life, especially not recently while hanging out with the Waif at the House of Black and White. But just after murdering an entire clan in a Red Wedding redux, she meets a group of people who live by the golden rule. How instructive.

Then again, the idea that Ed Sheeran and his merry band will help soften her drive for vengeance is hard to believe. When the men ask Arya where she’s headed, she tells them King’s Landing. She’s planning on murdering the queen, she says matter-of-factly. Naturally, the guys think that’s a laugh riot, so she laughs along, too.

Most likely, that’s the last we’ll see of Sheeran. Arya has some killing to do.

This isn’t the first time “Game of Thrones” has employed musicians to do what they do best. Members of Coldplay, Sigur Ros and Of Monsters and Men have also had cameos, mainly providing background music. But Sheeran’s part is certainly the most high-profile.

At least it isn’t Sheeran’s first acting gig — though it’s probably the first one anyone has actually seen. He had a role on the FX series “The Bastard Executioner.” The “Game of Thrones” wannabe was quickly canceled after one season.