My code seems to work when using an API key from the ORS website but when using a local host with the help of SyntaxByte I get an error that the response format is not supported. What am I doing wrong? Thanks in advance:
File "xxx.py", line 160, in <module>
main()
File "xxx.py", line 153, in main
optimized = requests.get(client.optimization(jobs=jobs, vehicles=vehicles, geometry=True))
File "/Users/ruben/opt/anaconda3/lib/python3.9/site-packages/openrouteservice/client.py", line 299, in wrapper
result = func(*args, **kwargs)
File "/Users/ruben/opt/anaconda3/lib/python3.9/site-packages/openrouteservice/optimization.py", line 97, in optimization
return client.request("/optimization", {}, post_json=params, dry_run=dry_run)
File "/Users/ruben/opt/anaconda3/lib/python3.9/site-packages/openrouteservice/client.py", line 204, in request
result = self._get_body(response)
File "/Users/ruben/opt/anaconda3/lib/python3.9/site-packages/openrouteservice/client.py", line 242, in _get_body
raise exceptions.ApiError(
ApiError: 406 ({'error': {'code': 2007, 'message': 'This response format is not supported'}, 'info': {'engine': {'version': '7.0.1', 'build_date': '2023-03-08T12:06:41Z'}, 'timestamp': 1681554106308}})