@standardagents/spec 0.27.13 → 0.28.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -371,12 +371,15 @@ function defineThreadEndpoint(handler) {
371
371
 
372
372
  // src/providers.ts
373
373
  var ProviderError = class extends Error {
374
- constructor(message, code, statusCode, retryAfter) {
374
+ constructor(message, code, statusCode, retryAfter, options) {
375
375
  super(message);
376
376
  this.code = code;
377
377
  this.statusCode = statusCode;
378
378
  this.retryAfter = retryAfter;
379
379
  this.name = "ProviderError";
380
+ if (options && "cause" in options && this.cause === void 0) {
381
+ this.cause = options.cause;
382
+ }
380
383
  }
381
384
  /**
382
385
  * Whether this error is retryable