defi.go 743 B

12345678910111213141516171819202122
  1. package v1
  2. import (
  3. "github.com/gogf/gf/v2/frame/g"
  4. )
  5. type SupportReq struct {
  6. g.Meta `path:"/supprot" tags:"Support" method:"get" summary:"Get a list of all supported networks"`
  7. }
  8. type PriceReq struct {
  9. g.Meta `path:"/price" tags:"Price" method:"get" summary:"Get price update of a token."`
  10. Address string ` v:"required" json:"address" dc:"代币地址"`
  11. Chain string ` v:"required" json:"chain" dc:"链名"`
  12. CheckLiquidity float64 ` json:"check_liquidity" dc:"流动性验证"`
  13. IncludeLiquidity bool ` json:"include_liquidity" dc:"是否返回流动数据" `
  14. }
  15. type CommonRes struct {
  16. Success bool `json:"success" dc:"是否成功"`
  17. Data interface{} `json:"data" dc:"数据"`
  18. }