package rest import ( store "custodial/pkg/store" trc "custodial/pkg/tron" gin "github.com/gin-gonic/gin" ) // TLrJqNptmYujFBj6UkQ49ARjdEU8zK6GzB type ErrorResponse struct { Error string `json:"error"` } func TronRestV1(r *gin.RouterGroup) { trc.InitMasterFromPrivateSettings() store.Init() var node trc.TronNode _, err := node.Init() if err != nil { panic(err) } r.POST("/create-account", TronCreateAccountV1) r.POST("/address-balance", TronAddressBalanceV1) r.POST("/account-balance", TronAccountBalanceV1) r.POST("/withdraw-usdt", TronWithdrawUsdtV1) r.POST("/withdraw-trx", TronWithdrawTrxV1) r.POST("/approve-usdt-spender", TronApproveUsdtSpenderV1) r.POST("/approve-usdt-contract", TronApproveUsdtContractV1) r.POST("/withdraw-usdt-by-spender", TronWithdrawUsdtBySpenderV1) r.POST("/withdraw-usdt-by-contract", TronWithdrawUsdtByContractV1) r.POST("/recharge-trx-by-spender", TronRechargeTrxBySpenderV1) r.POST("/approve-usdt-custody", TronApproveUsdtCustodyV1) r.POST("/tx-info", TronTransactionInfoV1) }