mirror of
https://github.com/aljazceru/ark.git
synced 2025-12-17 12:14:21 +01:00
* fix and test cheating scenario (malicious double spend) * test and fix async vtxo cheating cases * add replace statement in go.mod * Update server/internal/core/application/covenantless.go Co-authored-by: Pietralberto Mazza <18440657+altafan@users.noreply.github.com> Signed-off-by: Louis Singer <41042567+louisinger@users.noreply.github.com> * Update server/internal/infrastructure/wallet/btc-embedded/psbt.go Co-authored-by: Pietralberto Mazza <18440657+altafan@users.noreply.github.com> Signed-off-by: Louis Singer <41042567+louisinger@users.noreply.github.com> * Update server/test/e2e/covenant/e2e_test.go Co-authored-by: Pietralberto Mazza <18440657+altafan@users.noreply.github.com> Signed-off-by: Louis Singer <41042567+louisinger@users.noreply.github.com> * Update server/test/e2e/covenantless/e2e_test.go Co-authored-by: Pietralberto Mazza <18440657+altafan@users.noreply.github.com> Signed-off-by: Louis Singer <41042567+louisinger@users.noreply.github.com> * Update server/test/e2e/covenantless/e2e_test.go Co-authored-by: Pietralberto Mazza <18440657+altafan@users.noreply.github.com> Signed-off-by: Louis Singer <41042567+louisinger@users.noreply.github.com> * remove unused * [btc-embedded] fix GetNotificationChannel * [tx-builder] fix redeem transaction fee estimator * close grpc client in tests * [application] rework listentoscannerNotification * [application][covenant] fix getConnectorAmount * [tx-builder][covenant] get connector amount from wallet * e2e test sleep time * [liquid-standalone] ListConnectorUtxos: filter by script client side * fix Makefile integrationtest * do not use cache in integration tests * use VtxoKey as argument of findForfeitTxBitcoin * wrap adversarial test in t.Run * increaste test timeout * CI: setup go 1.23.1 * CI: revert go version * add replace in server/go.mod * Update server/internal/core/application/covenant.go Co-authored-by: Pietralberto Mazza <18440657+altafan@users.noreply.github.com> Signed-off-by: Louis Singer <41042567+louisinger@users.noreply.github.com> * remove replace * readd replace statement * fixes * go work sync * fix CI --------- Signed-off-by: Louis Singer <41042567+louisinger@users.noreply.github.com> Co-authored-by: Pietralberto Mazza <18440657+altafan@users.noreply.github.com>
40 lines
1.4 KiB
Go
40 lines
1.4 KiB
Go
package arksdk
|
|
|
|
import (
|
|
"context"
|
|
|
|
"github.com/ark-network/ark/pkg/client-sdk/client"
|
|
"github.com/ark-network/ark/pkg/client-sdk/store"
|
|
)
|
|
|
|
type ArkClient interface {
|
|
GetConfigData(ctx context.Context) (*store.StoreData, error)
|
|
Init(ctx context.Context, args InitArgs) error
|
|
InitWithWallet(ctx context.Context, args InitWithWalletArgs) error
|
|
IsLocked(ctx context.Context) bool
|
|
Unlock(ctx context.Context, password string) error
|
|
Lock(ctx context.Context, password string) error
|
|
Balance(ctx context.Context, computeExpiryDetails bool) (*Balance, error)
|
|
Receive(ctx context.Context) (offchainAddr, boardingAddr string, err error)
|
|
SendOnChain(ctx context.Context, receivers []Receiver) (string, error)
|
|
SendOffChain(
|
|
ctx context.Context, withExpiryCoinselect bool, receivers []Receiver,
|
|
) (string, error)
|
|
UnilateralRedeem(ctx context.Context) error
|
|
CollaborativeRedeem(
|
|
ctx context.Context, addr string, amount uint64, withExpiryCoinselect bool,
|
|
) (string, error)
|
|
SendAsync(ctx context.Context, withExpiryCoinselect bool, receivers []Receiver) (string, error)
|
|
Claim(ctx context.Context) (string, error)
|
|
ListVtxos(ctx context.Context) (spendable, spent []client.Vtxo, err error)
|
|
GetTransactionHistory(ctx context.Context) ([]Transaction, error)
|
|
Dump(ctx context.Context) (seed string, err error)
|
|
}
|
|
|
|
type Receiver interface {
|
|
To() string
|
|
Amount() uint64
|
|
|
|
IsOnchain() bool
|
|
}
|