uvd-x402-sdk 2.76.0 → 2.77.0

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "uvd-x402-sdk",
3
- "version": "2.76.0",
3
+ "version": "2.77.0",
4
4
  "description": "x402 Payment SDK - Gasless crypto payments across 25 blockchains via Ultravioleta facilitator. Supports EVM (including Scroll, SKALE Base, Robinhood Chain), Solana, Fogo, Stellar, NEAR, Algorand, Sui, and XRP Ledger. Features: ERC-8004 Trustless Agents, Escrow/Refunds, multi-stablecoin (USDC, EURC, AUSD, PYUSD, USDT, USDG).",
5
5
  "author": "Ultravioleta DAO <ultravioletadao@gmail.com>",
6
6
  "license": "MIT",
package/src/dx402.ts CHANGED
@@ -1000,11 +1000,10 @@ export function sellerDigestFor(
1000
1000
  /**
1001
1001
  * Largest `POST /dx402/anchor` request the facilitator accepts, mirroring its
1002
1002
  * `MAX_REQUEST_BODY_BYTES` (default 64 KiB, an anti-OOM bound on every route).
1003
- * After base64 inflation and ~600 bytes of metadata this leaves ~47 KB of
1004
- * plaintext.
1005
1003
  */
1006
1004
  export const ANCHOR_MAX_REQUEST_BYTES = 64 * 1024;
1007
1005
 
1006
+
1008
1007
  /** base64 without spreading the array into arguments -- a large blob would
1009
1008
  * otherwise overflow the call stack and surface as a generic failure. */
1010
1009
  function toBase64(bytes: Uint8Array): string {
@@ -1075,6 +1074,12 @@ export async function anchorEvidence(
1075
1074
  // `sealed` -> it hosts and derives the pointer; `pointer` alone -> it uses
1076
1075
  // yours; neither -> error (x402-rs `dx402/service.rs`).
1077
1076
  ...(pointer !== undefined ? { pointer } : { sealed: toBase64(blob) }),
1077
+ // Declared, not measured. Since x402-rs 2.3.0 the facilitator records
1078
+ // the store that ACTUALLY took the bytes and returns that, so a response
1079
+ // may name a different backend than the request did -- `ipfs` where you
1080
+ // said `s3`, because a deployment whose primary is Pinata wrote there.
1081
+ // That is the facilitator correcting the record, not a mismatch to
1082
+ // assert on.
1078
1083
  backend: opts.backend ?? (pointer !== undefined ? backendForPointer(pointer) : 's3'),
1079
1084
  contentHash: hash,
1080
1085
  keyAlg: opts.payerKey.length === 32 ? 'ECIES-X25519' : 'ECIES-secp256k1',