iterate.com / kernel

git clone https://git.iterate.com/repos/kernel

deploy: the command offers to turn Workers Paid and R2 on, after the exact terms and a yes (#22)

Card: tasks/offer-workers-paid-and-r2-activation-in-the-deploy-cli.md

Jonas, on the board: "it should also be modified to create the workers paid plan and r2 subscription for user". His answer to the scope question: "yes of course if we can still do it using the normal cloudflare cli oauth client and scopes".

## What

For each of Workers Paid and R2 that is off, `iterate deploy` now offers to turn it on.

- It reads the rate plan in Cloudflare's public catalog (`GET /billing/rate_plans/workers_paid`, `โ€ฆ/r2_paid`) and shows the plan's name and its fixed monthly fee ($5 and $0 on 27 Nov 2026), with the link to the prices by use.
- It asks. The default answer is no.
- After a yes, Cloudflare asks for one more approval, of the scope `billing:write` alone, with the same OAuth client as before (the cf CLI's). That access is in no file, makes the subscriptions (`POST /accounts/<id>/subscriptions`) and is ended at Cloudflare at once (`briefAccess`).
- The one-hour sign-in in the config folder and a kept sign-in never ask for `billing:write`. This is narrower than the ask on the card said (it put the scope in the one-hour sign-in): a token that can spend is then on no disk. To change it back, move the scope into `alsoAsk` of the deploy's sign-in.

No offer, and the page by hand as before: a no, terms that are not read for certain, an account with no payment card, an API token, a kept sign-in, nobody at the terminal, or a refusal by Cloudflare.

## Tested, and not

Fixtures only: the catalog's two answers, the offer, no offer, a refusal (missing, active = nothing asked, declined = the page by hand), and the brief access against a faked OAuth server (ended also when the act throws, no act without the scope).

Not proven live, because no real subscription is authorized: that Cloudflare grants `billing:write` to the cf client when it is asked for alone, and that it takes the body `{ rate_plan: { id }, frequency: "monthly" }`. Cloudflare documents the endpoint and the permission, not the body for these two plans. A refusal of either falls back to the page by hand.

Session: claude 3eb581c8-1b51-4686-8d1d-b642d0822a42 on beelink
Via: /agents/claude/installer-cloudflare-card-prompt-mwynk7y7-d3de92

๐Ÿค– Generated with [Claude Code](https://claude.com/claude-code)

Iterate-Run: /@1145574

jonas, 2026-11-27 13:47 UTC ยท 291a0a8c33694215c05a28f3d30a8968ac6b4b8d ยท parent 71b85ef

5 files changed

M core/lib/src/cli/README.md
@@ -150,7 +150,31 @@
 5. **Workers Paid, R2 and Zero Trust.** It opens the page for each one that is off and waits
    until it is on. Off means Cloudflare refused the read, and the account's line shows its words.
    A read that failed is not a fact: a 429 or a 5xx is read again, and after three the command
-   stops with nothing changed and says to run it again. An owner proves their address through Cloudflare Access, which needs the
+   stops with nothing changed and says to run it again.
+   - **The command offers to turn Workers Paid and R2 on itself**, for a person at the terminal
+     who signed in at Cloudflare's page. For each of the two that is off, it reads the rate plan
+     in Cloudflare's public catalog (`GET /billing/rate_plans/workers_paid`, `โ€ฆ/r2_paid`), shows
+     the plan's name and its fixed monthly fee, and asks. The default answer is no. After a yes,
+     Cloudflare asks once more for an approval, of the scope `billing:write` alone
+     (`BILLING_SCOPE`, `briefAccess`): that access is in no file, makes the subscriptions
+     (`POST /accounts/<id>/subscriptions`) and is ended at Cloudflare at once. No sign-in that is
+     kept ever holds that scope.
+   - **What the request is bound to.** Cloudflare's API takes the plan's name and no price, and
+     has no quote to agree to. So right before each request the command reads the product again
+     (one that came on meanwhile is not subscribed to twice) and the plan's terms again: terms
+     that changed after the yes make no subscription. A price in Cloudflare's answer that is not
+     the price agreed to is said, with where to cancel. A price that changes in the moment
+     between that read and the request is not caught.
+   - **An answer that does not arrive** (a 5xx, a dropped connection) may still be a subscription:
+     the command reads the account for up to two minutes, and sends the person to the account's
+     subscriptions before any purchase by hand. A revocation that Cloudflare does not confirm
+     after three tries is said: the access then ends by itself within the hour.
+   - **The way by hand stays.** With a no, with terms that the command could not read for
+     certain, with an API token or a kept sign-in, with nobody at the terminal, or when
+     Cloudflare refuses the approval or the subscription, the command opens the product's page
+     and waits, as before.
+
+   An owner proves their address through Cloudflare Access, which needs the
    account's Zero Trust organization. When the account has none, the command first sets one up
    through Cloudflare's API, as the script would, with a team name that Cloudflare picks. When
    Cloudflare refuses that because Zero Trust was never turned on, it opens the account's Zero
M core/lib/src/cli/cloudflare-access.test.ts
@@ -1,8 +1,10 @@
 import { existsSync, mkdtempSync, rmSync, writeFileSync } from "node:fs";
 import { tmpdir } from "node:os";
 import { join } from "node:path";
-import { expect, test } from "vitest";
+import { expect, test, vi } from "vitest";
 import {
+  BILLING_SCOPE,
+  briefAccess,
   CARD_SCOPE,
   DEPLOY_SCOPES,
   keptTokenServes,
@@ -229,3 +231,112 @@
   expect(keptTokenServes(lacking, DEPLOY_SCOPES, at)).toBe(false);
   expect(keptTokenServes({ ...before, expiresAt: at + 19 * 60_000 }, DEPLOY_SCOPES, at)).toBe(false);
 });
+
+test("the billing access is asked for alone, held in no file, used for the one act and ended at Cloudflare, also when the act throws", async () => {
+  // the scope that can spend is in no list that a kept or cached sign-in asks for
+  expect(DEPLOY_SCOPES).not.toContain(BILLING_SCOPE);
+  expect(CARD_SCOPE).not.toBe(BILLING_SCOPE);
+
+  const calls: { path: string; form: Record<string, string> }[] = [];
+  let revokeFails = false;
+  let extra: Record<string, string> = {};
+  const cloudflareSays = (granted: string) =>
+    vi.stubGlobal("fetch", async (url: string | URL, init?: RequestInit) => {
+      const path = new URL(String(url)).pathname;
+      const form = Object.fromEntries(new URLSearchParams(String(init?.body)));
+      calls.push({ path, form });
+      const answer = path.endsWith("/device/auth")
+        ? {
+            device_code: "device-1",
+            user_code: "ABCD-EFGH",
+            verification_uri: "https://dash.cloudflare.com/oauth2/device",
+            expires_in: 300,
+            interval: 1,
+          }
+        : path.endsWith("/token")
+          ? { access_token: "billing-token", expires_in: 3600, scope: granted, ...extra }
+          : {};
+      if (path.endsWith("/revoke") && revokeFails) return new Response("{}", { status: 400 });
+      return new Response(JSON.stringify(answer), { headers: { "content-type": "application/json" } });
+    });
+  const revoked = () => calls.filter((call) => call.path.endsWith("/revoke")).map((call) => call.form.token);
+  try {
+    cloudflareSays(BILLING_SCOPE);
+    let shown = "";
+    const made = await briefAccess(
+      [BILLING_SCOPE],
+      ({ code }) => {
+        shown = code;
+      },
+      async (token) => `acted with ${token}`,
+    );
+    expect(shown).toBe("ABCD-EFGH");
+    expect(made).toEqual({ lacks: [], done: "acted with billing-token" });
+    expect(calls[0]!.form.scope).toBe(BILLING_SCOPE);
+    expect(revoked()).toEqual(["billing-token"]);
+
+    // an act that throws: the access is ended all the same
+    calls.length = 0;
+    await expect(
+      briefAccess([BILLING_SCOPE], () => {}, async () => {
+        throw new Error("Cloudflare is down");
+      }),
+    ).rejects.toThrow("Cloudflare is down");
+    expect(revoked()).toEqual(["billing-token"]);
+
+    // an approval without the scope: no act, and the access is ended
+    calls.length = 0;
+    cloudflareSays("user-details.read");
+    let acted = false;
+    expect(
+      await briefAccess([BILLING_SCOPE], () => {}, async () => {
+        acted = true;
+      }),
+    ).toEqual({ lacks: [BILLING_SCOPE] });
+    expect(acted).toBe(false);
+    expect(revoked()).toEqual(["billing-token"]);
+
+    // a revocation that Cloudflare refuses: asked for three times, and said, never silent
+    calls.length = 0;
+    revokeFails = true;
+    cloudflareSays(BILLING_SCOPE);
+    const waits: number[] = [];
+    const notEnded = await briefAccess(
+      [BILLING_SCOPE],
+      () => {},
+      async () => "acted",
+      async (ms) => void waits.push(ms),
+    );
+    expect(notEnded).toEqual({
+      lacks: [],
+      done: "acted",
+      notEnded: "the access token: HTTP 400",
+    });
+    expect(revoked()).toEqual(["billing-token", "billing-token", "billing-token"]);
+    expect(waits).toEqual([1000, 2000]);
+    await expect(
+      briefAccess(
+        [BILLING_SCOPE],
+        () => {},
+        async () => {
+          throw new Error("The act failed.");
+        },
+        async () => {},
+      ),
+    ).rejects.toThrow(
+      "The act failed. The access for it was not ended at Cloudflare (the access token: HTTP 400)",
+    );
+
+    // a refresh token that came unasked: its end is tried three times and its failure is named
+    calls.length = 0;
+    extra = { refresh_token: "refresh-unasked" };
+    const both = await briefAccess([BILLING_SCOPE], () => {}, async () => "acted", async () => {});
+    expect(both.notEnded).toBe(
+      "the access token: HTTP 400; the refresh token, which does not end by itself: HTTP 400",
+    );
+    expect(revoked().filter((token) => token === "refresh-unasked")).toHaveLength(3);
+  } finally {
+    vi.unstubAllGlobals();
+  }
+  // each sign-in here waits one second for the device flow's first poll
+}, 20_000);
M core/lib/src/cli/cloudflare-access.ts
@@ -116,6 +116,13 @@
  *  (`keptSignInOf`) never does. */
 export const CARD_SCOPE = "aig.read";
 
+/** THE SCOPE THAT TURNS A PRODUCT OF THE ACCOUNT ON (Workers Paid, R2): Cloudflare's billing
+ *  write, which makes a subscription (`POST /accounts/<id>/subscriptions`). It can spend the
+ *  account's money, so NO SIGN-IN THAT IS KEPT EVER HOLDS IT: neither the one-hour sign-in in the
+ *  config folder nor a kept sign-in asks for it. Only `briefAccess` does, after the person said
+ *  yes to a product's price, and it ends that access when the act is done. */
+export const BILLING_SCOPE = "billing:write";
+
 /** WHAT `iterate recover` ASKS FOR: the reads that find the mind (its zone with the zone's
  *  account, the zone's routes, the boundary Worker's settings), and D1's write for the two
  *  statements. */
@@ -264,7 +271,9 @@
     options,
   );
   const said = parsed(OAuthAnswer, await answer.text());
-  if (said) return said;
+  // an answer that is not ok is an error also when its body names none: a refused revocation
+  // must never read as done
+  if (said && (answer.ok || said.error)) return said;
   if (answer.ok) return {};
   if (answer.status === 403) {
     const mitigated = answer.headers.get("cf-mitigated");
@@ -412,6 +421,53 @@
   );
   chmodSync(KEPT, 0o600);
   return { token: answer.access_token, from: "sign-in", lacks };
+}
+
+/** A SIGN-IN FOR ONE ACT, KEPT NOWHERE: the device flow with `scopes` alone, then `act` with its
+ *  token, then the token's end at Cloudflare, whatever `act` did. The token is in no file and in
+ *  no other call of the run. A sign-in that did not grant every scope does not act: `lacks` names
+ *  what is missing. THE END IS ASKED FOR UP TO THREE TIMES, AND A FAILURE IS SAID: `notEnded` is
+ *  Cloudflare's error for each token that may still work (the access token then ends by itself
+ *  within the hour; a refresh token does not),
+ *  and an `act` that throws carries the same words. It throws what the sign-in throws (refused,
+ *  or nobody approved in time): nothing was acted on then. */
+export async function briefAccess<T>(
+  scopes: readonly string[],
+  show: Parameters<typeof deviceSignIn>[1],
+  act: (token: string) => Promise<T>,
+  pause: (ms: number) => Promise<unknown> = sleep,
+): Promise<{ lacks: string[]; done?: T; notEnded?: string }> {
+  const answer = await deviceSignIn(scopes, show);
+  // each token's end is asked for up to three times; none was asked for a refresh token, and one
+  // that comes all the same lives longer than the hour, so its failure is named as such
+  const ended = async (token: string | undefined) => {
+    for (let attempt = 1; ; attempt++) {
+      const problem = await revoke(token);
+      if (!problem || attempt === 3) return problem;
+      await pause(attempt * 1000);
+    }
+  };
+  const end = async () => {
+    const refresh = await ended(answer.refresh_token);
+    const access = await ended(answer.access_token);
+    const problems = [
+      ...(access ? [`the access token: ${access}`] : []),
+      ...(refresh ? [`the refresh token, which does not end by itself: ${refresh}`] : []),
+    ];
+    return problems.length > 0 ? problems.join("; ") : undefined;
+  };
+  const lacks = scopesLacking(scopes, answer.scope);
+  let done: T | undefined;
+  try {
+    if (lacks.length === 0) done = await act(answer.access_token);
+  } catch (error) {
+    const notEnded = await end();
+    if (notEnded && error instanceof Error)
+      error.message += ` The access for it was not ended at Cloudflare (${notEnded}).`;
+    throw error;
+  }
+  const notEnded = await end();
+  return { lacks, ...(lacks.length === 0 ? { done } : {}), ...(notEnded ? { notEnded } : {}) };
 }
 
 // ---------------------------------------------------------------------------------------------
