diff --git a/mackerel/client.py b/mackerel/client.py index 27afca1..4e59f66 100644 --- a/mackerel/client.py +++ b/mackerel/client.py @@ -130,7 +130,7 @@ def get_hosts(self, **kwargs): """Get hosts. :param service: Service name - :param roles: Service role + :param role: Service role :param name: Host name """ uri = '/api/v0/hosts.json' @@ -138,8 +138,8 @@ def get_hosts(self, **kwargs): if kwargs.get('service', None): params['service'] = kwargs.get('service') - if kwargs.get('roles', None): - params['roles'] = kwargs.get('roles') + if kwargs.get('role', None): + params['role'] = kwargs.get('role') if kwargs.get('name', None): params['name'] = kwargs.get('name')