File tree Expand file tree Collapse file tree 1 file changed +14
-8
lines changed Expand file tree Collapse file tree 1 file changed +14
-8
lines changed Original file line number Diff line number Diff line change @@ -7,23 +7,29 @@ export interface SwapLiquidInterface {
7
7
}
8
8
9
9
const swapLiquid : SwapLiquidInterface = {
10
- swap : ( )
11
- . then ( ( ) => {
10
+ swap : ( ) => {
11
+ return new Promise ( ( resolve , reject ) => {
12
+ // Perform swap operation here
13
+ // For example: breezSwapLiquid.performSwap()
14
+ // If successful, call resolve()
15
+ // If error occurs, call reject(error)
16
+ } )
17
+ . then ( ( ) => {
12
18
console . log ( "Swap successful" ) ;
13
19
} )
14
- . catch ( ( error ) => {
20
+ . catch ( ( error : any ) => {
15
21
console . error ( "Swap error:" , error ) ;
16
- } ) ,
17
- swapLiquid : breezSwapLiquid ,
22
+ } ) ;
23
+ } ,
24
+ swapLiquid : BreezSwapLiquid ,
18
25
} ;
19
26
20
- const RefundableSwap = {
27
+ export const RefundableSwap = {
21
28
swapLiquid,
22
29
} ;
23
-
24
30
// Initialize the SDK instance
25
31
breezSwapLiquid . init ( {
26
- apiKey : "YOUR_API_KEY" ,
32
+ apiKey . env : "YOUR_API_KEY" ,
27
33
apiUrl : "https://api.breez.technology/v1" ,
28
34
websocketUrl : "wss://api.breez.technology/v1" ,
29
35
network : "liquid" ,
You can’t perform that action at this time.
0 commit comments