diff --git a/README.md b/README.md index 2c98781..7b19858 100644 --- a/README.md +++ b/README.md @@ -34,17 +34,18 @@ sudo python setup.py install **Get account details** ```python -from sipcentric import API, Partner, Customer +from sipcentric import API, Partner, Customer, ACCOUNTTYPE_BUSINESS api = API(username="myusername", password="mypassword") # Simwood Partners can interact with Sipcentric and create new Customers partner = Partner(api) for customer in partner.customers(): - print(customer.data['name']) + print(customer.data['company']) newcust = Customer(api) -newcust.create(company="Acme Ltd", firstName="Hayes", lastName="Murphy", email="hayes@example.com", - address1="24 Acacia Avenue", city="", postcode="FX5 7HQ", telephone="03069990000") +newcust.create(accountType=ACCOUNTTYPE_BUSINESS, + company="Acme Ltd", firstName="Hayes", lastName="Murphy", email="hayes@example.com", + address1="24 Acacia Avenue", city="Newton", postcode="FX5 7HQ", telephone="03069990000") # if your API credentials are for a Customer account: customer = Customer(api, "me")