Docs

Changing an interface

A redeploy that breaks a public tool, the Stripe tool or an event a caller used in the last 30 days is refused unless forced. What counts as a break.

A service's interface is what its tools and events say of themselves: the records #[tool] and #[event] write into the image. A redeploy that breaks a caller of a public tool, the Stripe tool or an event is refused while a caller used it in the last 30 days, unless forced. See Deploying.

What breaks a caller

  • a tool or event is removed;
  • a tool is no longer public, no longer a query, no longer takes anonymous calls, or takes fewer kinds of caller;
  • the Stripe tool is removed;
  • an argument is newly required, or takes fewer values: only some strings where it took any, fewer strings of an enum, or no longer a negative integer;
  • a result is no longer declared, or a result or event field is no longer always present;
  • a result or event field may hold more values: any string where it held an enum's, more strings of an enum, or a negative integer;
  • a type changes.

Added fields break nothing.

Changing one anyway

Keep the old tool beside the new one, marked #[deprecated], until no caller uses it. A deprecated tool's answers carry Deprecation, and Sunset once an owner sets one; see Calling a tool.