Skip to content

[Bug] Regression 2026.5.27→2026.5.28: "No API provider registered for api: bedrock-converse-stream" — pi-ai removal breaks Bedrock provider registration; bearer token auth broken #88707

Description

@podulator

Summary

Upgrading the OpenClaw host to 2026.5.28 causes all Bedrock calls to fail with:

No API provider registered for api: bedrock-converse-stream

This is a hard upgrade blocker for any Bedrock user, and in particular for users trying to use the new bearer token auth feature shipped in this release.

Root Cause

Commit bb46b79 ("refactor: internalize OpenClaw agent runtime", PR #85341, landed 2026-05-27) made two simultaneous architectural changes that create a version-mismatch trap:

Before (≤ 2026.5.26):
The bedrock-converse-stream API provider was automatically registered by the host via the bundled @earendil-works/pi-ai package. The @openclaw/amazon-bedrock-provider plugin merely wrapped and configured the provider — it did not call registerApiProvider itself.

After (≥ 2026.5.28):
@earendil-works/pi-ai was removed from the host runtime entirely and replaced with OpenClaw-native modules (openclaw/plugin-sdk/llm, etc.). The @openclaw/amazon-bedrock-provider plugin now must explicitly call registerApiProvider to register bedrock-converse-stream:

// extensions/amazon-bedrock/register.sync.runtime.ts
+  registerApiProvider(
+    {
+      api: "bedrock-converse-stream",
+      stream: streamBedrock,
+      streamSimple: streamSimpleBedrock,
+    },
+    `plugin:${providerId}`,
+  );

This explicit call only exists in plugin version 2026.5.28.

The trap: When users upgrade the host via npm install -g [email protected], the @openclaw/amazon-bedrock-provider plugin is not automatically updated. If the installed plugin is still at v2026.5.26:

  • v2026.5.26 plugin code runs (no registerApiProvider call)
  • Host no longer registers bedrock-converse-stream automatically (pi-ai removed)
  • Result: bedrock-converse-stream is never registered → every Bedrock call fails

The bearer token feature (also added in bb46b79 in stream.runtime.ts) is completely inaccessible in this state.

Affected Version Range

Host Plugin Bedrock works?
2026.5.26 2026.5.26 ✅ (pi-ai auto-registers)
2026.5.28 2026.5.28 ✅ (explicit registerApiProvider)
2026.5.28 2026.5.26 REGRESSION

Steps to Reproduce

  1. Have a working Bedrock setup on OpenClaw 2026.5.26 with @openclaw/amazon-bedrock-provider at v2026.5.26
  2. Run npm install -g openclaw to upgrade host to 2026.5.28 (plugin NOT updated)
  3. Restart the gateway
  4. Attempt any Bedrock model call
  5. Observe: No API provider registered for api: bedrock-converse-stream

Workaround

Run openclaw plugins update after upgrading the host to force the plugin to v2026.5.28. This restores the explicit registerApiProvider call.

Suggested Fix

The host upgrade path should either:

  1. Auto-update bundled/official plugins when the host is updated, OR
  2. Add a startup warning when a plugin version predates a breaking plugin-api contract change (e.g., when compat.pluginApi in the installed plugin is older than the host version that removed pi-ai), OR
  3. Restore a compatibility shim in the host that still registers bedrock-converse-stream when the plugin does not, to preserve backward compatibility across the transition window

Option 3 is the lowest-risk hotfix.

Key Commit

  • bb46b79 — "refactor: internalize OpenClaw agent runtime (refactor: internalize OpenClaw agent runtime #85341)" (2026-05-27)
    • Removes @earendil-works/pi-ai from plugin dependencies
    • Adds registerApiProvider({ api: "bedrock-converse-stream", ... }) to plugin (v2026.5.28 only)
    • Adds bearerToken support in new stream.runtime.ts

Additional Context

This also affects @openclaw/amazon-bedrock-mantle which had the same @earendil-works/pi-ai dependency removed in the same commit.

Metadata

Metadata

Assignees

No one assigned

    Labels

    P1High-priority user-facing bug, regression, or broken workflow.clawsweeper:fix-shape-clearClawSweeper found a clear likely implementation shape for this issue.clawsweeper:needs-maintainer-reviewClawSweeper marked this issue as needing maintainer review before automation.clawsweeper:needs-product-decisionClawSweeper marked this issue as needing a product or behavior decision.clawsweeper:no-new-fix-prClawSweeper does not recommend queueing a new automated fix PR for this issue.clawsweeper:source-reproClawSweeper found a high-confidence source-level issue reproduction.impact:auth-providerAuth, provider routing, model choice, or SecretRef resolution may break.issue-rating: 🦞 diamond lobsterVery strong issue quality with high-confidence source-level or clear reproduction.

    Type

    No type

    Fields

    Priority

    None yet

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions