Hi All
I am testing out the Get Network Client option under networks - monitor - clients.
The only I can get this to work is if I search ID value which looks to be a system id. I tried IP (I have Track by IP selected), tried MAC address, and Description but all come back with Not Found error. Below is what I have which was cut and paste right from the API page.
import meraki
API_KEY = '<my API>'
dashboard = meraki.DashboardAPI(API_KEY)
network_id = '<my id>'
client_id = '10.204.14.95'
response = dashboard.networks.getNetworkClient(
network_id, client_id
)
print(response)
Here is the output I get
2024-07-29 14:18:31 meraki: INFO > Meraki dashboard API session initialized with these parameters: {'version': '1.46.0', 'api_key': '************************************55b7', 'base_url': 'https://api.meraki.com/api/v1', 'single_request_timeout': 60, 'certificate_path': '', 'requests_proxy': '', 'wait_on_rate_limit': True, 'nginx_429_retry_wait_time': 60, 'action_batch_retry_wait_time': 60, 'network_delete_retry_wait_time': 240, 'retry_4xx_error': False, 'retry_4xx_error_wait_time': 60, 'maximum_retries': 2, 'simulate': False, 'be_geo_id': None, 'caller': None, 'use_iterator_for_get_pages': False}
2024-07-29 14:18:31 meraki: INFO > GET https://api.meraki.com/api/v1/networks/N_755478837491402474/clients/10.204.14.95
2024-07-29 14:18:32 meraki: ERROR > networks, getNetworkClient - 404 Not Found, b'<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtm'
Traceback (most recent call last):
File "/mnt/m2ssd/python/client_find_test.py", line 16, in <module>
response = dashboard.networks.getNetworkClient(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/dist-packages/meraki/api/networks.py", line 473, in getNetworkClient
return self._session.get(metadata, resource)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/dist-packages/meraki/rest_session.py", line 306, in get
response = self.request(metadata, 'GET', url, params=params)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/dist-packages/meraki/rest_session.py", line 300, in request
raise APIError(metadata, response)
meraki.exceptions.APIError: networks, getNetworkClient - 404 Not Found, <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtmplease wait a minute if the key or org was just newly created.
Any thoughts?
Thanks in Advance!