Under a proposed agreement to settle damages in its e-book price-fixing case, Apple could pay consumers as much as $400 million—or, potentially, nothing. After announcing the deal last month, the final details of Apple’s proposed settlement with the states and the consumer class were filed today with Judge Denise Cote in New York, and as reported, any consumer payments will be contingent upon the Second Circuit’s review of Cote’s 2013 verdict against Apple.

If Cote’s decision is upheld by the Second Circuit, Apple has agreed to pay $400 million to consumers. If the case is remanded for further proceedings, Apple will pay $50 million to settle the case. And if the Second Circuit reverses Cote, Apple will pay nothing. If the decision is upheld, Apple will also pay the 33 states $20 million to resolve claims for “costs, fees, and civil penalties.”

Consumers, however, shouldn’t expect to see refunds quickly. While the parties have asked the court for preliminary approval, they have also asked that the final process of securing the settlement be deferred until after the Second Circuit decides Apple’s appeal. That could take months, even years. In addition, the settlement would then have to be formally approved, which could include a public comment period, a final fairness hearing, as well as ironing out numerous logistical details.

In a stroke of good news for the publishers, the settlement funds (if there are any, pending the Second Circuit’ decision) will be distributed using the same template as the publisher settlements, which automatically distributed the refunds as book and e-book credits to consumer accounts, unless a consumer opted for a check . In other words, the decision could mean a potential windfall of Apple money that would flow into consumer accounts, and ultimately back to the publishers in the form of book purchases. (Clarification: according to the settlement agreement, refunds to consumer accounts can be used to purchase of "any product or service" offered by the retailer, unlike the publisher settlements which specified that settlement funds must be spend on books).

In a release, attorneys for the consumer class sounded confident consumers would see refunds, eventually. “We have obviously studied Judge Cote’s July 2013 ruling in detail, and believe that the Second Circuit will agree with her conclusion that Apple did violate federal antitrust laws,” said Steve W. Berman, managing partner of Hagens Berman and lead attorney representing the consumer class. But, he acknowledged, "in any case of this magnitude, there are high degrees of uncertainty, and Apple’s appeal of Judge Cote’s well-reasoned ruling is an example of that uncertainty."

Meanwhile, in an appeal brief filed this week with Second Circuit, Apple stressed the unprecedented nature of Cote's 2013 decision, and doubled down on its belief that Cote simply botched the case, by relying on too many inferences drawn from “highly ambiguous” evidence, and ignoring the "pro-competitive" nature of Apple's entry into the e-book market.

“Never before has a court found a company liable under the antitrust laws for entry into a market dominated by a single company, through admittedly vertical and lawful distribution agreements, to launch an enterprise that the court admitted benefited consumers and competition, where the company did not desire higher prices and the agreements did not specify prices to be charged, and which resulted in more competition, lower market prices, and increased market output,” Apple attorneys argued. “Plaintiffs do not cite a single analogous case, and there is none. The district court’s decision finding Apple per se liable under the antitrust laws was therefore reversible error.”

Apple's settlement comes after a string of defeats in the damages phase of the litigation, including a decision by Judge Cote that disqualified its two main expert witnesses. Apple had faced as much as $840 million in damages after trebling, if it had lost at trial.