# Migration guide: annualised auction yield

> What bridge facilitators must change for the annualised auction yield cutover — the rateBasisSeconds field, the universal expectedReturn signing rule, before/after code, and a checklist.

From **Friday 23 October 2026 (CET)**, auction rates move to an APR (365-day year, simple interest) and every auction carries an explicit `rateBasisSeconds`. This page lists what you must change and when. For the full field reference, see [Onboarding § Auction pricing fields](/bridge-facilitator/onboarding/#auction-pricing-fields) and [Pricing an offer](/bridge-facilitator/onboarding/#pricing-an-offer).

## What changes

- **`rateBasisSeconds` on every auction.** `GET /v1/auction` returns it on every auction. It is the period `expectedReturn` is earned over, fixed when the auction is created:
  - `31536000` (365 days) on **annual** auctions: every auction created after its vault switches to APR pricing, and every retarget auction.
  - The asset's settlement delay in seconds on **legacy** auctions, created before their vault switched (for example `2678400` for a 31-day FalconX auction). Legacy auctions behave exactly as auctions do today. Expect a few right after the cutover, while auctions opened before it finish.
- **`maxRate` is always an APR** in basis points (tenths precision), on annual and legacy auctions alike. It ramps over the Dutch auction, for example from `1095` to `1825` on JAAA, so read it close to submission.
- **One signing rule for every auction:** `expectedReturn = floor(amount × aprBps × rateBasisSeconds / (10_000 × 31_536_000))`.
- **Wrong-basis offers are rejected.** `POST /v1/offer` returns `400 Bad Request` when the offer's APR is above `maxRate` or below a quarter of the lowest APR on the auction's ramp. See [the bounds](/bridge-facilitator/onboarding/#pricing-an-offer).
- **Offers that are too small are refused.** If you keep your current configuration and sign the per-term figure on an annual auction, the implied APR is far below that floor (for example about 4.1 bps on JAAA, against a floor of 273.75 bps), so the offer is rejected instead of being filled at a near-zero rate. If your pricing is not updated by the cutover, your offers are refused.
- **Repayment on annual auctions** is `ceil(expectedReturn × paidSeconds / rateBasisSeconds)`, where `paidSeconds` counts whole days: at least 1 day, with day 2 starting at 30 hours, day 3 at 54 hours and so on (1 hour → 1 day, 30 hours → 2 days), capped at 365 days. Legacy auctions keep today's rule, `floor(expectedReturn × elapsed / rateBasisSeconds)` with `elapsed` rounded to the nearest whole day, so a loan repaid in under 12 hours earns no yield. See [How yield is repaid](/bridge-facilitator/onboarding/#how-yield-is-repaid).

## What does not change

- The `Offer` and `SubmitPushOffer` EIP-712 typed data, the `POST /v1/offer` body, and every endpoint path and field name.
- **Outstanding loans.** Loans funded before the cutover keep their `expectedReturn`, their basis and their repayment amount. Nothing is re-priced and there is nothing to do on-chain.
- The Request contract. PT is still 1:1 with principal, the amount of YT minted still equals the signed `expectedReturn` (prorated to the fill), and the Request still pulls only the principal. On an annual auction that `expectedReturn` is a full year of yield, so YT no longer redeems at about 1.0: a loan repaid the next day pays one day at your APR, and each YT is worth about 1/365 of a unit.

## Before and after

Before the cutover, `maxRate` is the yield for the auction's term and `expectedReturn` is priced per term:

```ts
// Before: maxRate and your bid are bps for the auction's term.
const termBps = 4n; // e.g. 4 bps for a 1-day JAAA term
const expectedReturn = (amount * termBps) / 10_000n;
```

After the cutover, price in APR and scale by the auction's `rateBasisSeconds`:

```ts
const YEAR_SECONDS = 31_536_000n;

/** aprTenthsBps: your APR in tenths of a basis point (1500 bps = 15000n). */
function expectedReturnFor(
  amount: bigint,
  aprTenthsBps: bigint,
  auction: { rateBasisSeconds?: number | null },
): bigint {
  const basis = auction.rateBasisSeconds;
  if (basis == null || !Number.isSafeInteger(basis) || basis <= 0) {
    // Never assume 365 days. A missing basis means a pre-cutover API: do not
    // apply this rule (see "Before the cutover").
    throw new Error("rateBasisSeconds unavailable; refusing to sign");
  }
  return (amount * aprTenthsBps * BigInt(basis)) / (100_000n * YEAR_SECONDS);
}

// Annual JAAA auction: 1,000,000 USDC at 15% APR → 150,000 USDC
expectedReturnFor(1_000_000_000_000n, 15_000n, { rateBasisSeconds: 31_536_000 }); // 150000000000n
// Legacy FalconX auction: 1,000,000 USDC at 11% APR → 9,342.465753 USDC
expectedReturnFor(1_000_000_000_000n, 11_000n, { rateBasisSeconds: 2_678_400 }); // 9342465753n
```

Use integer (`bigint`) arithmetic and round down. Floating-point maths can round an offer just above `maxRate` and get it rejected.

## Checklist

- [ ] **Update your pricing.** Express your bid as an APR, then derive `expectedReturn` with the rule above. Compare your APR against `maxRate` directly; it is already an APR.
- [ ] **Read `rateBasisSeconds` from every auction.** Do not hard-code `31536000` or the settlement delay: legacy auctions keep their old basis for their whole life. Fail closed (do not sign) when the field is missing.
- [ ] **Treat repayment as prorated.** Expected yield is about `expectedReturn × elapsed / rateBasisSeconds` (see [How yield is repaid](/bridge-facilitator/onboarding/#how-yield-is-repaid) for the exact rounding), not `expectedReturn`. Update any reporting, reconciliation or interest display that assumed `amount + expectedReturn`.
- [ ] **Review contract floors.** If you use [`SimplePush`](/bridge-facilitator/contract-examples/push/) or [`SimplePull`](/bridge-facilitator/contract-examples/pull/), size `minOutput` from principal plus the yield accrued over the expected term, not `PT + YT`. A floor that is already set too high can be lowered with `setMinOutput` (push) or `setRequestMetadata` (pull).
- [ ] **3F console users:** reload every open console tab after Friday 23 October 2026 so the page signs with the new rule.
- [ ] **Test on development** (`https://bf.dev.gcp.3f.xyz`) once it is migrated: submit one offer on an annual auction and confirm that an offer priced on the old per-term basis is rejected with `400`.

## Before the cutover

Until Friday 23 October 2026 (CET) the API does not return `rateBasisSeconds` and `maxRate` is still the per-term rate. If you ship before the cutover, branch on the field: when `rateBasisSeconds` is present, use the new rule; when it is absent, keep your current pricing. Never fill in a missing basis yourself. After the cutover every auction carries the field and you can remove the old path.