GithubHelp home page GithubHelp logo

USDT Derivatives balance empty about bybit HOT 5 CLOSED

hirokisan avatar hirokisan commented on September 26, 2024
USDT Derivatives balance empty

from bybit.

Comments (5)

Nitradamus avatar Nitradamus commented on September 26, 2024 1

Ah, it seems my key expired just that day. Thanks a lot :)

I am trying to get my wallet balance and unrealised PNL from the result, but it seems I can't query it directly from the res.Result. Is there any way I can access these? like res.Equity, res.UnrealisedPnl

Thanks again :)

from bybit.

Nitradamus avatar Nitradamus commented on September 26, 2024 1

Thanks alot for the instructions, all is working fine now. Thanks again for this module!

from bybit.

hirokisan avatar hirokisan commented on September 26, 2024

@Nitradamus

Thanks for your comment.

Your API key may have expired, please check it on the admin page.

from bybit.

hirokisan avatar hirokisan commented on September 26, 2024

Otherwise, I think you can find other reason inside CommonResponse like below

fmt.Println(res.CommonResponse)

bybit/service.go

Lines 4 to 13 in b119d59

type CommonResponse struct {
RetCode int `json:"ret_code"`
RetMsg string `json:"ret_msg"`
ExtCode string `json:"ext_code"`
ExtInfo string `json:"ext_info"`
TimeNow string `json:"time_now"`
RateLimitStatus int `json:"rate_limit_status"`
RateLimitResetMs int `json:"rate_limit_reset_ms"`
RateLimit int `json:"rate_limit"`
}

from bybit.

hirokisan avatar hirokisan commented on September 26, 2024

You can access these like below

res.Result.Balance[bybit.CoinUSDT].Equity
res.Result.Balance[bybit.CoinUSDT].UnrealisedPnl

from bybit.

Related Issues (18)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.