Files
notifications-admin/app/notify_client/complaint_api_client.py
Katie Smith 7a40ad6ac0 Add new methods to Service and Complaint api clients
* Added a new method to the ComplaintApiClient to get the total
complaints by date range from the API.
* Added a new method to the ServiceAPIClient to get the new platform
admin stats data from the API.
2018-06-29 15:31:40 +01:00

15 lines
454 B
Python

from app.notify_client import NotifyAdminAPIClient
class ComplaintApiClient(NotifyAdminAPIClient):
# Fudge assert in the super __init__ so
# we can set those variables later.
def __init__(self):
super().__init__("a" * 73, "b")
def get_all_complaints(self):
return self.get('/complaint')
def get_complaint_count(self, params_dict=None):
return self.get('/complaint/count-by-date-range', params=params_dict)