From 6aa28b0897f3c90785355d28a8d51ee6a942ec80 Mon Sep 17 00:00:00 2001 From: Geoff Taylor Date: Fri, 15 Oct 2021 14:34:32 +0100 Subject: [PATCH] Added POST_ONLY_SLIDE order type. --- mango/orders.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/mango/orders.py b/mango/orders.py index c1565d2..b8037a4 100644 --- a/mango/orders.py +++ b/mango/orders.py @@ -66,6 +66,7 @@ class OrderType(enum.Enum): LIMIT = "LIMIT" IOC = "IOC" POST_ONLY = "POST_ONLY" + POST_ONLY_SLIDE = "POST_ONLY_SLIDE" @staticmethod def from_value(value: Decimal) -> "OrderType": @@ -83,6 +84,9 @@ class OrderType(enum.Enum): return pyserum.enums.OrderType.IOC elif self == OrderType.POST_ONLY: return pyserum.enums.OrderType.POST_ONLY + elif self == OrderType.POST_ONLY_SLIDE: + # Best we can do in this situation + return pyserum.enums.OrderType.POST_ONLY else: return pyserum.enums.OrderType.LIMIT