Open HannahMR opened 1 week ago
Hmm I don't see the DB use from that function; could you mention also which other functions you think would be needed / find useful?
Thinking about exposing these via WASM instead of API, since it should be stateless + could be embedded in some app without needing a node.
Background
While it is currently possible to create PSBT swaps with Taproot Assets, this is not easily doable as not all the necessary API calls are available.
Reading through the PSBT swap itest gives an outline of the process and many of the steps are available via the API, key generation, PSBT signing, etc. What is missing is the creation step, an API call for the creation of the vPSBT.
It looks as if the vPSBT creation requires the ForInteractiveSend() function which is not currently exposed via an API.
Is your feature request related to a problem? Please describe.
This issue was discovered when attempting to experiment with PSBT swaps. Walking through the itest example I was unable to find a way to create a vPSBT via API calls.
Describe the solution you'd like
Developers looking to experiment with this feature would benefit greatly from this functionality being exposed via an API call.
Describe alternatives you've considered
Once I realized that the API call for creating vPSBTs was not available I looked at a number of different methods for doing this. I could export the ForInteractiveSend() function and run it in my code base to create the PSBT there, however, it seems that this function relies on other functions, and access to the DB would be needed.
The only other method I found for making this happen is to fork the repo and add custom functionality.