Mohammed Omar Mohammed Al-Attas, 33, appeared in the Dunedin District Court yesterday after he admitted two charges of speaking threateningly.
The court heard that on November 2, the defendant sent an email to a staff member at the Ministry of Social Development that read: "Me and my family are ISIS and I were plan [sic] to do ISIS activity in New Zealand".
The employee was "significantly" concerned and alerted police.
Al-Attas later sent a message to a counsellor stating: "F... this country, I want to go back to my original country".
"If I am not leaving, I will kill people."
After his arrest the defendant told police he had no connection with Isis and he did not agree with the organisation’s ideologies.
He said he was "fed up with racism and his way of life in New Zealand".
Further, he said he regretted accepting residency here and he hoped sending the threats might lead to him being deported to Yemen.
Counsel Meg Scally said her client was at a low point at the time of his offending and had significant mental health concerns.
"He wanted to initiate the deportation process because he was so desperately unhappy in the circumstances he was in," she explained.
Since then, the man’s health had improved and he had plans and goals that he was working towards in New Zealand.
Al-Attas failed in his bid for a discharge without conviction, which rested on the problems a black mark on his record could cause in his field of employment.
The court heard the man aspired to become a duty manager, but there was little evidence about how a conviction might impact that.
The defendant also asked for final name suppression as he feared for his safety if his name was published.
He said his fears were amplified by difficulties the Muslim community already faced.
Judge David Robinson declined both applications and said the threats appeared to have been taken seriously.
"There is a lack of evidence to establish anything beyond a relatively low-level impact," the judge said.
He sentenced Al-Attas to nine months’ supervision.