{"id":26929,"library":"elastic-agent-client","title":"Elastic Agent Client","description":"A Python implementation of an Elastic Agent Client. Currently at version 0.0.1.dev2 (development release). Release cadence is unknown as the project is in early development. Requires Python >=3.10.","status":"active","version":"0.0.1.dev2","language":"python","source_language":"en","source_url":"https://github.com/elastic/elastic-agent-client","tags":["elastic","agent","client","pre-release"],"install":[{"cmd":"pip install elastic-agent-client","lang":"bash","label":"Install via pip"}],"dependencies":[],"imports":[{"note":"The correct package uses underscores in the import name.","wrong":"from elasticagentclient import ElasticAgentClient","symbol":"ElasticAgentClient","correct":"from elastic_agent_client import ElasticAgentClient"}],"quickstart":{"code":"from elastic_agent_client import ElasticAgentClient\n\nclient = ElasticAgentClient(\n    url=os.environ.get('ELASTIC_AGENT_URL', 'http://localhost:8220'),\n    api_key=os.environ.get('ELASTIC_AGENT_API_KEY', '')\n)\n# Example: check health\nhealth = client.health()\nprint(health)","lang":"python","description":"Initialize the client with URL and API key from environment variables, then call health()."},"warnings":[{"fix":"Pin to a specific version and monitor for changes.","message":"The package is in early development (0.0.1.dev2). APIs are unstable and may change without notice.","severity":"gotcha","affected_versions":"<1.0.0"},{"fix":"Use 'from elastic_agent_client import ...'","message":"The import path uses underscores: 'elastic_agent_client', not hyphens or no underscores.","severity":"gotcha","affected_versions":"all"},{"fix":"Set ELASTIC_AGENT_API_KEY or pass api_key parameter.","message":"No authentication is set by default; you must provide an API key or token via environment variable or constructor argument.","severity":"gotcha","affected_versions":"all"}],"env_vars":null,"last_verified":"2026-04-27T00:00:00.000Z","next_check":"2026-07-26T00:00:00.000Z","problems":[{"fix":"Install with 'pip install elastic-agent-client' and import as 'from elastic_agent_client import ...'","cause":"Package not installed or wrong import name.","error":"ModuleNotFoundError: No module named 'elastic_agent_client'"},{"fix":"Check ELASTIC_AGENT_URL environment variable or the url parameter. Ensure the agent is reachable.","cause":"Incorrect URL or network issue.","error":"elastic_agent_client.exceptions.ConnectionError: Failed to connect to Elastic Agent"}],"ecosystem":"pypi","meta_description":null,"install_score":null,"install_tag":null,"quickstart_score":null,"quickstart_tag":null}