NICOLA Sturgeon’s political authority is “absolutely solid”, one of her closest allies has insisted despite a week of upheaval in the SNP group at Westminster.

Social Justice Secretary Shona Robison also said the party was “united” in recognising the First Minister’s leadership.

The claim comes after Ms Sturgeon’s preferred candidate to lead the party’s 44 MPs was soundly defeated in an internal contest, raising questions about her own influence.

Aberdeen South MP Stephen Flynn defeated Glasgow Central MP Alison Thewliss by 26 votes to 17 to replace Skye MP Ian Blackford.

After previous denials that he was under threat, Mr Blackford stepped down when it became clear Mr Flynn had the support of enough MPs to oust him.

Ms Thewliss, whose Westminster constituency overlaps Ms Sturgeon’s Holyrood one, was seen as a proxy for the SNP leader, and her candidacy as a bid to block Mr Flynn.

Opposition parties branded her loss a “humiliation” for the First Minister.

Ms Robison’s ex-husband, Dundee East SNP MP Stewart Hosie, later claimed reports of splits in the SNP group were a “complete fiction”.

However the next day the party’s longest serving MP, Pete Wishart, launched a stinging attack on its new leader, saying he was “bemused” by his arrival.

READ MORE: Pete Wishart hits out at Stephen Flynn as he quits SNP frontbench

Mr Wishart also claimed Mr Flynn had been campaigning for the leadership against Mr Blackford for some time, fuelling claims there had been a “coup” in the party.

Mr Flynn is seen as more willing to stand up to Ms Sturgeon than Mr Blackford, especially over her plan to fight the general election as a ‘de facto’ referendum on independence.

Many senior SNP figures are concerned that the idea - already dismissed by Unionist parties - could backfire, and by the lack of detail about how the SNP would fight it in practice.

Mr Flynn today made the point that MPs would be “on the frontline” in such a contest.

"My colleagues have a lot at stake in that regard. It’s us who will be on the frontline and I have no doubt our voices will be heard in relation to the up coming debate,” he told the Herald on Sunday.

READ MORE: Interview: Flynn hints at doubts over de facto independence vote

On BBC Scotland’s Sunday Show, Ms Robison was asked about the goings-on in the SNP’s Westminster group and if Ms Sturgeon’s authority was “as solid as it ever was”.

She replied: “Yes, it is. Absolutely solid. And people recognise the leadership that Nicola Sturgeon is providing in these tough times, and that is united across the party. Absolutely.” 

Mr Blackford was seen as having mishandled the sexual harassment scandal around former Glasgow North SNP MP Patrick Grady earlier this year, urging fellow MPs to support him despite previously boasting he took a “zero tolerance” to such misconduct.

The former financier is now in charge of SNP efforts to woo businesses over independence.

The Sunday Times reported that Ms Sturgeon has been left “exasperated” by the week’s events in the Westminster group, with one of her supporters blaming “outrageous egos and naïveté”,

A source also told the paper the First Minister “did not take” to Mr Flynn when she met him for the first time earlier this month.

His choice of Paisley MSP Mhairi Black as his deputy was criticised.
Questioning her work ethic, one SNP MP said she had "done the square toot of f*** all down here".

However a source close to Mr Flynn fiercely defended her.

"It's a stroke of luck he has Mhairi as his deputy.

"She is one of the best communicators in the business, se has a fire in the belly and she's exactly the person he wants in the fight for independence.

"She is a huge asset in the campaign ahead."

With the three most recent polls showing a lead for the Yes side since the Supreme Court stymied Indyref2, Ms Black is expected to be given a campaigning role in Mr Flynn's refreshed team.