Skip to content

Commit 31ccf3d

Browse files
committed
Added options method
1 parent 2100c8a commit 31ccf3d

1 file changed

Lines changed: 8 additions & 0 deletions

File tree

ox3apiclient/__init__.py

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -341,6 +341,14 @@ def get(self, url):
341341
""""""
342342
res = self.request(self._resolve_url(url), method='GET')
343343
return json.loads(res.read())
344+
def options(self, url):
345+
"""Send a request with HTTP method OPTIONS.
346+
347+
OX3 v2 uses this method for showing help information.
348+
349+
"""
350+
res = self.request(self._resolve_url(url), method='OPTIONS')
351+
return json.loads(res.read())
344352

345353
def put(self, url, data=None):
346354
"""Issue a PUT request to url with the data."""

0 commit comments

Comments
 (0)