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

Add limit price parameter for stop loss orders #451

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

benibienz
Copy link

Currently, when you create an order with place_stop_order() you create a stop limit order where the limit price is equal to the stop price.

This PR adds an optional argument limit_price to place_stop_order(), allowing the user to specify the limit as well as the stop price.

Note that our limit_price argument is equivalent to the API parameter price, whereas our price argument maps to the API parameter stop_price. This is a little confusing but I wanted to leave the default price arg of the function unchanged to maintain backwards compatibility.

@mabergerx
Copy link

This would be nice to have in the live version!

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.

2 participants