Skip to content

Instantly share code, notes, and snippets.

@jeffdeville
Last active February 2, 2023 18:01
Show Gist options
  • Save jeffdeville/a34f6654378c6cd950c4e045cfc73196 to your computer and use it in GitHub Desktop.
Save jeffdeville/a34f6654378c6cd950c4e045cfc73196 to your computer and use it in GitHub Desktop.
from belay.client import PolicyClient
from belay.requests import PolicyPurchaseRequest
from belay.enums import Durations
policy_client = PolicyClient('client_id', 'client_secret', sandbox=True)
policy_client.purchase(
PolicyPurchaseRequest(
sym="AAPL",
qty=5,
expiration= 3 * Durations.month,
price_lock = 150.00
)
)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment