diff --git a/python/opendht.pyx b/python/opendht.pyx
index b251197d083a8ff0376833d9a95c6bacb752b71d..e9170bd17df45316e620d9cc808fec69703c693b 100644
--- a/python/opendht.pyx
+++ b/python/opendht.pyx
@@ -636,6 +636,10 @@ cdef class DhtRunner(_WithID):
                 while pending > 0:
                     lock.wait()
             return ok
+
+    def cancelPut(self, InfoHash key, Value val):
+        self.thisptr.get().cancelPut(key._infohash, val._value)
+
     def listen(self, InfoHash key, value_cb):
         t = ListenToken()
         t._h = key._infohash
diff --git a/python/opendht_cpp.pxd b/python/opendht_cpp.pxd
index 0a5b88a6bcb62fda83baf0f9948bf7f2ae4ac9c7..e07084a1fc627871ab27022d415c34f9aeb0fbc8 100644
--- a/python/opendht_cpp.pxd
+++ b/python/opendht_cpp.pxd
@@ -267,6 +267,7 @@ cdef extern from "opendht/dhtrunner.h" namespace "dht":
         string getSearchesLog(sa_family_t af) const
         void get(InfoHash key, GetCallback get_cb, DoneCallback done_cb, nullptr_t f, Where w)
         void put(InfoHash key, shared_ptr[Value] val, DoneCallback done_cb, time_point created, bool permanent)
+        void cancelPut(InfoHash key, shared_ptr[Value] val)
         ListenToken listen(InfoHash key, ValueCallback get_cb)
         void cancelListen(InfoHash key, SharedListenToken token)
         vector[unsigned] getNodeMessageStats(bool i)