Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

support /fapi/v3/positionRisk #644

Merged
merged 1 commit into from
Dec 5, 2024
Merged

Conversation

xyq-c-cpp
Copy link
Collaborator

  1. support /fapi/v3/positionRisk, close Request upgrade NewGetPositionRiskService V2 => V3 #602

Comment on lines +528 to +531
func (c *Client) NewGetPositionRiskV2Service() *GetPositionRiskV2Service {
return &GetPositionRiskV2Service{c: c}
}

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there any reason to keep this V2 service? In my opinion, we only need the latest version of each service.

Copy link
Collaborator Author

@xyq-c-cpp xyq-c-cpp Dec 5, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Binance still provides this interface, so I have kept it. Of course, I can also keep only the V3 version @adshao

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Binance still provides this interface, so I have kept it. Of course, I can also keep only the V3 version @adshao

OK, that's fine, we can keep it as long as binance provides both v2/v3 interfaces.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@xyq-c-cpp @adshao
The second version should definitely be kept, as it allows you to view the leverage and margin type for each position at once in one query, while in version 3 you can't do that - you will have to make a query /fapi/v1/symbolConfig for each open position to view the current leverage, which will require much more queries and will use up the rate limit much faster.

@adshao adshao merged commit 6d882fc into ccxt:master Dec 5, 2024
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Request upgrade NewGetPositionRiskService V2 => V3
3 participants