Add docs to exchange API functions#58
Open
perplover wants to merge 1 commit intohyperliquid-dex:masterfrom
Open
Add docs to exchange API functions#58perplover wants to merge 1 commit intohyperliquid-dex:masterfrom
perplover wants to merge 1 commit intohyperliquid-dex:masterfrom
Conversation
traderben
requested changes
Oct 15, 2024
|
|
||
| Note: | ||
| - The scheduled time must be at least 5 seconds after the current time. | ||
| - Once the scheduled time arrives, all open orders will be canceled. |
Contributor
There was a problem hiding this comment.
I found having a separate bullet is confusing. The trigger count is incremented when the scheduled time arrives, not when this action is sent.
Suggested change
| - Once the scheduled time arrives, all open orders will be canceled. | |
| - Once the scheduled time arrives, all open orders will be canceled and a trigger count is incremented. |
| # Deprecated in favor of usd_class_transfer | ||
| def user_spot_transfer(self, usdc: float, to_perp: bool) -> Any: | ||
| usdc = int(round(usdc, 2) * 1e6) | ||
| usdc_rounded_micros = int(round(usdc, 2) * 1e6) |
Contributor
There was a problem hiding this comment.
I'd prefer not making this rename. usdc has 6 decimals so this is the actual amount of usdc and is not rounded. Perhaps the input should have been usd instead of usdc, but renaming it now would be a breaking change
| Args: | ||
| amount (float): The amount of the token to transfer. | ||
| destination (str): The destination address (EVM compatible) for the transfer. | ||
| token (str): The identifier of the token to be transferred (e.g., "BTC", "ETH"). |
Contributor
There was a problem hiding this comment.
These example tokens are not spot tokens. Also the token identifier is a different format
Suggested change
| token (str): The identifier of the token to be transferred (e.g., "BTC", "ETH"). | |
| token (str): The identifier of the token to be transferred (e.g., "PURR:0xc1fb593aeffbeb02f85e0308e9956a90"). |
| Initiate a withdrawal from the Hyperliquid bridge to a specified destination. | ||
|
|
||
| Args: | ||
| amount (float): The amount to withdraw. This should be in the base unit of the asset |
Contributor
There was a problem hiding this comment.
I found this confusing. All withdrawals are in USDC
Suggested change
| amount (float): The amount to withdraw. This should be in the base unit of the asset | |
| amount (float): The amount of USD to withdraw. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
A few changes: