Description
Docker container management methods return 404 errors because the client uses different endpoint paths than the server.
Error Example
404 Not Found
url='http://hummingbot-api:8000/docker/container/{container_name}/stop'
Root Cause
Client and server use inconsistent path formats:
| Method |
Client Path |
Server Endpoint |
stop_container |
/docker/container/{name}/stop |
/docker/stop-container/{name} |
start_container |
/docker/container/{name}/start |
/docker/start-container/{name} |
remove_container |
/docker/container/{name} |
/docker/remove-container/{name} |
Affected Code
File: hummingbot_api_client/routers/docker.py (lines 37-48)
# Current implementation (incorrect)
async def stop_container(self, container_name: str) -> Dict[str, Any]:
return await self._post(f"/docker/container/{container_name}/stop")
# Should be
async def stop_container(self, container_name: str) -> Dict[str, Any]:
return await self._post(f"/docker/stop-container/{container_name}")
Similar changes needed for start_container and remove_container methods.
Reference
Server endpoint definition: https://github.com/hummingbot/hummingbot-api/blob/main/routers/docker.py
Willing to Submit PR
I'm happy to submit a PR to fix this issue if needed.
Description
Docker container management methods return 404 errors because the client uses different endpoint paths than the server.
Error Example
Root Cause
Client and server use inconsistent path formats:
stop_container/docker/container/{name}/stop/docker/stop-container/{name}start_container/docker/container/{name}/start/docker/start-container/{name}remove_container/docker/container/{name}/docker/remove-container/{name}Affected Code
File:
hummingbot_api_client/routers/docker.py(lines 37-48)Similar changes needed for
start_containerandremove_containermethods.Reference
Server endpoint definition: https://github.com/hummingbot/hummingbot-api/blob/main/routers/docker.py
Willing to Submit PR
I'm happy to submit a PR to fix this issue if needed.