@mysten-incubation/suipay 0.2.0-dev.15 → 0.2.0-dev.16

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.d.ts CHANGED
@@ -558,7 +558,7 @@ declare const ERRORS: {
558
558
  };
559
559
  };
560
560
  readonly 'limit.rate_limited': {
561
- readonly surfaces: readonly ["gateway", "console_server"];
561
+ readonly surfaces: readonly ["gateway", "console_server", "sdk"];
562
562
  readonly status: 429;
563
563
  readonly title: "Rate limit exceeded";
564
564
  readonly paymentState: "not_charged";
package/dist/index.js CHANGED
@@ -1145,7 +1145,7 @@ var LIMIT_CODES = {
1145
1145
  }
1146
1146
  },
1147
1147
  "limit.rate_limited": {
1148
- surfaces: ["gateway", "console_server"],
1148
+ surfaces: ["gateway", "console_server", "sdk"],
1149
1149
  status: 429,
1150
1150
  title: "Rate limit exceeded",
1151
1151
  paymentState: "not_charged",
@@ -10787,7 +10787,9 @@ async function resolvePayerSession(options) {
10787
10787
  ok: false,
10788
10788
  // The gateway's stable code, never a raw body — the read client already
10789
10789
  // sanitized it, and an operator needs to tell 429 from 401.
10790
- error: manifestError(MANIFEST_ERROR_CODES.MALFORMED_MANIFEST, `bootstrap was refused (${bootstrap.error}${bootstrap.code ? `: ${bootstrap.code}` : ""})`)
10790
+ // A 429 is the gateway's rate limit, not a manifest the agent can fix, so
10791
+ // it keeps the retryable code instead of the manifest default.
10792
+ error: manifestError(MANIFEST_ERROR_CODES.MALFORMED_MANIFEST, `bootstrap was refused (${bootstrap.error}${bootstrap.code ? `: ${bootstrap.code}` : ""})`, bootstrap.status === 429 ? "limit.rate_limited" : void 0)
10791
10793
  };
10792
10794
  }
10793
10795
  const whole = manifestToSession({
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mysten-incubation/suipay",
3
- "version": "0.2.0-dev.15",
3
+ "version": "0.2.0-dev.16",
4
4
  "private": false,
5
5
  "type": "module",
6
6
  "description": "SuiPay embeddable client — quote and pay a 402 from a spend-account grant.",