Monitor events with WebSocket
This is a websocket api, it supports to watch start
and stop
event of container(s).
The entrypoint of the websocket api is wss://${REGION}.hyper.sh:443/events/ws
. In addition, it's same as other apis.
As a reference, here is an example websocket client (written by golang)
The websocket connection will be closed from the server side if:
Server restart for maintaining
Connection opened for a long time (exceed 24 hours by default)
Error occured.
So the client should handle the close and reconnect if needed.
GET /events/ws
Example request:
Example response:
Example request, filter by container:
Example request, filter by image:
Example request, filter by event:
Example request, filter by label:
Example request, compound filter:
Query Parameters:
filters – A json encoded value of the filters (a map[string][]string) to process on the event list. Available filters:
container=; – container to filter
event=; – event to filter, valid value : start|stop
image=; – image to filter
label=; – container label to filter
Status Codes:
101 – switching protocols
400 - bad request parameter
429 - too many requests
500 – server error
Last updated