{"id":26735,"library":"assemblyline-ui","title":"Assemblyline API and Socket IO server","description":"Assemblyline 4 - API and Socket IO server. Version 4.7.3.1 is the latest. The project is under active development (pre-1.0), with frequent releases. Part of the Assemblyline suite by the Canadian Centre for Cyber Security.","status":"active","version":"4.7.3.1","language":"python","source_language":"en","source_url":"https://github.com/CybercentreCanada/assemblyline-ui/","tags":["assemblyline","api","socket.io","cybersecurity"],"install":[{"cmd":"pip install assemblyline-ui","lang":"bash","label":"pip install"}],"dependencies":[{"reason":"Core API client and shared models","package":"assemblyline","optional":false},{"reason":"Real-time event streaming","package":"assemblyline-socketio-client","optional":false}],"imports":[{"note":"AssemblylineAPI is in the api submodule","wrong":"from assemblyline_ui import AssemblylineAPI","symbol":"AssemblylineAPI","correct":"from assemblyline_ui.api import AssemblylineAPI"},{"note":"SocketIOServer is in socketio submodule","wrong":"from assemblyline_ui import SocketIOServer","symbol":"SocketIOServer","correct":"from assemblyline_ui.socketio import SocketIOServer"}],"quickstart":{"code":"from assemblyline_ui.api import AssemblylineAPI\nfrom assemblyline.common import forge\n\n# Initialize using a configuration dict\nconfig = forge.get_config()\napi = AssemblylineAPI(config)\n# Example: list submissions\nsubmissions = api.list_submissions()\nprint(submissions)","lang":"python","description":"Initialize the API client using Assemblyline's forge configuration."},"warnings":[{"fix":"Use 'forge.get_config()' without arguments, and set ASSEMBLYLINE_CONFIG environment variable or place config in standard location.","message":"Configuration format changed between v4.0 and v4.1. The 'forge.get_config()' no longer accepts a file path parameter; it reads from environment variables or a default config.","severity":"breaking","affected_versions":"4.0.x -> 4.1.x"},{"fix":"Replace with 'from assemblyline_ui.api import AssemblylineAPI'","message":"The 'from assemblyline_ui import api as api_module' import path is deprecated. Use direct submodule imports.","severity":"deprecated","affected_versions":"<4.7"},{"fix":"Import SocketIOServer only inside async functions or use conditionals.","message":"When running tests, ensure the socket.io server is not initialized unless explicitly needed, as it may block the event loop.","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 assemblyline-ui'","cause":"The package assemblyline-ui is not installed in the current environment.","error":"ModuleNotFoundError: No module named 'assemblyline_ui'"},{"fix":"Use 'from assemblyline_ui.api import AssemblylineAPI' instead of 'import assemblyline_ui'","cause":"Importing the top-level package instead of the submodule.","error":"AttributeError: module 'assemblyline_ui' has no attribute 'api'"}],"ecosystem":"pypi","meta_description":null,"install_score":null,"install_tag":null,"quickstart_score":null,"quickstart_tag":null}