[Bug] Agent executes API mutations without consulting documentation, causing production data corruption

Resolved 💬 3 comments Opened Apr 17, 2026 by rebechilabs Closed Apr 21, 2026

Bug Description
Claude Opus 4.7 failed to consult Pipedrive API documentation before executing mutations. Resulted in ~917 deals with incorrect owner_id in production CRM of a law firm. Root cause: the agent kept guessing query param semantics (status=all_not_deleted, then status=open) instead of reading the docs. A single WebFetch of the Pipedrive API reference would have revealed the known v1 bug where pipeline_id filter is silently ignored. This pattern of "try-and-see" on production data is dangerous and should be caught by the model's default workflow.

Environment Info

  • Platform: darwin
  • Terminal: Apple_Terminal
  • Version: 2.1.81
  • Feedback ID: 2b053cfe-b0bd-4351-b991-fe840d965860

Errors

[{"error":"Error: Failed to fetch version from https://storage.googleapis.com/claude-code-dist-86c565f3-f756-42ad-8dfa-d59b1c096819/claude-code-releases/latest: ECONNREFUSED\n    at ZWR (/$bunfs/root/src/entrypoints/cli.js:2722:2074)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-04-17T18:59:21.582Z"},{"error":"Error: Failed to fetch version from https://storage.googleapis.com/claude-code-dist-86c565f3-f756-42ad-8dfa-d59b1c096819/claude-code-releases/latest: ECONNREFUSED\n    at ZWR (/$bunfs/root/src/entrypoints/cli.js:2722:2074)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-04-17T18:59:21.584Z"},{"error":"Error: 1P event logging: 3 events failed to export (code=ECONNREFUSED, ECONNREFUSED)\n    at queueFailedEvents (/$bunfs/root/src/entrypoints/cli.js:397:2687)\n    at async doExport (/$bunfs/root/src/entrypoints/cli.js:397:1559)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-04-17T18:59:31.590Z"},{"error":"Error: {\"message\":\"Failed to export 3 events (code=ECONNREFUSED, ECONNREFUSED)\",\"originalLine\":\"397\",\"originalColumn\":\"1710\",\"line\":\"397\",\"column\":\"1710\",\"sourceURL\":\"/$bunfs/root/src/entrypoints/cli.js\",\"stack\":\"Error: Failed to export 3 events (code=ECONNREFUSED, ECONNREFUSED)\\n    at doExport (/$bunfs/root/src/entrypoints/cli.js:397:1710)\\n    at processTicksAndRejections (native:7:39)\",\"name\":\"Error\"}\n    at error (/$bunfs/root/src/entrypoints/cli.js:2670:27423)\n    at <anonymous> (/$bunfs/root/src/entrypoints/cli.js:138:85385)\n    at pz4 (/$bunfs/root/src/entrypoints/cli.js:138:85929)\n    at <anonymous> (/$bunfs/root/src/entrypoints/cli.js:139:17366)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-04-17T18:59:31.592Z"},{"error":"Error: Failed to fetch version from https://storage.googleapis.com/claude-code-dist-86c565f3-f756-42ad-8dfa-d59b1c096819/claude-code-releases/latest: ECONNREFUSED\n    at ZWR (/$bunfs/root/src/entrypoints/cli.js:2722:2074)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-04-17T19:29:50.394Z"},{"error":"Error: Failed to fetch version from https://storage.googleapis.com/claude-code-dist-86c565f3-f756-42ad-8dfa-d59b1c096819/claude-code-releases/latest: ECONNREFUSED\n    at ZWR (/$bunfs/root/src/entrypoints/cli.js:2722:2074)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-04-17T19:29:50.394Z"}]

View original on GitHub ↗

This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