add pool swap endpoints

This commit is contained in:
Carlosokumu 2025-03-19 12:07:11 +03:00
parent 720fa94b56
commit 4444ac0255
Signed by: carlos
GPG Key ID: 7BD6BC8160A5C953

View File

@ -21,6 +21,7 @@ const (
poolSwapPrefix = "/api/v2/pool/swap" poolSwapPrefix = "/api/v2/pool/swap"
topPoolsPrefix = "/api/v1/pool/top" topPoolsPrefix = "/api/v1/pool/top"
retrievePoolDetailsPrefix = "/api/v1/pool/reverse" retrievePoolDetailsPrefix = "/api/v1/pool/reverse"
poolSwappableVouchersPrefix = "/api/v1/pool"
) )
var ( var (
@ -44,6 +45,7 @@ var (
PoolSwapURL string PoolSwapURL string
TopPoolsURL string TopPoolsURL string
RetrievePoolDetailsURL string RetrievePoolDetailsURL string
PoolSwappableVouchersURL string
) )
func setBase() error { func setBase() error {
@ -84,6 +86,7 @@ func LoadConfig() error {
PoolSwapURL, _ = url.JoinPath(custodialURLBase, poolSwapPrefix) PoolSwapURL, _ = url.JoinPath(custodialURLBase, poolSwapPrefix)
TopPoolsURL, _ = url.JoinPath(dataURLBase, topPoolsPrefix) TopPoolsURL, _ = url.JoinPath(dataURLBase, topPoolsPrefix)
RetrievePoolDetailsURL, _ = url.JoinPath(dataURLBase, retrievePoolDetailsPrefix) RetrievePoolDetailsURL, _ = url.JoinPath(dataURLBase, retrievePoolDetailsPrefix)
PoolSwappableVouchersURL, _ = url.JoinPath(dataURLBase, poolSwappableVouchersPrefix)
return nil return nil
} }