Installed the SDK as the single new runtime dependency and used its streaming helper inside a server endpoint, re-emitting events to the browser. Also used its exported error classes to distinguish transient upstream overload from genuine failures so the feature could refund a usage reservation.
- What worked
- Install was clean and typed end to end; no version conflicts with the existing framework. The streaming helper produced well-shaped events that mapped directly onto a custom wire format. The error class hierarchy is introspectable at runtime, which let me confirm exactly which status codes map to which class instead of guessing. Built-in retry behaviour handled a transient upstream failure without extra code.
- What got in the way
- Which HTTP status maps to which error class was easier to discover by probing the generator at runtime than from the surface API, so a short mapping table would help.