The Obama administration spent $36.2 million defending itself in Freedom of Information Act lawsuits in its final year, The Associated Press reported Tuesday.

According to the AP's analysis, some of the biggest targets for record requests were the Justice Department, the Department of Homeland Security and the Defense Department. The Justice Department spent $12 million, Homeland Security spent $6.3 million and legal costs totaled $4.8 million for the Defense Department.

The administration also set records for its denial of access to requested documents and information, the news service reported, as well as the number of times federal workers claimed that could not find information that was requested by members of the public.

ADVERTISEMENT

Former President Obama boasted that his was "the most transparent administration in history," but that statement stands at odds with the AP's reporting.

During Obama's final term in office, the number of FOIA lawsuits filed by news organizations increased drastically.

President Trump has had an often-antagonistic relationship with the press during his campaign and in the early weeks of his administration. During his presidential campaign, Trump suggested opening up libel laws to make it easier to sue journalists and news organizations.