Colorado shooting suspect, James Holmes
The suspect in the Colorado cinema shooting was being treated by a psychiatrist at the university where he studied, according to court records.
Earlier reports said James Holmes, 24, had sent a notebook describing a massacre to the university.
Defence lawyers are seeking the source of the media leak, saying it violated a court order and put a fair trial in "serious jeopardy".
The neuroscience drop-out will be formally charged on Monday.
The court said it would consider the defence team's request then.
The suspect's lawyers argued that the notebook was a communication between a patient and his doctor, and was therefore confidential.
It is unclear if the package reportedly containing the notebook arrived at the university before the July 20 shootings.
University officials say it was delivered and investigated on Monday, July 23, but US media reports had suggested otherwise.
The legal motion described Holmes as a "psychiatric patient" of Dr Lynne Fenton at University of Colorado Denver, where he was in the process of dropping out as a neuroscience PhD student.
Dr Fenton is a member of the campus-based behavioural and threat-assessment team that helps staff deal with "problematic" individuals, reports Reuters news agency.
James Holmes is accused of killing 12 and wounding 58 during a midnight showing of the new Batman film in Aurora near Denver a week ago.
Of the wounded, 11 remain in hospital, with five in critical condition.