US Army whistleblower Chelsea Manning tried to kill herself in prison last week, her lawyers have confirmed.
Ms Manning, who is transgender, is serving a 35-year sentence at an all-male military facility.
Her lawyers accused the US military of violating her privacy by revealing that she had been admitted to hospital.
The army had not disclosed the reason for the hospital admission but it was linked to a suicide attempt in media reports.
Ms Manning's legal team said in a statement: "Last week, Chelsea made a decision to end her life.
"She would have preferred to keep her private medical information private, and instead focus on her recovery.
"She knows that people have questions about how she is doing and she wants everyone to know that she remains under close observation by the prison and expects to remain on this status for the next several weeks."
A tweet was sent from Ms Manning's account on Monday, reading: "I am okay. I'm glad to be alive.
"Thank you for all your love. I will get through this."
Tweets on the account are sometimes sent by Ms Manning's representatives but are usually dictated over the telephone by the prisoner herself.
Ms Manning was convicted in 2013 of leaking more than 700,000 secret files to Wikileaks.
She had been working as an intelligence analyst in Iraq.
She was convicted under her previous name, Bradley, and shortly thereafter announced she would start living as a woman.
Last year she was approved for hormone therapy after being diagnosed with gender dysphoria — the sense of one's gender being at odds with the sex assigned at birth.
She will remain a soldier in the US Army for the duration of her sentence.