@mysten-incubation/suipay-buyer 0.3.0-dev.15 → 0.3.0-dev.17

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.
@@ -1149,7 +1149,7 @@ var LIMIT_CODES = {
1149
1149
  }
1150
1150
  },
1151
1151
  "limit.rate_limited": {
1152
- surfaces: ["gateway", "console_server"],
1152
+ surfaces: ["gateway", "console_server", "sdk"],
1153
1153
  status: 429,
1154
1154
  title: "Rate limit exceeded",
1155
1155
  paymentState: "not_charged",
@@ -2921,6 +2921,8 @@ var CONTEXT_ALLOWLIST = /* @__PURE__ */ new Set([
2921
2921
  "seedId",
2922
2922
  "grantId",
2923
2923
  "grantObjectId",
2924
+ "policyId",
2925
+ "onChainPolicyId",
2924
2926
  "sameGrantObjectId",
2925
2927
  "verifiedGrant",
2926
2928
  "poolObjectId",
package/dist/index.d.ts CHANGED
@@ -1,5 +1,5 @@
1
- import { E as ErrorCode, P as PaymentState, N as NextAction, R as Receipt, C as CodeFor, D as DelegationScope, O as Offer } from './native-transfer-_cAFkvY9.js';
2
- export { B as BuildNativeTransferInput, M as McpPaymentSigner, a as NativeTransferAccept, b as NativeTransferBuild, c as NativeTransferError, d as NativeTransferGas, e as NativeTransferSignerInput, S as SuiPayError, f as SuiPayErrorFields, g as buildMcpPaymentPayload, h as buildNativeTransferBytes, i as createNativeTransferSigner, j as inspectNativeTransfer, t as toErrorFields } from './native-transfer-_cAFkvY9.js';
1
+ import { E as ErrorCode, P as PaymentState, N as NextAction, R as Receipt, C as CodeFor, D as DelegationScope, O as Offer } from './native-transfer-DspFvMQc.js';
2
+ export { B as BuildNativeTransferInput, M as McpPaymentSigner, a as NativeTransferAccept, b as NativeTransferBuild, c as NativeTransferError, d as NativeTransferGas, e as NativeTransferSignerInput, S as SuiPayError, f as SuiPayErrorFields, g as buildMcpPaymentPayload, h as buildNativeTransferBytes, i as createNativeTransferSigner, j as inspectNativeTransfer, t as toErrorFields } from './native-transfer-DspFvMQc.js';
3
3
  import { SuiGrpcClient } from '@mysten/sui/grpc';
4
4
  import { Ed25519Keypair } from '@mysten/sui/keypairs/ed25519';
5
5
  import { KeyObject } from 'node:crypto';
package/dist/index.js CHANGED
@@ -13,7 +13,7 @@ import {
13
13
  parseErrorPayload,
14
14
  stricterPaymentState,
15
15
  toErrorFields
16
- } from "./chunk-MTAXAJHB.js";
16
+ } from "./chunk-BCI3TKYX.js";
17
17
 
18
18
  // src/mcp.ts
19
19
  async function buildMcpPaymentPayload(paymentRequired, signer) {
@@ -9980,7 +9980,9 @@ async function resolvePayerSession(options) {
9980
9980
  ok: false,
9981
9981
  // The gateway's stable code, never a raw body — the read client already
9982
9982
  // sanitized it, and an operator needs to tell 429 from 401.
9983
- error: manifestError(MANIFEST_ERROR_CODES.MALFORMED_MANIFEST, `bootstrap was refused (${bootstrap.error}${bootstrap.code ? `: ${bootstrap.code}` : ""})`)
9983
+ // A 429 is the gateway's rate limit, not a manifest the agent can fix, so
9984
+ // it keeps the retryable code instead of the manifest default.
9985
+ error: manifestError(MANIFEST_ERROR_CODES.MALFORMED_MANIFEST, `bootstrap was refused (${bootstrap.error}${bootstrap.code ? `: ${bootstrap.code}` : ""})`, bootstrap.status === 429 ? "limit.rate_limited" : void 0)
9984
9986
  };
9985
9987
  }
9986
9988
  const whole = manifestToSession({
@@ -560,7 +560,7 @@ declare const ERRORS: {
560
560
  };
561
561
  };
562
562
  readonly 'limit.rate_limited': {
563
- readonly surfaces: readonly ["gateway", "console_server"];
563
+ readonly surfaces: readonly ["gateway", "console_server", "sdk"];
564
564
  readonly status: 429;
565
565
  readonly title: "Rate limit exceeded";
566
566
  readonly paymentState: "not_charged";
@@ -1,2 +1,2 @@
1
1
  import '@mysten/sui/client';
2
- export { B as BuildNativeTransferInput, a as NativeTransferAccept, b as NativeTransferBuild, c as NativeTransferError, k as NativeTransferErrorCode, d as NativeTransferGas, e as NativeTransferSignerInput, h as buildNativeTransferBytes, i as createNativeTransferSigner, j as inspectNativeTransfer } from './native-transfer-_cAFkvY9.js';
2
+ export { B as BuildNativeTransferInput, a as NativeTransferAccept, b as NativeTransferBuild, c as NativeTransferError, k as NativeTransferErrorCode, d as NativeTransferGas, e as NativeTransferSignerInput, h as buildNativeTransferBytes, i as createNativeTransferSigner, j as inspectNativeTransfer } from './native-transfer-DspFvMQc.js';
@@ -3,7 +3,7 @@ import {
3
3
  buildNativeTransferBytes,
4
4
  createNativeTransferSigner,
5
5
  inspectNativeTransfer
6
- } from "./chunk-MTAXAJHB.js";
6
+ } from "./chunk-BCI3TKYX.js";
7
7
  export {
8
8
  NativeTransferError,
9
9
  buildNativeTransferBytes,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mysten-incubation/suipay-buyer",
3
- "version": "0.3.0-dev.15",
3
+ "version": "0.3.0-dev.17",
4
4
  "type": "module",
5
5
  "description": "SuiPay buyer SDK — delegated spend-account pay plus a typed /v1 control-plane client.",
6
6
  "license": "MIT",