WASHINGTON (AP) — Insurance giant American International Group Inc. is better positioned to pay back all of its $182 billion federal bailout, a key Treasury official plans to testify Wednesday.

But AIG's ability to repay taxpayers depends on its future profitability and the insurance industry's strength, Treasury chief restructuring officer Jim Millstein says in his prepared testimony. He says AIG must complete the planned sales of two large insurance subsidiaries and regain the market's confidence.

"It will take time to repair in full the damage to their franchises, particularly in the United States," Millstein says.

AIG received the largest bailout of any company during the financial crisis that crested in September 2008. The company could not meet its financial obligations after selling guarantees on mortgage-related investments that later lost value.

Millstein is scheduled to testify before the Congressional Oversight Panel, which is monitoring the $700 billion financial bailout. The panel has criticized officials who managed the bailout for failing to consider alternatives, such as filing for bankruptcy or demanding concessions from AIG's creditors.

The panel already heard from a regulator who failed to halt AIG's near-collapse and from officials who managed the rescue for the Federal Reserve Bank of New York.

AIG CEO Robert Benmosche is testifying that AIG is less reliant on government aid because it has been able to raise money from private investors in recent months.