summaryrefslogtreecommitdiff
path: root/yarns/lib.py
diff options
context:
space:
mode:
authorLars Wirzenius <liw@liw.fi>2019-03-10 14:20:31 +0200
committerLars Wirzenius <liw@liw.fi>2019-03-10 14:20:31 +0200
commit3a37ad5eff9af642424c519159d74ce9abe7a926 (patch)
tree6ed99f0ca79eabb9bc67ec4bf454a5b282160295 /yarns/lib.py
parenteeff0a63cfb8f72a8479371366aca4c71a483509 (diff)
downloadeffi-reg-3a37ad5eff9af642424c519159d74ce9abe7a926.tar.gz
Add: PUT to effiapi to update member resource
Diffstat (limited to 'yarns/lib.py')
-rw-r--r--yarns/lib.py5
1 files changed, 5 insertions, 0 deletions
diff --git a/yarns/lib.py b/yarns/lib.py
index a776fda..100511e 100644
--- a/yarns/lib.py
+++ b/yarns/lib.py
@@ -96,6 +96,11 @@ class EffiAPI:
body = json.dumps(body)
self.request(requests.post, path, headers, body)
+ def PUT(self, path, headers, body):
+ headers['Content-Type'] = 'application/json'
+ body = json.dumps(body)
+ self.request(requests.put, path, headers, body)
+
def GET(self, path, headers, body):
self.request(requests.get, path, headers, body)