@gvnrdao/dh-sdk 0.0.207 → 0.0.209
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/browser/dist/index.js
CHANGED
|
@@ -1,25 +1,6 @@
|
|
|
1
1
|
// Browser ESM entry point for Diamond Hands SDK
|
|
2
|
-
//
|
|
3
|
-
//
|
|
4
|
-
//
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
// TODO: Re-enable when these modules have proper ES module builds
|
|
8
|
-
// import * as LitOpsModule from "../../lit-ops/dist/index.js";
|
|
9
|
-
// import * as LitActionsModule from "../../lit-actions/dist/index.js";
|
|
10
|
-
// ========================================
|
|
11
|
-
// MAIN SDK EXPORTS
|
|
12
|
-
// ========================================
|
|
13
|
-
// Export main SDK classes (based on actual SDK exports)
|
|
14
|
-
export const DiamondHandsSDK = SDKModule.DiamondHandsSDK;
|
|
15
|
-
// ========================================
|
|
16
|
-
// RE-EXPORT CORE SDK ONLY
|
|
17
|
-
// ========================================
|
|
18
|
-
// Re-export core SDK exports only to avoid conflicts
|
|
19
|
-
// Note: CommonJS module, so we export specific items
|
|
20
|
-
export const { AuthParamsValidation, BPSConversions, BitcoinOperations, CacheManager, ContractManager, DiamondHandsSDK: SDKClass, ErrorCategory, ErrorSeverity, EventHelpers, LoanCreator, LoanQuery, LoanStatus, PaymentType, PositionStatus, SDKError, SatoshisConversions, UCDConversions, WeiConversions, createBitcoinOperations, createCacheManager, createContractManager, createLoanCreator, createLoanQuery, createPKPManager, failure, success, tryCatch, tryCatchAsync, unwrap, unwrapOr, validateSDKConfig, } = SDKModule;
|
|
21
|
-
// ========================================
|
|
22
|
-
// DEFAULT EXPORT
|
|
23
|
-
// ========================================
|
|
24
|
-
// Default export (main SDK class)
|
|
25
|
-
export default SDKModule.DiamondHandsSDK;
|
|
2
|
+
// Static ESM re-exports from the package-root ESM build.
|
|
3
|
+
// Avoids the CJS require() circular reference that esbuild/Vite introduced
|
|
4
|
+
// when the wrapper required ../dist/index.js (the package's own CJS entry).
|
|
5
|
+
export * from '../../dist/index.mjs';
|
|
6
|
+
export { default } from '../../dist/index.mjs';
|
package/dist/index.js
CHANGED
|
@@ -34026,6 +34026,8 @@ var DiamondHandsGraph = class {
|
|
|
34026
34026
|
lastUpdated
|
|
34027
34027
|
pkpId
|
|
34028
34028
|
status
|
|
34029
|
+
ucdMinted
|
|
34030
|
+
ucdPaid
|
|
34029
34031
|
ucdDebt
|
|
34030
34032
|
totalPaid
|
|
34031
34033
|
totalExtensions
|
package/dist/index.mjs
CHANGED
|
@@ -33954,6 +33954,8 @@ var DiamondHandsGraph = class {
|
|
|
33954
33954
|
lastUpdated
|
|
33955
33955
|
pkpId
|
|
33956
33956
|
status
|
|
33957
|
+
ucdMinted
|
|
33958
|
+
ucdPaid
|
|
33957
33959
|
ucdDebt
|
|
33958
33960
|
totalPaid
|
|
33959
33961
|
totalExtensions
|
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
import { Result } from "../types/result";
|
|
15
15
|
import { Satoshis } from "../types/branded/domain-values";
|
|
16
16
|
import { SDKError } from "../utils/error-handler";
|
|
17
|
-
import type { CreateLoanRequest, CreateLoanResult,
|
|
17
|
+
import type { CreateLoanRequest, CreateLoanResult, LoanDataDetail, UCDMintRequest, UCDMintResult, PartialPaymentRequest, PartialPaymentResult, BTCWithdrawalResult, RenewPositionRequest, RenewPositionResult, LiquidationRequest, LiquidationResult, ConfirmBalanceRequest, ConfirmBalanceResult, TermsWithFeesResult } from "../interfaces/chunks/loan-operations.i";
|
|
18
18
|
import type { DiamondHandsSDKConfig } from "../interfaces/chunks/config.i";
|
|
19
19
|
import type { PKPData } from "../interfaces/chunks/pkp-integration.i";
|
|
20
20
|
import { ContractManager } from "./contract/contract-manager.module";
|
|
@@ -417,7 +417,7 @@ export declare class DiamondHandsSDK {
|
|
|
417
417
|
* @param enrichBalance - Whether to enrich with current Bitcoin balance
|
|
418
418
|
* @returns Loan data
|
|
419
419
|
*/
|
|
420
|
-
getLoanByPkpId(pkpId: string, enrichBalance?: boolean): Promise<Result<
|
|
420
|
+
getLoanByPkpId(pkpId: string, enrichBalance?: boolean): Promise<Result<LoanDataDetail | null, SDKError>>;
|
|
421
421
|
/**
|
|
422
422
|
* Get loans for a borrower
|
|
423
423
|
*
|
|
@@ -86,7 +86,7 @@ export declare class LoanQuery {
|
|
|
86
86
|
* @param enrichBalance - Whether to enrich with Bitcoin balance
|
|
87
87
|
* @returns Loan data
|
|
88
88
|
*/
|
|
89
|
-
getLoanByPkpId(pkpId: string, enrichBalance?: boolean): Promise<Result<
|
|
89
|
+
getLoanByPkpId(pkpId: string, enrichBalance?: boolean): Promise<Result<LoanDataDetail | null, SDKError>>;
|
|
90
90
|
/**
|
|
91
91
|
* Get loans with filters and pagination
|
|
92
92
|
*
|
package/package.json
CHANGED