M core/lib/src/cli/deploy.test.ts
@@ -6,6 +6,9 @@
 import { MindConfig as ScriptConfig } from "../../../alchemy/src/config.ts";
 import { DEPLOY_SCOPES, RECOVER_SCOPES, scopesLacking, STACK_SCOPES } from "./cloudflare-access.ts";
 import {
+  activationOffer,
+  activationOutcomeOf,
+  activationReport,
   alternativesOf,
   assertSupportedNodeVersion,
   boundaryCheck,
@@ -19,6 +22,10 @@
   deployStack,
   deployConfigOf,
   patternsRefusalOf,
+  planTermsOf,
+  sameTerms,
+  PRODUCTS,
+  subscriptionBodyOf,
   deployedMind,
   domainPickerOptions,
   earlierDeployOf,
@@ -2189,3 +2196,252 @@
     },
   };
 }
+
+// What Cloudflare's public catalog answered on 27 Nov 2026 for the two rate plans
+// (GET /billing/rate_plans/<plan>, read with no credentials), cut to a few of their parts.
+const catalog = (result: unknown) => ({ status: 200, result, total: 0, error: "" });
+const workersPaidPlan = {
+  "id": "WORKERS_PAID",
+  "public_name": "Cloudflare Workers Paid",
+  "currency": "USD",
+  "components": [
+    {
+      "name": "account",
+      "publicName": "Base Monthly Fee",
+      "kind": "enum",
+      "type": "flatPricingComponent",
+      "aggregate": "",
+      "chargeType": "subscription",
+      "chargeModel": "flat",
+      "defaultQuantity": 1,
+      "tiers": [
+        {
+          "lowerThreshold": 1,
+          "upperThreshold": 1,
+          "pricingType": "fixed",
+          "price": 5,
+          "bucketSize": 0
+        }
+      ],
+      "discounts": {}
+    },
+    {
+      "name": "queues_enabled",
+      "publicName": "Queues",
+      "kind": "enum",
+      "type": "tieredPricingComponent",
+      "aggregate": "",
+      "features": [
+        "queues.enabled"
+      ],
+      "chargeType": "subscription",
+      "chargeModel": "tiered",
+      "defaultQuantity": 1,
+      "tiers": [
+        {
+          "lowerThreshold": 0,
+          "upperThreshold": 1,
+          "pricingType": "fixed",
+          "price": 0,
+          "bucketSize": 0
+        }
+      ],
+      "discounts": {}
+    }
+  ]
+};
+const r2Plan = {
+  "id": "R2_PAID",
+  "public_name": "R2 Storage",
+  "currency": "USD",
+  "components": [
+    {
+      "name": "base",
+      "publicName": "Base",
+      "kind": "enum",
+      "type": "flatPricingComponent",
+      "aggregate": "",
+      "chargeType": "subscription",
+      "chargeModel": "flat",
+      "defaultQuantity": 1,
+      "tiers": [
+        {
+          "lowerThreshold": 0,
+          "upperThreshold": 0,
+          "pricingType": "fixed",
+          "price": 0,
+          "bucketSize": 0
+        }
+      ],
+      "discounts": {}
+    },
+    {
+      "name": "r2_storage",
+      "publicName": "R2 Storage",
+      "kind": "usage",
+      "type": "tieredPricingComponent",
+      "metric": "r2_storage",
+      "aggregate": "sum",
+      "chargeType": "usage",
+      "chargeModel": "tiered",
+      "defaultQuantity": 0,
+      "tiers": [
+        {
+          "lowerThreshold": 0,
+          "upperThreshold": 0,
+          "pricingType": "unit",
+          "price": 0.015,
+          "bucketSize": 0
+        }
+      ],
+      "discounts": {},
+      "cfUOM": "GIGABYTE",
+      "cfQuantityLabel": "{{comma .}} GB-Month",
+      "cfStartOfFirstUnit": 300000000001,
+      "cfUsageDivisor": 30000000000,
+      "cfUsageID": "r2_storage"
+    }
+  ]
+};
+
+test("a product that is off is offered with its exact terms from Cloudflare's catalog, and only a yes makes the subscription", () => {
+  const terms = planTermsOf("workers_paid", catalog(workersPaidPlan));
+  expect(terms).toEqual({ plan: "workers_paid", name: "Cloudflare Workers Paid", monthly: 5 });
+  const offer = activationOffer({
+    product: "Workers Paid",
+    terms,
+    account: "Ada's Account",
+    card: "there",
+    person: true,
+  });
+  expect(offer!.question).toBe("Turn on Workers Paid now, for $5 a month?");
+  expect(offer!.words).toContain("Cloudflare Workers Paid, $5 a month");
+  expect(offer!.words).toContain("charges the payment card of the account Ada's Account");
+  expect(offer!.words).toContain("each month until you cancel it");
+  expect(offer!.words).toContain(PRODUCTS["Workers Paid"].pricing);
+  expect(offer!.words).toContain("After a no, you turn it on yourself");
+
+  // R2 has no monthly fee: the words promise no charge now, and still name the prices by use
+  const free = activationOffer({
+    product: "R2",
+    terms: planTermsOf("r2_paid", catalog(r2Plan)),
+    account: "Ada's Account",
+    card: "unknown",
+    person: true,
+  });
+  expect(free!.question).toBe("Turn on R2 now, for $0 a month?");
+  expect(free!.words).toContain("R2 Storage, $0 a month.");
+  expect(free!.words).not.toContain("charges the payment card");
+  expect(free!.words).toContain(PRODUCTS.R2.pricing);
+
+  // what the yes sends, and what Cloudflare's answer means
+  expect(subscriptionBodyOf(PRODUCTS.R2.plan)).toEqual({
+    rate_plan: { id: "r2_paid" },
+    frequency: "monthly",
+  });
+  expect(activationOutcomeOf({ status: 200, result: {}, total: 0, error: "" })).toEqual({ on: true });
+});
+
+test("no offer without certain terms, without a card, or with nobody at Cloudflare's page: the way by hand stays", () => {
+  const terms = planTermsOf("workers_paid", catalog(workersPaidPlan));
+  const base = { product: "Workers Paid" as const, terms, account: "A", card: "there" as const };
+  expect(activationOffer({ ...base, person: true })).toBeDefined();
+  // an API token, a kept sign-in, CI or a coding agent: nobody can approve the billing access
+  expect(activationOffer({ ...base, person: false })).toBeUndefined();
+  expect(activationOffer({ ...base, card: "none", person: true })).toBeUndefined();
+  expect(activationOffer({ ...base, terms: undefined, person: true })).toBeUndefined();
+
+  // terms that are not read for certain are no terms
+  expect(planTermsOf("workers_paid", undefined)).toBeUndefined();
+  expect(planTermsOf("workers_paid", { ...catalog(workersPaidPlan), status: 404 })).toBeUndefined();
+  expect(planTermsOf("r2_paid", catalog(workersPaidPlan))).toBeUndefined();
+  expect(
+    planTermsOf("workers_paid", catalog({ ...workersPaidPlan, currency: "EUR" })),
+  ).toBeUndefined();
+  expect(planTermsOf("workers_paid", catalog({ id: "WORKERS_PAID" }))).toBeUndefined();
+  const perUnit = structuredClone(workersPaidPlan);
+  perUnit.components[0]!.tiers[0]!.pricingType = "unit";
+  expect(planTermsOf("workers_paid", catalog(perUnit))).toBeUndefined();
+  const otherCharge = structuredClone(workersPaidPlan);
+  otherCharge.components[0]!.chargeType = "oneTime";
+  expect(planTermsOf("workers_paid", catalog(otherCharge))).toBeUndefined();
+});
+
+test("a subscription that Cloudflare refuses is not on, and its words are kept for the person", () => {
+  expect(
+    activationOutcomeOf({
+      status: 403,
+      result: undefined,
+      total: 0,
+      error: "Authentication error (code 10000)",
+    }),
+  ).toEqual({ on: false, why: "403: Authentication error (code 10000)" });
+  expect(
+    activationOutcomeOf({ status: 400, result: undefined, total: 0, error: "no payment method" }),
+  ).toEqual({ on: false, why: "400: no payment method" });
+});
+
+test("the request follows the terms that the person agreed to: terms that changed after the yes make no subscription", () => {
+  const agreed = planTermsOf("workers_paid", catalog(workersPaidPlan))!;
+  expect(sameTerms(agreed, planTermsOf("workers_paid", catalog(workersPaidPlan)))).toBe(true);
+  const dearer = structuredClone(workersPaidPlan);
+  dearer.components[0]!.tiers[0]!.price = 6;
+  expect(sameTerms(agreed, planTermsOf("workers_paid", catalog(dearer)))).toBe(false);
+  expect(sameTerms(agreed, undefined)).toBe(false);
+});
+
+test("after the subscriptions: one product's failure loses no other's result, and a lost answer is never called nothing bought", () => {
+  const paid = planTermsOf("workers_paid", catalog(workersPaidPlan))!;
+  const r2 = planTermsOf("r2_paid", catalog(r2Plan))!;
+  // an answer with a 5xx, like a request that threw, is lost: Cloudflare may have made it
+  expect(activationOutcomeOf({ status: 502, result: undefined, total: 0, error: "bad gateway" })).toEqual({
+    lost: "502: bad gateway",
+  });
+  expect(activationOutcomeOf({ status: 200, result: { price: 5 }, total: 0, error: "" })).toEqual({
+    on: true,
+    charged: 5,
+  });
+
+  // Workers Paid was made, the answer for R2 was lost and R2 is still off
+  const report = activationReport({
+    account: "acc1",
+    outcomes: [
+      { product: "Workers Paid", agreed: paid, outcome: { on: true, charged: 5 }, onNow: false },
+      { product: "R2", agreed: r2, outcome: { lost: "fetch failed" }, onNow: false },
+    ],
+  });
+  expect(report.byHand).toEqual(["R2"]);
+  expect(report.lines[0]).toEqual({ kind: "success", text: "Workers Paid is on." });
+  expect(report.lines[1]!.kind).toBe("warn");
+  expect(report.lines[1]!.text).toContain("may have made the subscription");
+  expect(report.lines[1]!.text).toContain("https://dash.cloudflare.com/acc1/billing/subscriptions");
+  expect(report.lines[1]!.text).not.toContain("Nothing was");
+
+  // a lost answer whose product the account then shows on: it is on, and nothing is bought by hand
+  expect(
+    activationReport({
+      account: "acc1",
+      outcomes: [{ product: "R2", agreed: r2, outcome: { lost: "fetch failed" }, onNow: true }],
+    }),
+  ).toEqual({ lines: [{ kind: "success", text: "R2 is on." }], byHand: [] });
+
+  // a refusal: nothing was bought for it, and the page by hand follows
+  const refused = activationReport({
+    account: "acc1",
+    outcomes: [
+      { product: "Workers Paid", agreed: paid, outcome: { on: false, why: "403: no" }, onNow: false },
+    ],
+  });
+  expect(refused.byHand).toEqual(["Workers Paid"]);
+  expect(refused.lines[0]!.text).toContain("Nothing was bought for it");
+
+  // a price in Cloudflare's answer that is not the price agreed to is said, with where to cancel
+  const other = activationReport({
+    account: "acc1",
+    outcomes: [
+      { product: "Workers Paid", agreed: paid, outcome: { on: true, charged: 6 }, onNow: false },
+    ],
+  });
+  expect(other.byHand).toEqual([]);
+  expect(other.lines[1]!.text).toContain("names $6 a month for Workers Paid, not the $5");
+});
M core/lib/src/cli/deploy.ts

Not shown: the change is larger than this page shows. A clone has it.