@dvmkit/sdk 0.13.0 → 0.14.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.
@@ -126,6 +126,7 @@ import {
126
126
  verifyAttestation,
127
127
  verifyChallenge,
128
128
  verifyDrainReceiptChain,
129
+ verifyDrawFundingReceiptChain,
129
130
  verifyFundingReceiptChain,
130
131
  verifyJobReceipt,
131
132
  walletExists,
@@ -133,7 +134,7 @@ import {
133
134
  withWalletLock,
134
135
  writeAgentMnemonic,
135
136
  writeIdentity
136
- } from "../chunk-V3WFX65W.js";
137
+ } from "../chunk-5JSPTVIK.js";
137
138
  import {
138
139
  X402_BATCH_SETTLEMENT_SCHEME,
139
140
  X402_DEFAULT_FACILITATOR,
@@ -195,15 +196,18 @@ import {
195
196
  import {
196
197
  computeResultHash,
197
198
  isDrainReceipt,
199
+ isDrawFundingReceipt,
198
200
  isFundingReceipt,
199
201
  isSignedJobReceipt,
200
202
  signDrainReceipt,
203
+ signDrawFundingReceipt,
201
204
  signFundingReceipt,
202
205
  signReceipt,
203
206
  verifyDrainReceipt,
207
+ verifyDrawFundingReceipt,
204
208
  verifyFundingReceipt,
205
209
  verifyReceipt
206
- } from "../chunk-5H7P3ORL.js";
210
+ } from "../chunk-5UC7TOQC.js";
207
211
  import {
208
212
  applyRetryToPool,
209
213
  withInitRetry
@@ -1471,6 +1475,7 @@ function recordFundResponse(args) {
1471
1475
  record.balanceMicro = args.credit.balance_micro;
1472
1476
  record.remainingMicro = args.credit.remaining_micro;
1473
1477
  record.ledgerSeq = Math.max(record.ledgerSeq, args.credit.ledger_seq);
1478
+ pruneDrawFundings(record, record.ledgerSeq);
1474
1479
  record.expiryMs = args.credit.expiry_ms;
1475
1480
  record.targetMicro = args.targetMicro;
1476
1481
  record.status = args.credit.status === "unbacked" ? "unbacked" : args.credit.expired ? "expired" : "active";
@@ -1553,15 +1558,42 @@ function applyReceiptCredit(args) {
1553
1558
  where: (c) => c.callerPubkey === args.callerPubkey && c.creditId === args.credit.credit_id
1554
1559
  });
1555
1560
  if (!record) return {};
1561
+ let admitted = false;
1562
+ for (const evidence of args.drawFundings ?? []) {
1563
+ const verdict = admitDrawFunding(record, {
1564
+ callerPubkey: args.callerPubkey,
1565
+ identity: args.identity,
1566
+ receipt: evidence.receipt,
1567
+ builder: evidence.builder,
1568
+ now
1569
+ });
1570
+ admitted ||= verdict.recorded;
1571
+ }
1572
+ if (args.credit.ledger_seq < record.ledgerSeq) {
1573
+ if (admitted) {
1574
+ attachDvmLocation(record, key, args.identity);
1575
+ record.updatedAt = now;
1576
+ saveStore(store);
1577
+ }
1578
+ return { credit: record };
1579
+ }
1556
1580
  attachDvmLocation(record, key, args.identity);
1557
1581
  let mismatch;
1582
+ let fundedMicro;
1558
1583
  const sequential = args.credit.ledger_seq === record.ledgerSeq + 1;
1559
1584
  if (sequential && args.outcome === "completed" && record.status === "active" && !record.provisional && !record.unsequencedBalance) {
1560
- const expected = record.remainingMicro - args.credit.amount;
1585
+ const eligible = (record.drawFundings ?? []).filter(
1586
+ (fact) => fact.drawId === args.credit.draw_id && fact.ledgerSeq === args.credit.ledger_seq
1587
+ );
1588
+ if (eligible.length > 0) {
1589
+ fundedMicro = eligible.reduce((sum, fact) => sum + fact.fundedMicro, 0);
1590
+ }
1591
+ const expected = record.remainingMicro + (fundedMicro ?? 0) - args.credit.amount;
1561
1592
  if (args.credit.balance_after !== expected) {
1562
1593
  mismatch = {
1563
1594
  atMs: now,
1564
1595
  expectedMicro: expected,
1596
+ ...fundedMicro !== void 0 ? { fundedMicro } : {},
1565
1597
  reportedMicro: args.credit.balance_after,
1566
1598
  drawId: args.credit.draw_id,
1567
1599
  ledgerSeq: args.credit.ledger_seq,
@@ -1571,11 +1603,10 @@ function applyReceiptCredit(args) {
1571
1603
  record.discrepancy = mismatch;
1572
1604
  }
1573
1605
  }
1574
- if (args.credit.ledger_seq >= record.ledgerSeq) {
1575
- record.remainingMicro = args.credit.balance_after;
1576
- record.ledgerSeq = args.credit.ledger_seq;
1577
- delete record.unsequencedBalance;
1578
- }
1606
+ record.remainingMicro = args.credit.balance_after;
1607
+ record.ledgerSeq = args.credit.ledger_seq;
1608
+ pruneDrawFundings(record, record.ledgerSeq, args.credit.draw_id);
1609
+ delete record.unsequencedBalance;
1579
1610
  delete record.provisional;
1580
1611
  if (args.outcome === "completed") record.lastPriceMicro = args.credit.amount;
1581
1612
  if (!mismatch && record.discrepancy && args.credit.ledger_seq > record.discrepancy.ledgerSeq) {
@@ -1584,9 +1615,103 @@ function applyReceiptCredit(args) {
1584
1615
  record.lastReceiptJobId = args.jobId;
1585
1616
  record.updatedAt = now;
1586
1617
  saveStore(store);
1587
- return { credit: record, ...mismatch ? { mismatch } : {} };
1618
+ return {
1619
+ credit: record,
1620
+ ...mismatch ? { mismatch } : {},
1621
+ ...fundedMicro !== void 0 ? { fundedMicro } : {}
1622
+ };
1623
+ });
1624
+ }
1625
+ function recordDrawFunding(args) {
1626
+ const now = args.now ?? Date.now();
1627
+ return withCreditLock(() => {
1628
+ const store = loadStore();
1629
+ const key = normalizeCreditEndpoint(args.endpoint);
1630
+ if (!isDrawFundingReceipt(args.receipt)) {
1631
+ return { recorded: false, reason: "invalid", verifyReason: "signature_invalid" };
1632
+ }
1633
+ const named = args.receipt;
1634
+ const record = findDvmLocated(store.credits, {
1635
+ endpoint: key,
1636
+ ...args.identity ? { identity: args.identity } : {},
1637
+ where: (c) => c.callerPubkey === args.callerPubkey && c.creditId === named.credit_id
1638
+ });
1639
+ if (!record) return { recorded: false, reason: "unknown_credit" };
1640
+ const verdict = admitDrawFunding(record, {
1641
+ callerPubkey: args.callerPubkey,
1642
+ identity: args.identity,
1643
+ receipt: named,
1644
+ builder: args.builder,
1645
+ now
1646
+ });
1647
+ if (verdict.recorded) {
1648
+ attachDvmLocation(record, key, args.identity);
1649
+ record.updatedAt = now;
1650
+ saveStore(store);
1651
+ }
1652
+ return { credit: record, ...verdict };
1588
1653
  });
1589
1654
  }
1655
+ function admitDrawFunding(record, args) {
1656
+ const verdict = verifyDrawFundingReceiptChain({
1657
+ receipt: args.receipt,
1658
+ builder: args.builder,
1659
+ expectedCallerPubkey: args.callerPubkey,
1660
+ expectedCreditId: record.creditId
1661
+ });
1662
+ const named = verdict.receipt;
1663
+ if (!named) return { recorded: false, reason: "invalid", verifyReason: "signature_invalid" };
1664
+ if (verdict.reason === "caller_pubkey_mismatch") return { recorded: false, reason: "caller_mismatch" };
1665
+ if (verdict.reason === "credit_id_mismatch") return { recorded: false, reason: "unknown_credit" };
1666
+ if (verdict.status === "invalid") {
1667
+ const provider = verdict.reason === "dvm_identity_mismatch" || verdict.reason === "receipt_key_mismatch" || verdict.reason === "attestation_invalid";
1668
+ return {
1669
+ recorded: false,
1670
+ reason: provider ? "provider_mismatch" : "invalid",
1671
+ ...verdict.reason ? { verifyReason: verdict.reason } : {}
1672
+ };
1673
+ }
1674
+ if (args.identity && named.dvm_id !== args.identity.dvmId) {
1675
+ return { recorded: false, reason: "provider_mismatch", verifyReason: "dvm_identity_mismatch" };
1676
+ }
1677
+ if (record.dvmId !== void 0 && named.dvm_id !== record.dvmId) {
1678
+ return { recorded: false, reason: "provider_mismatch", verifyReason: "dvm_identity_mismatch" };
1679
+ }
1680
+ const attested = dvmLocationIdentity(record);
1681
+ if (attested) {
1682
+ const anchorPubkey = args.builder?.pubkey?.trim().toLowerCase();
1683
+ if (verdict.status !== "verified" || anchorPubkey !== attested.builderPubkey) {
1684
+ return { recorded: false, reason: "provider_mismatch", verifyReason: "receipt_key_mismatch" };
1685
+ }
1686
+ }
1687
+ if (named.currency !== record.currency) return { recorded: false, reason: "currency_mismatch" };
1688
+ if (named.ledger_seq <= record.ledgerSeq) return { recorded: false, reason: "already_reflected" };
1689
+ const held = record.drawFundings ?? [];
1690
+ if (held.some((fact) => fact.fundId === named.fund_id)) {
1691
+ return { recorded: false, reason: "duplicate" };
1692
+ }
1693
+ held.push({
1694
+ fundId: named.fund_id,
1695
+ jobId: named.job_id,
1696
+ drawId: named.draw_id,
1697
+ fundedMicro: named.funded_micro,
1698
+ ledgerSeq: named.ledger_seq,
1699
+ balanceAfterMicro: named.balance_after_micro,
1700
+ recordedAt: args.now,
1701
+ receipt: named
1702
+ });
1703
+ held.sort((a, b) => a.ledgerSeq - b.ledgerSeq || a.recordedAt - b.recordedAt);
1704
+ record.drawFundings = held;
1705
+ return { recorded: true };
1706
+ }
1707
+ function pruneDrawFundings(record, ledgerSeq, drawId) {
1708
+ if (!record.drawFundings) return;
1709
+ const kept = record.drawFundings.filter(
1710
+ (fact) => fact.ledgerSeq > ledgerSeq && (drawId === void 0 || fact.drawId !== drawId)
1711
+ );
1712
+ if (kept.length === 0) delete record.drawFundings;
1713
+ else record.drawFundings = kept;
1714
+ }
1590
1715
  function applyImplicitReceiptCredit(args) {
1591
1716
  if (!args.credit.credit_id.startsWith("imp:")) return {};
1592
1717
  const now = args.now ?? Date.now();
@@ -1943,6 +2068,7 @@ function adoptCreditId(record, creditId) {
1943
2068
  delete record.refillDrainNoticed;
1944
2069
  delete record.discrepancy;
1945
2070
  delete record.lastReceiptJobId;
2071
+ delete record.drawFundings;
1946
2072
  }
1947
2073
  var MAX_SETTLED_DRAIN_EVIDENCE = 8;
1948
2074
  var MAX_LOST_IMPLICIT_CREDITS = 8;
@@ -6179,6 +6305,7 @@ export {
6179
6305
  isCreditFundRail,
6180
6306
  isCreditFundingMode,
6181
6307
  isDrainReceipt,
6308
+ isDrawFundingReceipt,
6182
6309
  isFundingReceipt,
6183
6310
  isJobIdentityValue,
6184
6311
  isPaymentRequestMessage,
@@ -6285,6 +6412,7 @@ export {
6285
6412
  recordBalanceResponse,
6286
6413
  recordCreditX402Instrument,
6287
6414
  recordDrainReceipts,
6415
+ recordDrawFunding,
6288
6416
  recordFundResponse,
6289
6417
  recordFundingMenuSnapshot,
6290
6418
  recordPendingDrain,
@@ -6322,6 +6450,7 @@ export {
6322
6450
  shellQuoteArg,
6323
6451
  signAttestation,
6324
6452
  signDrainReceipt,
6453
+ signDrawFundingReceipt,
6325
6454
  signDvmRequestData,
6326
6455
  signFundingReceipt,
6327
6456
  signReceipt,
@@ -6367,6 +6496,8 @@ export {
6367
6496
  verifyChallenge,
6368
6497
  verifyDrainReceipt,
6369
6498
  verifyDrainReceiptChain,
6499
+ verifyDrawFundingReceipt,
6500
+ verifyDrawFundingReceiptChain,
6370
6501
  verifyFundingReceipt,
6371
6502
  verifyFundingReceiptChain,
6372
6503
  verifyJobReceipt,
@@ -1,2 +1,2 @@
1
- export { ADMIN_STATE_UNAVAILABLE, AGENT_MNEMONIC_FILE, BTC_RATE_FILE, BUDGET_FILE, CAPABILITY_NAME_RE, COINGECKO_SIMPLE_PRICE_URL, CONFIG_AUDIT_FILE, CONFIG_BACKUP_FILE, CONFIG_DIR, CONFIG_FILE, CONFIG_PINNED_FILE, CREDITS_FILE, CREDIT_DRAIN_RAILS, CREDIT_FUNDING_MODES, CREDIT_FUND_RAILS, DEFAULT_AGENT_MINT_URL, DIAGNOSTIC_CATALOGUE_VERSION, DbTransport, DvmError, DvmX402ChannelStorage, FAVORITES_FILE, FEEDBACK_NUDGES_FILE, FX_CACHE_TTL_MS, FX_RETRY_COUNT, IDENTITIES_FILE, IDENTITIES_VERSION, InvalidUsdPriceError, JOBS_FILE, JOB_IDENTITY_HEADER, MESSAGES_DIR, MemoryKVStore, NwcBackend, NwcError, PAIRINGS_DIR, PRIVKEY_HEX_RE, PersistentCounterSource, RAIL_FLAGS, RAIL_REFUNDABLE, RECEIPTS_FILE, RECENT_SPENDS_CAP, RECOVERY_MNEMONIC_FILE, REQUEST_INTENTS_DIR, ROUTER_FEEDBACK_CLAIM_HEADER, ROUTER_FEEDBACK_CLAIM_TTL_MS, SPANS_INSERTED_CHANNEL, STABLECOIN_FUND_RAILS, SUPPORTED_PROTOCOL_VERSION, SpanWriter, StepCache, TEMPO_CHAIN_ID, TEMPO_CHANNELS_FILE, TEMPO_CHARGE_PENDING_STALE_MS, TEMPO_MODERATO_CHAIN_ID, TEMPO_MODERATO_RPC, TEMPO_PATH_USD_MODERATO, TEMPO_SESSION_UPDATED_REASON, WALLET_FILE, WALLET_VERSION, X402EnvValidationError, X402_BATCH_CHANNEL_ABI, X402_BATCH_SETTLEMENT_KEY, X402_BATCH_SETTLEMENT_SCHEME, X402_CHANNELS_FILE, X402_DEFAULT_FACILITATOR, X402_DEFAULT_NETWORK, X402_EXACT_AUTHORIZATION_TTL_SECONDS, X402_EXACT_SCHEME, X402_NETWORKS, X402_PENDING_STALE_MS, X402_RECEIVER_AUTHORIZER_KEY, X402_REFUSAL_TRANSACTION_DISCOVERY_WINDOW_MS, X402_RPC_URL_KEY, X402_SELF_RELAY_KEY, X402_V1_VERSION, X402_VERSION, acknowledgeReplayedX402Payment, acknowledgeX402ChannelOwner, advanceTempoChannelExit, amountBoundsVerdict, appendBudgetSpend, appendFundingReceipt, appendReceipt, applyImplicitReceiptCredit, applyReceiptCredit, applyRetryToPool, asProviderText, asProviderTextOpt, assertAgentMnemonicReplaceable, assertNoRivalX402Voucher, assertNutSupport, assertSupportedX402Network, assertTempoSessionChallengeWithinAsk, assertTempoSessionDepositWithinCap, assertTempoSessionVoucherWithinAsk, assertX402ChannelPayer, assertX402RequirementDescribesChannel, attestedDvmIdentity, authenticatedBuilderPubkey, backupSecretFile, bindCashuTokenToSubmissionContext, bindDiagnosticCapabilityAuthority, bindDiagnosticIdentityAuthority, breakdownSince, buildAdminAuthHeader, buildAdminChallenge, buildAttestation, buildPaymentRequiredV2, buildPaymentRequirements, builderLockPath, caip2ToX402Network, canReplaceExpiredX402Deposit, canSwap, canonicalRequestPath, canonicaliseForSigning, canonicalize, capFor, cashuSubmissionBindingFingerprint, cashuSubmissionBindingFromContext, chainIdFromCaip2, checkBudgetForLedger, checkMeltQuoteState, checkMintHealth, checkReceiptAttestation, clearCreditSelection, clearPendingDrain, clearPendingFunding, clearPendingTempoChargeFunding, clearPendingX402ExactFunding, clearPendingX402Funding, clearRefillRailUnavailable, cliIdentityStoreGenerateIdentity, computeResultHash, computeSmartDenominations, costAnchor, coveringMintsForSpend, createDiagnosticCapabilityAuthority, createMintQuoteRetryState, createMonotonicClock, createNoopLogger, createStdoutLogger, createTempoChannelStore, createTempoCloseCredential, createTempoCreditSession, createTempoSessionPaymentFetch, createX402BatchPayment, currentContext, decodePayment, decodePaymentRequiredHeader, deleteAgentMnemonic, deriveAgentMasterKeypair, deriveAgentRefundSubkey, deriveAgentRefundSubkeyPubkey, deriveBuilderLockKeypair, deriveBuilderLockPubkey, deriveIdentityFromPrivkey, derivePubkeyFromPrivkey, deriveReceiptKeypair, deriveReceiptSecret, deriveTempoAddress, dvmLocationIdentity, effectiveFundingMint, effectiveMints, encodePayment, encodePaymentRequiredHeader, encodeSettleResponseHeader, ensureAddress, ensureConfigDir, ensureConfigSubdir, ensureProvisionalCredit, entryKind, exactEvmAuthorization, extendDiagnosticIdentityAuthority, fetchBtcUsdRate, fetchCoinGeckoBtcUsd, fetchCoinGeckoSpot, fetchLnurlPayInvoice, fetchMeltQuote, findX402Channel, forgetCredit, formatStaleness, formatUsd, formatUsdcMicrounits, fundWireAmountMicro, fundingModeForTempoIntent, fundingModeForX402Flavour, generateAgentMnemonic, generateEphemeralReceiptKey, generateIdentity, generateX402PrivateKey, getBalance, getBalanceByMint, getInfo, getInputFeesForProofs, getLastKnownBtcRate, getTempoUsdcBalance, getWallet, getX402Balance, hashCapabilities, hashedCanonicalDvmId, identitiesFileExists, initLoggers, insertSpanBatch, isAbortError, isArtifactMessage, isCancelMessage, isCompleteMessage, isCreditFundRail, isCreditFundingMode, isDrainReceipt, isFundingReceipt, isJobIdentityValue, isPaymentRequestMessage, isPromptMessage, isPublicRequestId, isSignableExactRequirement, isSignedJobReceipt, isStablecoinFundRail, isStorableJobId, isTextMessage, isValidEvmPrivateKey, isWorkingMessage, issueRouterFeedbackClaim, listCredits, listFundingMenuSnapshots, listImplicitCredits, listPendingFundings, listPendingX402Fundings, listPendingX402FundingsForChannel, listResumableTempoChargeFundings, listResumableX402ExactFundings, listResumableX402Fundings, listTempoChannelAssociations, listTransactions, listX402Channels, loadAgentWallet, loadBudgetLedger, loadCredit, loadCreditX402Binding, loadIdentities, loadIdentitySecret, loadImplicitCredits, loadPendingFunding, loadReceipt, loadReceipts, loadResumableTempoChargeFunding, loadResumableX402ExactFunding, loadResumableX402Funding, loadTempoChannelAssociation, loadTempoChannelAssociationByKey, loadTempoChannelController, loadTempoChannelEntry, loadWalletConfiguredMints, loggers, looksLikeMnemonic, lookupInvoice, makeInvoice, markCredit, markImplicitCreditLost, markRefillDrainNoticed, markRefillRailUnavailable, maxAdvertisedMicro, maxKeysetDenomination, meltAmountBounds, microToSats, missingDleqRecoveryDiagnostic, mnemonicFingerprint, msatsToMicro, msatsToUsd, msatsToUsdCents, msatsToUsdc, normalizeCreditEndpoint, normalizeFeedbackEndpointHost, nwcDedupWindowMs, nwcTimeoutMs, offersTempoCreditCharge, offersTempoCreditFunding, offersTempoCreditSession, offersX402CreditChannel, offersX402CreditFlavour, offersX402CreditFunding, parseCreditMenu, parseCreditTerms, parseJobIdentityHeader, parseLnAddress, parseNwcUri, parseTraceparent, parseUsdPrice, payInvoiceReconciling, paymentRequiredV2FromV1, pendingDrainById, pendingDrainFor, persistTempoOpenCredential, pinDimension, prepareP2PKMint, processX402BatchCorrection, processX402BatchResponse, processX402BatchResponseForWallet, projectDiagnosticFields, projectEventName, projectSpanRow, providerProseSources, providerTextToString, randomTraceId, readAgentMnemonic, readCompletedCreditHistory, readFundValuation, readX402ChannelGuardFacts, readX402ChannelOnChain, receiptPubkeyFromSecret, receiveToAgentWallet, reconcileRefusedX402Deposits, reconcileTempoChannelOnChain, recordBalanceResponse, recordCreditX402Instrument, recordDrainReceipts, recordFundResponse, recordFundingMenuSnapshot, recordPendingDrain, recordPendingFunding, recordPendingTempoChargeFunding, recordPendingX402ExactFunding, recordPendingX402Funding, recordRefusedDrawBalance, recordX402ChannelMetadata, redactUrl, redactUrlsInText, refundX402BatchChannel, rehydrateOutputData, repairConfigDirMode, resolveLnurlPayMetadataUrl, resolveRpcHttpTransportOptions, resolveRpcOverride, resolveTempoAsset, resolveTempoNetwork, resolveX402Asset, resolveX402ChannelRpc, restoreProofsFromOutputs, retirePendingX402Funding, retireTempoChannel, retireTempoChannelScope, retryMintQuoteOperation, saveAgentWallet, saveBudgetLedger, saveIdentities, selectProofsForSpend, serializeOutputData, setEmitter, settleDrainEvidence, sha256hex, shellQuoteArg, signAttestation, signDrainReceipt, signDvmRequestData, signFundingReceipt, signReceipt, signRequestData, signedRequestDomain, spendEntry, swapFeeForProofs, swapSendReserve, tempoAccountFromConfig, tempoBalanceCheckHint, tempoChallengeAmountMicro, tempoChannelControlledBy, tempoChargeCredentialSettleable, tempoCredentialAmountMicro, tempoCredentialValidBefore, tempoDescriptorController, tempoSessionAssociationByKey, tempoSessionChallenge, tempoSessionChallengeChannelScope, tempoSessionChallengeMicro, tempoSessionCredentialChannelScope, tempoSessionCredentialCumulativeMicro, tempoSessionCumulativeCapMicro, tempoSessionPriorCumulativeMicro, tempoTokenReference, toAgentProof, toCashuProofs, toLockPubkey, transportErrorCode, tryResolveTempoAsset, unsignRequestData, usdToMsats, usdcContractByCaip2, usdcContractFor, usdcDomainNameFor, usdcDomainVersionFor, usdcToMsats, validateAgentMnemonic, validateLnAddress, validateX402Env, verifyAttestation, verifyCanonicalSignedRequest, verifyChallenge, verifyDrainReceipt, verifyDrainReceiptChain, verifyFundingReceipt, verifyFundingReceiptChain, verifyJobReceipt, verifyReceipt, verifyRouterFeedbackClaim, walletExists, warmFxSnapshot, weakestReceiptVerdict, windowEnd, windowStart, withIdentitiesLock, withInitRetry, withNwcPool, withTempoChannelLock, withTraceContext, withWalletLock, withX402ChannelLock, withholdsTempoCreditSession, withinAdvertisedTolerance, writeAgentMnemonic, writeIdentity, x402ChannelBalanceUnreconciledAt, x402ChannelControlledBy, x402ChannelReservation, x402CreditChannelNetworks, x402CreditExactNetworks, x402CreditFlavour, x402CreditFundingNetworks, x402ExactFundingDead, x402FlavourForInstrument, x402InstrumentForFlavour, x402NetworkByCaip2, x402NetworkBySlug, x402NetworkLabel, x402NetworkListForCopy, x402NetworkToCaip2, x402PendingBlockExpiresAt, x402PendingDepositExpiresAt, x402PendingFundingJson, x402PendingRetired, x402PendingStale, x402PendingUnsettled, x402RequiredFromError, x402ReservationRelease, x402SupportedNetworksHint, x402VoucherPendingState, x402WalletFromConfig } from "./caller.js";
1
+ export { ADMIN_STATE_UNAVAILABLE, AGENT_MNEMONIC_FILE, BTC_RATE_FILE, BUDGET_FILE, CAPABILITY_NAME_RE, COINGECKO_SIMPLE_PRICE_URL, CONFIG_AUDIT_FILE, CONFIG_BACKUP_FILE, CONFIG_DIR, CONFIG_FILE, CONFIG_PINNED_FILE, CREDITS_FILE, CREDIT_DRAIN_RAILS, CREDIT_FUNDING_MODES, CREDIT_FUND_RAILS, DEFAULT_AGENT_MINT_URL, DIAGNOSTIC_CATALOGUE_VERSION, DbTransport, DvmError, DvmX402ChannelStorage, FAVORITES_FILE, FEEDBACK_NUDGES_FILE, FX_CACHE_TTL_MS, FX_RETRY_COUNT, IDENTITIES_FILE, IDENTITIES_VERSION, InvalidUsdPriceError, JOBS_FILE, JOB_IDENTITY_HEADER, MESSAGES_DIR, MemoryKVStore, NwcBackend, NwcError, PAIRINGS_DIR, PRIVKEY_HEX_RE, PersistentCounterSource, RAIL_FLAGS, RAIL_REFUNDABLE, RECEIPTS_FILE, RECENT_SPENDS_CAP, RECOVERY_MNEMONIC_FILE, REQUEST_INTENTS_DIR, ROUTER_FEEDBACK_CLAIM_HEADER, ROUTER_FEEDBACK_CLAIM_TTL_MS, SPANS_INSERTED_CHANNEL, STABLECOIN_FUND_RAILS, SUPPORTED_PROTOCOL_VERSION, SpanWriter, StepCache, TEMPO_CHAIN_ID, TEMPO_CHANNELS_FILE, TEMPO_CHARGE_PENDING_STALE_MS, TEMPO_MODERATO_CHAIN_ID, TEMPO_MODERATO_RPC, TEMPO_PATH_USD_MODERATO, TEMPO_SESSION_UPDATED_REASON, WALLET_FILE, WALLET_VERSION, X402EnvValidationError, X402_BATCH_CHANNEL_ABI, X402_BATCH_SETTLEMENT_KEY, X402_BATCH_SETTLEMENT_SCHEME, X402_CHANNELS_FILE, X402_DEFAULT_FACILITATOR, X402_DEFAULT_NETWORK, X402_EXACT_AUTHORIZATION_TTL_SECONDS, X402_EXACT_SCHEME, X402_NETWORKS, X402_PENDING_STALE_MS, X402_RECEIVER_AUTHORIZER_KEY, X402_REFUSAL_TRANSACTION_DISCOVERY_WINDOW_MS, X402_RPC_URL_KEY, X402_SELF_RELAY_KEY, X402_V1_VERSION, X402_VERSION, acknowledgeReplayedX402Payment, acknowledgeX402ChannelOwner, advanceTempoChannelExit, amountBoundsVerdict, appendBudgetSpend, appendFundingReceipt, appendReceipt, applyImplicitReceiptCredit, applyReceiptCredit, applyRetryToPool, asProviderText, asProviderTextOpt, assertAgentMnemonicReplaceable, assertNoRivalX402Voucher, assertNutSupport, assertSupportedX402Network, assertTempoSessionChallengeWithinAsk, assertTempoSessionDepositWithinCap, assertTempoSessionVoucherWithinAsk, assertX402ChannelPayer, assertX402RequirementDescribesChannel, attestedDvmIdentity, authenticatedBuilderPubkey, backupSecretFile, bindCashuTokenToSubmissionContext, bindDiagnosticCapabilityAuthority, bindDiagnosticIdentityAuthority, breakdownSince, buildAdminAuthHeader, buildAdminChallenge, buildAttestation, buildPaymentRequiredV2, buildPaymentRequirements, builderLockPath, caip2ToX402Network, canReplaceExpiredX402Deposit, canSwap, canonicalRequestPath, canonicaliseForSigning, canonicalize, capFor, cashuSubmissionBindingFingerprint, cashuSubmissionBindingFromContext, chainIdFromCaip2, checkBudgetForLedger, checkMeltQuoteState, checkMintHealth, checkReceiptAttestation, clearCreditSelection, clearPendingDrain, clearPendingFunding, clearPendingTempoChargeFunding, clearPendingX402ExactFunding, clearPendingX402Funding, clearRefillRailUnavailable, cliIdentityStoreGenerateIdentity, computeResultHash, computeSmartDenominations, costAnchor, coveringMintsForSpend, createDiagnosticCapabilityAuthority, createMintQuoteRetryState, createMonotonicClock, createNoopLogger, createStdoutLogger, createTempoChannelStore, createTempoCloseCredential, createTempoCreditSession, createTempoSessionPaymentFetch, createX402BatchPayment, currentContext, decodePayment, decodePaymentRequiredHeader, deleteAgentMnemonic, deriveAgentMasterKeypair, deriveAgentRefundSubkey, deriveAgentRefundSubkeyPubkey, deriveBuilderLockKeypair, deriveBuilderLockPubkey, deriveIdentityFromPrivkey, derivePubkeyFromPrivkey, deriveReceiptKeypair, deriveReceiptSecret, deriveTempoAddress, dvmLocationIdentity, effectiveFundingMint, effectiveMints, encodePayment, encodePaymentRequiredHeader, encodeSettleResponseHeader, ensureAddress, ensureConfigDir, ensureConfigSubdir, ensureProvisionalCredit, entryKind, exactEvmAuthorization, extendDiagnosticIdentityAuthority, fetchBtcUsdRate, fetchCoinGeckoBtcUsd, fetchCoinGeckoSpot, fetchLnurlPayInvoice, fetchMeltQuote, findX402Channel, forgetCredit, formatStaleness, formatUsd, formatUsdcMicrounits, fundWireAmountMicro, fundingModeForTempoIntent, fundingModeForX402Flavour, generateAgentMnemonic, generateEphemeralReceiptKey, generateIdentity, generateX402PrivateKey, getBalance, getBalanceByMint, getInfo, getInputFeesForProofs, getLastKnownBtcRate, getTempoUsdcBalance, getWallet, getX402Balance, hashCapabilities, hashedCanonicalDvmId, identitiesFileExists, initLoggers, insertSpanBatch, isAbortError, isArtifactMessage, isCancelMessage, isCompleteMessage, isCreditFundRail, isCreditFundingMode, isDrainReceipt, isDrawFundingReceipt, isFundingReceipt, isJobIdentityValue, isPaymentRequestMessage, isPromptMessage, isPublicRequestId, isSignableExactRequirement, isSignedJobReceipt, isStablecoinFundRail, isStorableJobId, isTextMessage, isValidEvmPrivateKey, isWorkingMessage, issueRouterFeedbackClaim, listCredits, listFundingMenuSnapshots, listImplicitCredits, listPendingFundings, listPendingX402Fundings, listPendingX402FundingsForChannel, listResumableTempoChargeFundings, listResumableX402ExactFundings, listResumableX402Fundings, listTempoChannelAssociations, listTransactions, listX402Channels, loadAgentWallet, loadBudgetLedger, loadCredit, loadCreditX402Binding, loadIdentities, loadIdentitySecret, loadImplicitCredits, loadPendingFunding, loadReceipt, loadReceipts, loadResumableTempoChargeFunding, loadResumableX402ExactFunding, loadResumableX402Funding, loadTempoChannelAssociation, loadTempoChannelAssociationByKey, loadTempoChannelController, loadTempoChannelEntry, loadWalletConfiguredMints, loggers, looksLikeMnemonic, lookupInvoice, makeInvoice, markCredit, markImplicitCreditLost, markRefillDrainNoticed, markRefillRailUnavailable, maxAdvertisedMicro, maxKeysetDenomination, meltAmountBounds, microToSats, missingDleqRecoveryDiagnostic, mnemonicFingerprint, msatsToMicro, msatsToUsd, msatsToUsdCents, msatsToUsdc, normalizeCreditEndpoint, normalizeFeedbackEndpointHost, nwcDedupWindowMs, nwcTimeoutMs, offersTempoCreditCharge, offersTempoCreditFunding, offersTempoCreditSession, offersX402CreditChannel, offersX402CreditFlavour, offersX402CreditFunding, parseCreditMenu, parseCreditTerms, parseJobIdentityHeader, parseLnAddress, parseNwcUri, parseTraceparent, parseUsdPrice, payInvoiceReconciling, paymentRequiredV2FromV1, pendingDrainById, pendingDrainFor, persistTempoOpenCredential, pinDimension, prepareP2PKMint, processX402BatchCorrection, processX402BatchResponse, processX402BatchResponseForWallet, projectDiagnosticFields, projectEventName, projectSpanRow, providerProseSources, providerTextToString, randomTraceId, readAgentMnemonic, readCompletedCreditHistory, readFundValuation, readX402ChannelGuardFacts, readX402ChannelOnChain, receiptPubkeyFromSecret, receiveToAgentWallet, reconcileRefusedX402Deposits, reconcileTempoChannelOnChain, recordBalanceResponse, recordCreditX402Instrument, recordDrainReceipts, recordDrawFunding, recordFundResponse, recordFundingMenuSnapshot, recordPendingDrain, recordPendingFunding, recordPendingTempoChargeFunding, recordPendingX402ExactFunding, recordPendingX402Funding, recordRefusedDrawBalance, recordX402ChannelMetadata, redactUrl, redactUrlsInText, refundX402BatchChannel, rehydrateOutputData, repairConfigDirMode, resolveLnurlPayMetadataUrl, resolveRpcHttpTransportOptions, resolveRpcOverride, resolveTempoAsset, resolveTempoNetwork, resolveX402Asset, resolveX402ChannelRpc, restoreProofsFromOutputs, retirePendingX402Funding, retireTempoChannel, retireTempoChannelScope, retryMintQuoteOperation, saveAgentWallet, saveBudgetLedger, saveIdentities, selectProofsForSpend, serializeOutputData, setEmitter, settleDrainEvidence, sha256hex, shellQuoteArg, signAttestation, signDrainReceipt, signDrawFundingReceipt, signDvmRequestData, signFundingReceipt, signReceipt, signRequestData, signedRequestDomain, spendEntry, swapFeeForProofs, swapSendReserve, tempoAccountFromConfig, tempoBalanceCheckHint, tempoChallengeAmountMicro, tempoChannelControlledBy, tempoChargeCredentialSettleable, tempoCredentialAmountMicro, tempoCredentialValidBefore, tempoDescriptorController, tempoSessionAssociationByKey, tempoSessionChallenge, tempoSessionChallengeChannelScope, tempoSessionChallengeMicro, tempoSessionCredentialChannelScope, tempoSessionCredentialCumulativeMicro, tempoSessionCumulativeCapMicro, tempoSessionPriorCumulativeMicro, tempoTokenReference, toAgentProof, toCashuProofs, toLockPubkey, transportErrorCode, tryResolveTempoAsset, unsignRequestData, usdToMsats, usdcContractByCaip2, usdcContractFor, usdcDomainNameFor, usdcDomainVersionFor, usdcToMsats, validateAgentMnemonic, validateLnAddress, validateX402Env, verifyAttestation, verifyCanonicalSignedRequest, verifyChallenge, verifyDrainReceipt, verifyDrainReceiptChain, verifyDrawFundingReceipt, verifyDrawFundingReceiptChain, verifyFundingReceipt, verifyFundingReceiptChain, verifyJobReceipt, verifyReceipt, verifyRouterFeedbackClaim, walletExists, warmFxSnapshot, weakestReceiptVerdict, windowEnd, windowStart, withIdentitiesLock, withInitRetry, withNwcPool, withTempoChannelLock, withTraceContext, withWalletLock, withX402ChannelLock, withholdsTempoCreditSession, withinAdvertisedTolerance, writeAgentMnemonic, writeIdentity, x402ChannelBalanceUnreconciledAt, x402ChannelControlledBy, x402ChannelReservation, x402CreditChannelNetworks, x402CreditExactNetworks, x402CreditFlavour, x402CreditFundingNetworks, x402ExactFundingDead, x402FlavourForInstrument, x402InstrumentForFlavour, x402NetworkByCaip2, x402NetworkBySlug, x402NetworkLabel, x402NetworkListForCopy, x402NetworkToCaip2, x402PendingBlockExpiresAt, x402PendingDepositExpiresAt, x402PendingFundingJson, x402PendingRetired, x402PendingStale, x402PendingUnsettled, x402RequiredFromError, x402ReservationRelease, x402SupportedNetworksHint, x402VoucherPendingState, x402WalletFromConfig } from "./caller.js";
2
2
  export { DEFAULT_LOCK_PUBKEY_GRACE_SECONDS, JobCancelledError, MintHealthTracker, NON_CHANNEL_BITCOIN_RAILS, PAYMENT_PROOF_KEYS, PayoutReporter, PostgresTempoChargeStore, PostgresTempoSessionStore, RevenueReporter, SIGNED_ENVELOPE_FIELDS, SIGNED_ENVELOPE_TYPES, TEMPO_CLOSE_DB_RECOVERY_BUDGET_MS, TEMPO_CLOSE_REQUESTED_TOPIC, TempoSessionChannelMismatchError, X402FacilitatorHealth, X402_BATCH_SETTLEMENT_MAINNET_NETWORK, _testing, abortJob, activePubkeySet, applyPaymentInfoToJob, assertRevenueReporterReady, buildPaymentErrorResponse, clearAccumulatorForDvm, createAdminCashuNonceStore, createDVMServer, createDefaultReplayStore, createInstrumentedFetch, creditDepositPayload, depleteLots, derivedFundCreditId, devModeSkipsPaymentVerification, fifoOrder, fromJobRecord, fundedMicroFor, hasPaymentProof, hashLockKey, humanizeZodError, implicitCreditId, inKindDrawMsats, initLockPubkeyTable, initWalletAccumulatorTable, insertAccumulatorRows, installAdminCashuRoutes, isDerivedCreditId, isInKindDepletion, isNonChannelBitcoinRail, isStaleJobReapable, isTerminal, isYieldMessage, issueUpfrontChallenges, jobCredentialGate, loadLockPubkeyState, lockPubkeyStoreToLockPubkey, lotOwedSats, msatsToFiatMicro, netOwedSats, paymentErrorBody, pinAskFiat, priceFiatMicro, processIncomingPayment, providerMessage, pruneRetired, rateUnavailablePaymentError, repairX402ExactSettlementEffect, resolveFxSnapshot, resolvePriceFiat, revenueReporterBannerState, rotateLockPubkey, seedLockPubkeyState, settleWithFacilitator, toCreditTerms, toJobRecord, unknownRouteNotFound, verifyIncomingPayment, verifyTempoSessionManagementCredential, verifyUpfrontPayment, verifyWithFacilitator, verifyX402Payment, wrapMppx, x402RequiredUsdcMicro, x402SettledShare } from "./server.js";
@@ -1,22 +1,22 @@
1
1
  import { FacilitatorConfig } from '@x402/core/server';
2
- import { al as PaymentPayload, aa as PaymentRequirementsV1, ab as PaymentRequirementsV2, aF as X402Config, aw as SettleResponse, aD as VerifyResponse, bj as X402ExactVersionSupport, bk as X402Receipt, bl as TransactionalPayoutHook, bm as CashuMeltCompleted } from '../step-cache-WUig1cx-.js';
3
- export { bn as CreditDepositPayload, bo as CreditDrainPayload, bp as FundingLot, bq as LotDebit, br as LotDepletion, bs as MppxServer, bt as NON_CHANNEL_BITCOIN_RAILS, bu as NonChannelBitcoinRail, bv as PayoutReporter, bw as PostgresTempoSessionStore, bx as RevenueReporter, by as SIGNED_ENVELOPE_FIELDS, bz as SIGNED_ENVELOPE_TYPES, bA as X402TrackedChannel, bB as _testing, bC as createDefaultReplayStore, bD as depleteLots, bE as fifoOrder, bF as inKindDrawMsats, bG as isInKindDepletion, bH as isNonChannelBitcoinRail, bI as lotOwedSats, bJ as netOwedSats, bK as wrapMppx } from '../step-cache-WUig1cx-.js';
2
+ import { am as PaymentPayload, ab as PaymentRequirementsV1, ac as PaymentRequirementsV2, aH as X402Config, ax as SettleResponse, aF as VerifyResponse, bo as X402ExactVersionSupport, bp as X402Receipt, bq as TransactionalPayoutHook, br as CashuMeltCompleted } from '../step-cache-CoORQQ_Y.js';
3
+ export { bs as CreditDepositPayload, bt as CreditDrainPayload, bu as FundingLot, bv as LotDebit, bw as LotDepletion, bx as MppxServer, by as NON_CHANNEL_BITCOIN_RAILS, bz as NonChannelBitcoinRail, bA as PayoutReporter, bB as PostgresTempoSessionStore, bC as RevenueReporter, bD as SIGNED_ENVELOPE_FIELDS, bE as SIGNED_ENVELOPE_TYPES, bF as X402TrackedChannel, bG as _testing, bH as createDefaultReplayStore, bI as depleteLots, bJ as fifoOrder, bK as inKindDrawMsats, bL as isInKindDepletion, bM as isNonChannelBitcoinRail, bN as lotOwedSats, bO as netOwedSats, bP as wrapMppx } from '../step-cache-CoORQQ_Y.js';
4
4
  import { Hono } from 'hono';
5
5
  import { Env, BlankSchema } from 'hono/types';
6
6
  import { Pool } from 'pg';
7
7
  export { Pool } from 'pg';
8
8
  import { g as getWallet } from '../wallet-Dwjs5n_M.js';
9
- import { C as ConsumedCredentialStore, L as LockPubkeyStateLoader } from '../credit-menu-KqobCjkW.js';
10
- export { A as AccumulatorPool, a as AppEnv, b as CreditFundingReport, D as DEFAULT_LOCK_PUBKEY_GRACE_SECONDS, F as FiatDenomination, c as FiatDenominationFailure, d as FundOnlyRequest, I as IncomingPaymentOpts, J as JobCancelledError, e as LockPubkeyPool, f as LockPubkeyState, M as MintHealthTracker, P as PAYMENT_PROOF_KEYS, g as PaymentErrorCode, h as PaymentErrorDetail, i as PaymentInfo, j as PostgresTempoChargeStore, R as ReporterBannerOpts, k as ResolvedFx, l as RevenueBootCheckOpts, S as SDKServerOpts, m as ServerJob, n as ShortPayForfeit, T as TempoChannelReport, o as TempoObserverHealth, p as TempoSessionChannelMismatchError, U as UpfrontPaymentOpts, V as VerifiedIncomingPayment, q as VerifyIncomingSnapshot, X as X402BatchChannelObservation, r as X402FacilitatorHealth, s as X402SettlementEvidenceOutcome, t as X402SettlementRepair, u as X402SettlementRepairRefusal, v as X402SettlementRepaired, w as X402WedgedSettlement, x as X402WedgedSettlementPage, y as X402_BATCH_SETTLEMENT_MAINNET_NETWORK, z as abortJob, B as activePubkeySet, E as applyPaymentInfoToJob, G as assertRevenueReporterReady, H as buildPaymentErrorResponse, K as clearAccumulatorForDvm, N as createDVMServer, O as creditDepositPayload, Q as derivedFundCreditId, W as devModeSkipsPaymentVerification, Y as fromJobRecord, Z as fundedMicroFor, _ as hasPaymentProof, $ as hashLockKey, a0 as implicitCreditId, a1 as initLockPubkeyTable, a2 as initWalletAccumulatorTable, a3 as insertAccumulatorRows, a4 as isDerivedCreditId, a5 as isTerminal, a6 as isYieldMessage, a7 as issueUpfrontChallenges, a8 as loadLockPubkeyState, a9 as msatsToFiatMicro, aa as paymentErrorBody, ab as pinAskFiat, ac as priceFiatMicro, ad as processIncomingPayment, ae as providerMessage, af as pruneRetired, ag as repairX402ExactSettlementEffect, ah as resolveFxSnapshot, ai as resolvePriceFiat, aj as revenueReporterBannerState, ak as rotateLockPubkey, al as seedLockPubkeyState, am as toCreditTerms, an as toJobRecord, ao as unknownRouteNotFound, ap as verifyIncomingPayment, aq as verifyTempoSessionManagementCredential, ar as verifyUpfrontPayment, as as x402RequiredUsdcMicro, at as x402SettledShare } from '../credit-menu-KqobCjkW.js';
11
- export { O as OutgoingMessage, S as StaleJobReapable, i as isStaleJobReapable } from '../job-store-BVGvAaBG.js';
9
+ import { C as ConsumedCredentialStore, L as LockPubkeyStateLoader } from '../credit-menu-C-kmf61K.js';
10
+ export { A as AccumulatorPool, a as AppEnv, b as CreditFundingReport, D as DEFAULT_LOCK_PUBKEY_GRACE_SECONDS, F as FiatDenomination, c as FiatDenominationFailure, d as FundOnlyRequest, I as IncomingPaymentOpts, J as JobCancelledError, e as LockPubkeyPool, f as LockPubkeyState, M as MintHealthTracker, P as PAYMENT_PROOF_KEYS, g as PaymentErrorCode, h as PaymentErrorDetail, i as PaymentInfo, j as PostgresTempoChargeStore, R as ReporterBannerOpts, k as ResolvedFx, l as RevenueBootCheckOpts, S as SDKServerOpts, m as ServerJob, n as ShortPayForfeit, T as TempoChannelReport, o as TempoObserverHealth, p as TempoSessionChannelMismatchError, U as UpfrontPaymentOpts, V as VerifiedIncomingPayment, q as VerifyIncomingSnapshot, X as X402BatchChannelObservation, r as X402FacilitatorHealth, s as X402SettlementEvidenceOutcome, t as X402SettlementRepair, u as X402SettlementRepairRefusal, v as X402SettlementRepaired, w as X402WedgedSettlement, x as X402WedgedSettlementPage, y as X402_BATCH_SETTLEMENT_MAINNET_NETWORK, z as abortJob, B as activePubkeySet, E as applyPaymentInfoToJob, G as assertRevenueReporterReady, H as buildPaymentErrorResponse, K as clearAccumulatorForDvm, N as createDVMServer, O as creditDepositPayload, Q as derivedFundCreditId, W as devModeSkipsPaymentVerification, Y as fromJobRecord, Z as fundedMicroFor, _ as hasPaymentProof, $ as hashLockKey, a0 as implicitCreditId, a1 as initLockPubkeyTable, a2 as initWalletAccumulatorTable, a3 as insertAccumulatorRows, a4 as isDerivedCreditId, a5 as isTerminal, a6 as isYieldMessage, a7 as issueUpfrontChallenges, a8 as loadLockPubkeyState, a9 as msatsToFiatMicro, aa as paymentErrorBody, ab as pinAskFiat, ac as priceFiatMicro, ad as processIncomingPayment, ae as providerMessage, af as pruneRetired, ag as repairX402ExactSettlementEffect, ah as resolveFxSnapshot, ai as resolvePriceFiat, aj as revenueReporterBannerState, ak as rotateLockPubkey, al as seedLockPubkeyState, am as toCreditTerms, an as toJobRecord, ao as unknownRouteNotFound, ap as verifyIncomingPayment, aq as verifyTempoSessionManagementCredential, ar as verifyUpfrontPayment, as as x402RequiredUsdcMicro, at as x402SettledShare } from '../credit-menu-C-kmf61K.js';
11
+ export { O as OutgoingMessage, S as StaleJobReapable, i as isStaleJobReapable } from '../job-store-DVCATwhU.js';
12
12
  import { z } from 'zod';
13
- export { f as LockPubkeyStoreLockPubkey, t as lockPubkeyStoreToLockPubkey } from '../lightning-backend-CsW_b6C7.js';
13
+ export { f as LockPubkeyStoreLockPubkey, t as lockPubkeyStoreToLockPubkey } from '../lightning-backend-DXNVlVs9.js';
14
14
  import 'mppx';
15
15
  import '@x402/evm/batch-settlement/server';
16
16
  import '@x402/core/types';
17
17
  import 'viem';
18
18
  import '@cashu/cashu-ts';
19
- import '../fx-DM7UCzg1.js';
19
+ import '../fx-hFlF4Cn8.js';
20
20
 
21
21
  declare function verifyWithFacilitator(payload: PaymentPayload, requirements: PaymentRequirementsV1 | PaymentRequirementsV2, config?: Pick<X402Config, "facilitator" | "facilitatorAuth">, createAuthHeaders?: FacilitatorConfig["createAuthHeaders"] | undefined): Promise<VerifyResponse>;
22
22
  declare function settleWithFacilitator(payload: PaymentPayload, requirements: PaymentRequirementsV1 | PaymentRequirementsV2, config?: Pick<X402Config, "facilitator" | "facilitatorAuth">, createAuthHeaders?: FacilitatorConfig["createAuthHeaders"] | undefined): Promise<SettleResponse>;
@@ -61,7 +61,7 @@ import {
61
61
  verifyUpfrontPayment,
62
62
  x402RequiredUsdcMicro,
63
63
  x402SettledShare
64
- } from "../chunk-HIQ3CEZ3.js";
64
+ } from "../chunk-JFH34P3M.js";
65
65
  import "../chunk-XRLKGCAW.js";
66
66
  import {
67
67
  PayoutReporter
@@ -70,7 +70,7 @@ import {
70
70
  settleWithFacilitator,
71
71
  verifyWithFacilitator
72
72
  } from "../chunk-E7ZBCT5U.js";
73
- import "../chunk-EQYHHYW4.js";
73
+ import "../chunk-TKJBUFYY.js";
74
74
  import "../chunk-TWKQFIOW.js";
75
75
  import {
76
76
  SIGNED_ENVELOPE_FIELDS,
@@ -93,7 +93,7 @@ import {
93
93
  } from "../chunk-AFV77S4C.js";
94
94
  import {
95
95
  toLockPubkey
96
- } from "../chunk-V3WFX65W.js";
96
+ } from "../chunk-5JSPTVIK.js";
97
97
  import "../chunk-62FI3NJF.js";
98
98
  import "../chunk-SXL44PL5.js";
99
99
  import "../chunk-7KQLPVV7.js";
@@ -110,10 +110,10 @@ import {
110
110
  isNonChannelBitcoinRail,
111
111
  lotOwedSats,
112
112
  netOwedSats
113
- } from "../chunk-Q2X4QYOB.js";
113
+ } from "../chunk-A2YESDQM.js";
114
114
  import "../chunk-YG7G4DPZ.js";
115
115
  import "../chunk-COYKJRMM.js";
116
- import "../chunk-5H7P3ORL.js";
116
+ import "../chunk-5UC7TOQC.js";
117
117
  import "../chunk-EP7OVWI5.js";
118
118
  import "../chunk-BPYMEMQX.js";
119
119
  import "../chunk-H3GGFEE5.js";
@@ -1,5 +1,5 @@
1
1
  import { ProofLike } from '@cashu/cashu-ts';
2
- import { a5 as Message, aj as FundingMethod, $ as FundingReceipt, bR as CreditSnapshot, a0 as JobReceipt, ay as StepRecord, a1 as MessageType } from './step-cache-WUig1cx-.js';
2
+ import { a6 as Message, ak as FundingMethod, a0 as FundingReceipt, bW as CreditSnapshot, a1 as JobReceipt, az as StepRecord, a2 as MessageType } from './step-cache-CoORQQ_Y.js';
3
3
 
4
4
  type JobStatus = "processing" | "completed" | "failed" | "awaiting-input" | "cancelled" | "working";
5
5
  interface JobRecord {
@@ -1,4 +1,4 @@
1
- import { X as JsonValue } from './step-cache-WUig1cx-.js';
1
+ import { X as JsonValue } from './step-cache-CoORQQ_Y.js';
2
2
 
3
3
  declare const lockPubkeyBrand: unique symbol;
4
4
  /**
@@ -1,10 +1,10 @@
1
1
  import {
2
2
  MemoryCreditLedger
3
- } from "./chunk-EQYHHYW4.js";
4
- import "./chunk-Q2X4QYOB.js";
3
+ } from "./chunk-TKJBUFYY.js";
4
+ import "./chunk-A2YESDQM.js";
5
5
  import "./chunk-YG7G4DPZ.js";
6
6
  import "./chunk-COYKJRMM.js";
7
- import "./chunk-5H7P3ORL.js";
7
+ import "./chunk-5UC7TOQC.js";
8
8
  import "./chunk-EP7OVWI5.js";
9
9
  import "./chunk-BPYMEMQX.js";
10
10
  import "./chunk-H3GGFEE5.js";
@@ -1,15 +1,15 @@
1
- import { ae as CashuMode, bL as CreditLedgerQuerier, bM as CreditDrainEnqueue, bN as HostedSettlementReportObligations, R as ResolvedCreditConfig, bO as DVMAuthScheme, B as SignedRequestDomain, bP as CreditLedgerLike, bQ as X402RefundSettlementGate, bR as CreditSnapshot, bS as CreditDrawRefundArgs, bT as CreditDrawRefundResult, bU as DrawResult, bV as X402SettlementStatus, bW as X402UnresolvedRefund, bX as GrownDrawResult, bY as DrawResolution, bZ as FundingRecord, $ as FundingReceipt, b_ as CreditInvoiceRecord, b$ as InvoiceSettlement, c0 as BlockedInvoiceCursor, c1 as InvoiceReconciliation, c2 as InvoiceWriteOff, c3 as DrawRecord, c4 as StalePendingDrawCursor, c5 as TempoCreditLossEvidence, c6 as TempoCreditLoss, c7 as X402CreditLossEvidence, c8 as X402CreditLoss, c9 as DrainMethod, ca as DrainRequestResult, cb as BitcoinDepositLiability, bp as FundingLot, cc as CreditDrainRecord, cd as ChannelDrainCursor, ce as DrainWriteOff, cf as DrainTransitionResult, cg as DrainReleaseResult, ch as DrainFulfilment, ci as HostingCleanupFence, a0 as JobReceipt, a5 as Message, K as KVStore, G as SignedRequestReplayStore, Z as ZodLike, a as DVMDescriptor } from '../step-cache-WUig1cx-.js';
2
- export { cj as CLIENT_COMPATIBILITY_HEADERS, d as CanonicalEnvelope, ck as ClientCompatibility, cl as ClientCompatibilityEnv, cm as ClientCompatibilityGate, cn as ClientCompatibilityRequirement, co as ClientSemVer, f as CreateSignedRequestVerifierOpts, cp as CreditFundingBasis, cq as CreditInvoiceStatus, cr as CreditLedger, cs as CreditLedgerError, ct as CreditLedgerErrorCode, cu as CreditLedgerErrorDetails, cv as CreditLedgerPool, cw as CreditStatus, cx as DRAIN_DELIVERY_RESERVE_SATS, cy as DVM_PROTOCOL_VERSION, cz as DrainConflictReason, cA as DrawRailValue, cB as DrawStatus, cC as HostedTempoCloseReportWriteOff, cD as JobCostReportPayload, cE as JobTerminalReportPayload, cF as PostgresX402ChannelStorage, cG as ReplayStoreBackend, cH as RevenueSkippedNoRailPayload, cI as RevenueSkippedNoRailReason, x as SIGNED_REQUEST_AUTH_ID, y as SIGNED_REQUEST_STATEMENT_VERSION, cJ as Secp256k1AuthOpts, z as SignedRequestAudience, E as SignedRequestError, F as SignedRequestFailure, H as SignedRequestSignOpts, M as SignedRequestStatementHeader, N as SignedRequestVerifier, cK as TempoDrainDecision, cL as TempoDrainDecisionArgs, cM as TempoDrainDecisionResult, cN as TempoDrainHoldReason, cO as X402ChannelStorageOpts, cP as X402RelayLockHolder, cQ as X402RelaySubmissionLock, cR as X402RelaySubmissionLockError, cS as allocateDrawValue, cT as clientCompatibilityAttributes, cU as clientCompatibilityMiddleware, cV as clientUpgradeRequired, O as createSignedRequestVerifier, cW as parseClientCapabilities, cX as parseClientCompatibility, cY as parseDvmClient, cZ as parseProtocolVersion, c_ as requireClientCompatibility, c$ as retryHostedTempoCloseReport, d0 as secp256k1Auth, d1 as signedRequestInput, V as signedRequestStatementHeader, d2 as writeOffHostedTempoCloseReport } from '../step-cache-WUig1cx-.js';
1
+ import { af as CashuMode, bQ as CreditLedgerQuerier, bR as CreditDrainEnqueue, bS as HostedSettlementReportObligations, R as ResolvedCreditConfig, bT as DVMAuthScheme, B as SignedRequestDomain, bU as CreditLedgerLike, bV as X402RefundSettlementGate, bW as CreditSnapshot, bX as CreditDrawRefundArgs, bY as CreditDrawRefundResult, bZ as DrawResult, b_ as X402SettlementStatus, b$ as X402UnresolvedRefund, c0 as GrownDrawResult, c1 as DrawResolution, c2 as FundingRecord, c3 as CreditFundingEvidence, c4 as CreditInvoiceRecord, c5 as InvoiceSettlement, c6 as BlockedInvoiceCursor, c7 as InvoiceReconciliation, c8 as InvoiceWriteOff, c9 as DrawRecord, ca as StalePendingDrawCursor, cb as TempoCreditLossEvidence, cc as TempoCreditLoss, cd as X402CreditLossEvidence, ce as X402CreditLoss, cf as DrainMethod, cg as DrainRequestResult, ch as BitcoinDepositLiability, bu as FundingLot, ci as CreditDrainRecord, cj as ChannelDrainCursor, ck as DrainWriteOff, cl as DrainTransitionResult, cm as DrainReleaseResult, cn as DrainFulfilment, co as HostingCleanupFence, a1 as JobReceipt, a6 as Message, K as KVStore, G as SignedRequestReplayStore, Z as ZodLike, a as DVMDescriptor } from '../step-cache-CoORQQ_Y.js';
2
+ export { cp as CLIENT_COMPATIBILITY_HEADERS, d as CanonicalEnvelope, cq as ClientCompatibility, cr as ClientCompatibilityEnv, cs as ClientCompatibilityGate, ct as ClientCompatibilityRequirement, cu as ClientSemVer, f as CreateSignedRequestVerifierOpts, cv as CreditFundingBasis, cw as CreditInvoiceStatus, cx as CreditLedger, cy as CreditLedgerError, cz as CreditLedgerErrorCode, cA as CreditLedgerErrorDetails, cB as CreditLedgerPool, cC as CreditStatus, cD as DRAIN_DELIVERY_RESERVE_SATS, cE as DVM_PROTOCOL_VERSION, cF as DrainConflictReason, cG as DrawRailValue, cH as DrawStatus, cI as HostedTempoCloseReportWriteOff, cJ as JobCostReportPayload, cK as JobTerminalReportPayload, cL as PostgresX402ChannelStorage, cM as ReplayStoreBackend, cN as RevenueSkippedNoRailPayload, cO as RevenueSkippedNoRailReason, x as SIGNED_REQUEST_AUTH_ID, y as SIGNED_REQUEST_STATEMENT_VERSION, cP as Secp256k1AuthOpts, z as SignedRequestAudience, E as SignedRequestError, F as SignedRequestFailure, H as SignedRequestSignOpts, M as SignedRequestStatementHeader, N as SignedRequestVerifier, cQ as TempoDrainDecision, cR as TempoDrainDecisionArgs, cS as TempoDrainDecisionResult, cT as TempoDrainHoldReason, cU as X402ChannelStorageOpts, cV as X402RelayLockHolder, cW as X402RelaySubmissionLock, cX as X402RelaySubmissionLockError, cY as allocateDrawValue, cZ as clientCompatibilityAttributes, c_ as clientCompatibilityMiddleware, c$ as clientUpgradeRequired, O as createSignedRequestVerifier, d0 as parseClientCapabilities, d1 as parseClientCompatibility, d2 as parseDvmClient, d3 as parseProtocolVersion, d4 as requireClientCompatibility, d5 as retryHostedTempoCloseReport, d6 as secp256k1Auth, d7 as signedRequestInput, V as signedRequestStatementHeader, d8 as writeOffHostedTempoCloseReport } from '../step-cache-CoORQQ_Y.js';
3
3
  import { Pool } from 'pg';
4
- import { au as CreditMenu, a as AppEnv, U as UpfrontPaymentOpts, i as PaymentInfo, av as ReceiptIssuer, aw as LightningReceive, ax as TempoSettlementReadiness, ay as DVMHostOpts, az as DVMServeResult, L as LockPubkeyStateLoader, C as ConsumedCredentialStore } from '../credit-menu-KqobCjkW.js';
5
- export { aA as BuildCreditMenuArgs, aB as BuilderIdentity, aC as CREDIT_ENVELOPE_KEYS, aD as CreateX402BatchSettlementServerOpts, aE as CreditEnvelope, aF as CreditEnvelopeError, aG as CreditFundCommitment, aH as CreditTerms, aI as DEFAULT_INVOICE_TTL_SECONDS, aJ as DVMHost, aK as HostingClosureCommand, aL as HostingClosureEvidence, aM as HostingControlCommand, aN as HostingControlConfig, aO as HostingControlStatus, aP as JobManager, aQ as JobManagerOpts, aR as LightningReceiveConfig, aS as MIN_INVOICE_TTL_SECONDS, aT as MemoryConsumedCredentialStore, aU as MemoryConsumedCredentialStoreOpts, aV as MemoryProcessedPaymentStore, aW as MemoryX402ExactSettlementStore, aX as MountOpts, aY as OwnerDisplay, aZ as PaidJobCompletion, a_ as PaymentMode, a$ as PlatformReporterOpts, b0 as PostgresProcessedPaymentStore, b1 as PostgresX402ExactSettlementStore, b2 as PriceFiat, b3 as ProcessedPaymentQuerier, b4 as ProcessedPaymentRail, b5 as ProcessedPaymentRecord, b6 as ProcessedPaymentReplayError, b7 as ProcessedPaymentStore, b8 as X402BatchAcceptance, b9 as X402BatchFunding, ba as X402BatchRefusal, bb as X402BatchSettlementServer, bc as X402ExactAcceptance, bd as X402ExactIntentConflictError, be as X402ExactSettlementAttempt, bf as X402ExactSettlementChainEvidence, bg as X402ExactSettlementEffect, bh as X402ExactSettlementEvidenceMissingError, bi as X402ExactSettlementEvidenceReader, bj as X402ExactSettlementIntent, bk as X402ExactSettlementNotReadyError, bl as X402ExactSettlementServer, bm as X402ExactSettlementServerOpts, bn as X402ExactSettlementStatus, bo as X402ExactSettlementStore, bp as X402SettlementChainEvidence, bq as X402SettlementEvidenceReader, br as X402SettlementSubmissionError, bs as X402_BATCH_AUTO_SETTLEMENT, bt as X402_BATCH_MIN_WITHDRAW_DELAY_SECONDS, bu as X402_BATCH_SETTLEMENT_NETWORK, bv as attachCreditMenu, bw as buildCreditMenu, bx as createDVMHost, by as createX402BatchSettlementServer, bz as creditEnvelopeIgnoreFields, bA as drawSettlementRef, bB as extractCreditEnvelope, bC as fundingCommitment, bD as selectPrimaryCredit, bE as signHostingClosure, bF as signHostingControl, bG as stripCreditEnvelope, bH as toCreditView } from '../credit-menu-KqobCjkW.js';
4
+ import { au as CreditMenu, a as AppEnv, U as UpfrontPaymentOpts, i as PaymentInfo, av as ReceiptIssuer, aw as LightningReceive, ax as TempoSettlementReadiness, ay as DVMHostOpts, az as DVMServeResult, L as LockPubkeyStateLoader, C as ConsumedCredentialStore } from '../credit-menu-C-kmf61K.js';
5
+ export { aA as BuildCreditMenuArgs, aB as BuilderIdentity, aC as CREDIT_ENVELOPE_KEYS, aD as CreateX402BatchSettlementServerOpts, aE as CreditEnvelope, aF as CreditEnvelopeError, aG as CreditFundCommitment, aH as CreditTerms, aI as DEFAULT_INVOICE_TTL_SECONDS, aJ as DVMHost, aK as HostingClosureCommand, aL as HostingClosureEvidence, aM as HostingControlCommand, aN as HostingControlConfig, aO as HostingControlStatus, aP as JobManager, aQ as JobManagerOpts, aR as LightningReceiveConfig, aS as MIN_INVOICE_TTL_SECONDS, aT as MemoryConsumedCredentialStore, aU as MemoryConsumedCredentialStoreOpts, aV as MemoryProcessedPaymentStore, aW as MemoryX402ExactSettlementStore, aX as MountOpts, aY as OwnerDisplay, aZ as PaidJobCompletion, a_ as PaymentMode, a$ as PlatformReporterOpts, b0 as PostgresProcessedPaymentStore, b1 as PostgresX402ExactSettlementStore, b2 as PriceFiat, b3 as ProcessedPaymentQuerier, b4 as ProcessedPaymentRail, b5 as ProcessedPaymentRecord, b6 as ProcessedPaymentReplayError, b7 as ProcessedPaymentStore, b8 as X402BatchAcceptance, b9 as X402BatchFunding, ba as X402BatchRefusal, bb as X402BatchSettlementServer, bc as X402ExactAcceptance, bd as X402ExactIntentConflictError, be as X402ExactSettlementAttempt, bf as X402ExactSettlementChainEvidence, bg as X402ExactSettlementEffect, bh as X402ExactSettlementEvidenceMissingError, bi as X402ExactSettlementEvidenceReader, bj as X402ExactSettlementIntent, bk as X402ExactSettlementNotReadyError, bl as X402ExactSettlementServer, bm as X402ExactSettlementServerOpts, bn as X402ExactSettlementStatus, bo as X402ExactSettlementStore, bp as X402SettlementChainEvidence, bq as X402SettlementEvidenceReader, br as X402SettlementSubmissionError, bs as X402_BATCH_AUTO_SETTLEMENT, bt as X402_BATCH_MIN_WITHDRAW_DELAY_SECONDS, bu as X402_BATCH_SETTLEMENT_NETWORK, bv as attachCreditMenu, bw as buildCreditMenu, bx as createDVMHost, by as createX402BatchSettlementServer, bz as creditEnvelopeIgnoreFields, bA as drawSettlementRef, bB as extractCreditEnvelope, bC as fundingCommitment, bD as selectPrimaryCredit, bE as signHostingClosure, bF as signHostingControl, bG as stripCreditEnvelope, bH as toCreditView } from '../credit-menu-C-kmf61K.js';
6
6
  import { Context, Hono } from 'hono';
7
7
  import { z } from 'zod';
8
- import { F as FxFetcher } from '../fx-DM7UCzg1.js';
9
- import { c as StreamableJobStore, R as ReceiptIssuingStore, J as JobRecord, d as RequestIdClaim, e as RequestIdClaimResult, f as JobRetentionCursor, O as OutgoingMessage, A as AppendOutgoingOptions, P as PaymentCreditDelta, V as VerifyAndCreditResult, g as JobCounters, b as JobStore } from '../job-store-BVGvAaBG.js';
10
- export { a as JobStatus, h as isStreamableJobStore } from '../job-store-BVGvAaBG.js';
11
- import { C as ContentHoldHistory, a as ContentHoldMutation } from '../content-retention-_Yy3YK4t.js';
12
- export { b as ContentHold, c as ContentHoldError, d as ContentHoldEvent, e as ContentHoldStore, f as ContentHoldsResponse, J as JobContentMetadata, g as baselineContentExpiry, h as contentMetadata, i as isContentHoldStore } from '../content-retention-_Yy3YK4t.js';
8
+ import { F as FxFetcher } from '../fx-hFlF4Cn8.js';
9
+ import { c as StreamableJobStore, R as ReceiptIssuingStore, J as JobRecord, d as RequestIdClaim, e as RequestIdClaimResult, f as JobRetentionCursor, O as OutgoingMessage, A as AppendOutgoingOptions, P as PaymentCreditDelta, V as VerifyAndCreditResult, g as JobCounters, b as JobStore } from '../job-store-DVCATwhU.js';
10
+ export { a as JobStatus, h as isStreamableJobStore } from '../job-store-DVCATwhU.js';
11
+ import { C as ContentHoldHistory, a as ContentHoldMutation } from '../content-retention-BcHNpP2F.js';
12
+ export { b as ContentHold, c as ContentHoldError, d as ContentHoldEvent, e as ContentHoldStore, f as ContentHoldsResponse, J as JobContentMetadata, g as baselineContentExpiry, h as contentMetadata, i as isContentHoldStore } from '../content-retention-BcHNpP2F.js';
13
13
  export { P as PinnedFetch, S as SSRFError, a as SSRFGuardOpts, b as SSRFReason, c as SSRFResolver, d as assertSafeUrl, e as createPinnedFetch } from '../ssrf-dMooihtY.js';
14
14
  import { Env, BlankSchema } from 'hono/types';
15
15
  import 'mppx';
@@ -17,7 +17,7 @@ import '@x402/core/server';
17
17
  import '@x402/evm/batch-settlement/server';
18
18
  import '@x402/core/types';
19
19
  import 'viem';
20
- import '../lightning-backend-CsW_b6C7.js';
20
+ import '../lightning-backend-DXNVlVs9.js';
21
21
  import '@cashu/cashu-ts';
22
22
 
23
23
  /** Default lifetime of a per-call implicit credit: 90 days before the ledger refuses new draws. */
@@ -233,8 +233,12 @@ declare class MemoryCreditLedger implements CreditLedgerLike {
233
233
  creditId: string;
234
234
  fundId: string;
235
235
  }): Promise<FundingRecord | undefined>;
236
+ listDrawFundings(args: {
237
+ creditId: string;
238
+ drawId: string;
239
+ }): Promise<FundingRecord[]>;
236
240
  completeFunding(args: Parameters<CreditLedgerLike["completeFunding"]>[0]): Promise<FundingRecord>;
237
- saveFundingReceipt(args: Parameters<CreditLedgerLike["saveFundingReceipt"]>[0]): Promise<FundingReceipt>;
241
+ saveFundingReceipt(args: Parameters<CreditLedgerLike["saveFundingReceipt"]>[0]): Promise<CreditFundingEvidence>;
238
242
  recordInvoice(args: Parameters<CreditLedgerLike["recordInvoice"]>[0]): Promise<CreditInvoiceRecord>;
239
243
  getInvoice(args: {
240
244
  creditId: string;
@@ -618,4 +622,4 @@ interface WriteOffTempoCloseReportResponse {
618
622
  note: string;
619
623
  }
620
624
 
621
- export { BitcoinDepositLiability, BlockedInvoiceCursor, CREDIT_REQUEST_SCHEMA, ConsumedCredentialStore, ContentHoldHistory, ContentHoldMutation, CreditDrawRefundArgs, CreditDrawRefundResult, CreditInvoiceRecord, CreditLedgerLike, CreditLedgerQuerier, CreditMenu, type CreditRequest, type CreditRouteDeps, CreditSnapshot, DVMAuthScheme, DVMHostOpts, DVMServeResult, DrawRecord, DrawResolution, DrawResult, FundingRecord, GrownDrawResult, IMPLICIT_CREDIT_TTL_MS, type InitLockPool, type InstallAdminContentRoutesOpts, InvoiceReconciliation, InvoiceSettlement, InvoiceWriteOff, JobRecord, JobStore, LightningReceive, MemoryCreditLedger, type PendingImplicitDrawGroup, type PendingImplicitDrawSummary, PostgresJobStore, PostgresKVStore, PostgresReplayStore, type PostgresReplayStoreOpts, REQUEST_ID_FIELD, type ResolvedCashuOpts, type RetryTempoCloseReportResponse, SDK_INIT_ADVISORY_LOCK, SignedRequestDomain, SignedRequestReplayStore, StalePendingDrawCursor, StreamableJobStore, type TempoCloseReportSummary, type TempoCloseReportsResponse, type WriteOffTempoCloseReportResponse, handleCreditRequest, hasInvalidRequestId, installAdminContentRoutes, protocolEnvelopeIgnoreFields, readPendingImplicitDraws, requestIdFromEnvelope, resolveCashuOptsFromEnv, serve, stripProtocolEnvelope, withSdkInitLock };
625
+ export { BitcoinDepositLiability, BlockedInvoiceCursor, CREDIT_REQUEST_SCHEMA, ConsumedCredentialStore, ContentHoldHistory, ContentHoldMutation, CreditDrawRefundArgs, CreditDrawRefundResult, CreditFundingEvidence, CreditInvoiceRecord, CreditLedgerLike, CreditLedgerQuerier, CreditMenu, type CreditRequest, type CreditRouteDeps, CreditSnapshot, DVMAuthScheme, DVMHostOpts, DVMServeResult, DrawRecord, DrawResolution, DrawResult, FundingRecord, GrownDrawResult, IMPLICIT_CREDIT_TTL_MS, type InitLockPool, type InstallAdminContentRoutesOpts, InvoiceReconciliation, InvoiceSettlement, InvoiceWriteOff, JobRecord, JobStore, LightningReceive, MemoryCreditLedger, type PendingImplicitDrawGroup, type PendingImplicitDrawSummary, PostgresJobStore, PostgresKVStore, PostgresReplayStore, type PostgresReplayStoreOpts, REQUEST_ID_FIELD, type ResolvedCashuOpts, type RetryTempoCloseReportResponse, SDK_INIT_ADVISORY_LOCK, SignedRequestDomain, SignedRequestReplayStore, StalePendingDrawCursor, StreamableJobStore, type TempoCloseReportSummary, type TempoCloseReportsResponse, type WriteOffTempoCloseReportResponse, handleCreditRequest, hasInvalidRequestId, installAdminContentRoutes, protocolEnvelopeIgnoreFields, readPendingImplicitDraws, requestIdFromEnvelope, resolveCashuOptsFromEnv, serve, stripProtocolEnvelope, withSdkInitLock };
@@ -82,7 +82,7 @@ import {
82
82
  toCreditView,
83
83
  unknownRouteNotFound,
84
84
  writeOffHostedTempoCloseReport
85
- } from "../chunk-HIQ3CEZ3.js";
85
+ } from "../chunk-JFH34P3M.js";
86
86
  import {
87
87
  MemoryProcessedPaymentStore,
88
88
  PostgresProcessedPaymentStore,
@@ -92,7 +92,7 @@ import "../chunk-ITRSITFP.js";
92
92
  import "../chunk-E7ZBCT5U.js";
93
93
  import {
94
94
  MemoryCreditLedger
95
- } from "../chunk-EQYHHYW4.js";
95
+ } from "../chunk-TKJBUFYY.js";
96
96
  import {
97
97
  PostgresJobStore
98
98
  } from "../chunk-TWKQFIOW.js";
@@ -115,7 +115,7 @@ import {
115
115
  IMPLICIT_CREDIT_TTL_MS,
116
116
  generateEphemeralReceiptKey,
117
117
  receiptPubkeyFromSecret
118
- } from "../chunk-V3WFX65W.js";
118
+ } from "../chunk-5JSPTVIK.js";
119
119
  import {
120
120
  X402_DEFAULT_FACILITATOR,
121
121
  X402_DEFAULT_NETWORK,
@@ -139,13 +139,13 @@ import {
139
139
  PostgresX402ChannelStorage,
140
140
  X402RelaySubmissionLockError,
141
141
  allocateDrawValue
142
- } from "../chunk-Q2X4QYOB.js";
142
+ } from "../chunk-A2YESDQM.js";
143
143
  import "../chunk-YG7G4DPZ.js";
144
144
  import {
145
145
  SDK_INIT_ADVISORY_LOCK,
146
146
  withSdkInitLock
147
147
  } from "../chunk-COYKJRMM.js";
148
- import "../chunk-5H7P3ORL.js";
148
+ import "../chunk-5UC7TOQC.js";
149
149
  import {
150
150
  applyRetryToPool
151
151
  } from "../chunk-EP7OVWI5.js";
@@ -1504,7 +1504,7 @@ ${config.facilitatorAuth?.keyId ?? ""}`;
1504
1504
  sharedPgConsumedStore = consumedStore;
1505
1505
  }
1506
1506
  if (pgPool) {
1507
- const { CreditLedger: CreditLedger2 } = await import("../credit-ledger-L4RAXLY7.js");
1507
+ const { CreditLedger: CreditLedger2 } = await import("../credit-ledger-D3UUR2GW.js");
1508
1508
  const pgLedger = new CreditLedger2(pgPool, tempoSessionStore);
1509
1509
  pendingInits.push(pgLedger.init());
1510
1510
  creditLedger = pgLedger;
@@ -1513,7 +1513,7 @@ ${config.facilitatorAuth?.keyId ?? ""}`;
1513
1513
  pendingInits.push(pgProcessed.init());
1514
1514
  processedPayments = pgProcessed;
1515
1515
  } else {
1516
- const { MemoryCreditLedger: MemoryCreditLedger2 } = await import("../memory-credit-ledger-JKQ34VMH.js");
1516
+ const { MemoryCreditLedger: MemoryCreditLedger2 } = await import("../memory-credit-ledger-SCXQO4HZ.js");
1517
1517
  creditLedger = disposableCashu?.ledger ?? new MemoryCreditLedger2();
1518
1518
  const { MemoryProcessedPaymentStore: MemoryProcessedPaymentStore2 } = await import("../processed-payment-store-GKMAWOM3.js");
1519
1519
  processedPayments = new MemoryProcessedPaymentStore2();