Skip to content

Commit

Permalink
Extracted request wrapper to separated class
Browse files Browse the repository at this point in the history
  • Loading branch information
Jakub Reczko committed Jun 12, 2016
1 parent a8bb70c commit a077fc8
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion voucherify/client.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
TIMEOUT = 30 * 1000


class Client(object):
class VoucherifyRequest(object):
def __init__(self, application_id, client_secret_key):
self.timeout = TIMEOUT
self.headers = {
Expand Down Expand Up @@ -47,6 +47,11 @@ def request(self, path, method='GET', **kwargs):

return result


class Client(VoucherifyRequest):
def __init__(self, *args, **kwargs):
super(Client, self).__init__(*args, **kwargs)

def list(self, query):
path = '/vouchers/'

Expand Down

0 comments on commit a077fc8

Please sign in to comment.