Moved example to separate file
The example has been moved to its own file for better organization.
Added BuyExample() and SellExample() functions
New functions have been added to be used by other examples, simplifying code and enabling greater reusability.
Removed unnecessary code related to btcec and elementsutil
This simplifies the example by not requiring keypairs, signatures, etc.
Implemented explorerSvc for better abstraction
Now using an interface, making it easier to switch service providers if needed.
Created utils.go for additional utility functions
Functions for initializing services, getting test coins, and working with tdexv2 API calls are now defined in this new file.
Removed trade package and added end-to-end test examples
Improves testing capabilities by incorporating test examples from tdex-daemon/cmd/tdexd.
Updated market precision and trading fees
Adjusted market precision for regtest network and set trading fees for the market.
Replaced static price with price feeder
Uses a price feeder to open the market instead of setting a static price manually. Aims to restore price feed support for the v2 protocol in the future.
This fixes the integration test for the
v1
version of the daemon.It also refactors the buy/sell trading example scripts so that they can be used within the e2e test and standalone.