An immigrant teen who was denied an abortion by a U.S. government official, even though her pregnancy was caused by rape, had threatened to harm herself if she was forced to have the child, according to a government memo released Friday.

The memo is addressed to Scott Lloyd, director of the Office of Refugee Resettlement, which shelters thousands of unaccompanied immigrant minors in the U.S. without legal permission. The American Civil Liberties Unio posted the memo as part of its ongoing lawsuit over abortion access for immigrant minors in custody.

The document describes how the teen was raped in her home country and believed she had become pregnant as a result. According to the memo, written by the Office of Refugee Resettlement's deputy director, she told a doctor during her first pre-natal visit that she wanted an abortion. The teen "disclosed to the medical doctor that she preferred to harm herself rather than to continue with her pregnancy."

REPORT REVEALS 92 PERCENT OF FOREIGN NATIONALS IN FEDERAL PRISONS ARE ILLEGAL IMMIGRANTS

In later visits, the teen reported the pressure her mother and a potential sponsor were putting on her to keep the pregnancy. At one point, she reported facing "physical harm" if she had the abortion.

"She felt pressured by her mother and potential sponsor to continue the pregnancy, but she wants to terminate the pregnancy," the memo said.

While the recommendation of the deputy director is blacked out, Lloyd circled the word "disapproved" at the bottom of the memo and signed it. The teen and another minor eventually received access to an abortion after U.S. District Judge Tanya Chutkan ruled in their favor this week.

In a letter about the case that was disclosed in court filings Thursday, Lloyd argued he saw no obligation under the law or the U.S.

Constitution to allow abortions for people in his office's custody, even though government policy restricting abortion broadly has an exemption for women who were victims of rape.

WHAT IS DACA AND WHY IS THE TRUMP ADMINISTRATION ENDING IT?

He also said an abortion would not "cure the reality" of the woman's rape. Both abortion and rape were forms of violence, he said in his letter.

"Implicit here are the dubious notions that it is possible to cure violence with further violence," he said.

The ACLU accused Lloyd of implementing a "cruel and heartless policy," and pledged to continue fighting it.