{"id":20770647,"url":"https://github.com/ably/echo.websocket.org","last_synced_at":"2025-04-30T13:52:33.746Z","repository":{"id":209908347,"uuid":"725239755","full_name":"ably/echo.websocket.org","owner":"ably","description":"WebSocket echo server for the community","archived":false,"fork":false,"pushed_at":"2024-04-19T12:29:22.000Z","size":5659,"stargazers_count":5,"open_issues_count":1,"forks_count":1,"subscribers_count":5,"default_branch":"main","last_synced_at":"2025-03-30T16:46:27.394Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"https://echo-websocket.fly.dev/","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ably.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null}},"created_at":"2023-11-29T18:19:54.000Z","updated_at":"2024-12-01T17:09:45.000Z","dependencies_parsed_at":"2023-12-21T21:38:47.440Z","dependency_job_id":"e2470c44-5d74-4006-a5b3-dd94fe7d4731","html_url":"https://github.com/ably/echo.websocket.org","commit_stats":null,"previous_names":["ably/echo.websocket.org"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ably%2Fecho.websocket.org","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ably%2Fecho.websocket.org/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ably%2Fecho.websocket.org/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ably%2Fecho.websocket.org/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ably","download_url":"https://codeload.github.com/ably/echo.websocket.org/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":251714939,"owners_count":21631806,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-17T12:11:05.525Z","updated_at":"2025-04-30T13:52:33.701Z","avatar_url":"https://github.com/ably.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Echo Server\n\nThis is a very simple HTTP echo server with support for websockets and server-sent\nevents (SSE), available at https://echo-websocket.fly.dev/\n\nThe server is designed for testing HTTP proxies and clients. It echoes\ninformation about HTTP request headers and bodies back to the client.\n\n## Behavior\n\n- Any messages sent from a websocket client are echoed as a websocket message.\n- Visit `/.ws` in a browser for a basic UI to connect and send websocket messages.\n- Request `/.sse` to receive the echo response via server-sent events.\n- Request any other URL to receive the echo response in plain text.\n\n## Configuration\n\n### Port\n\nThe `PORT` environment variable sets the server port, which defaults to `8080`.\n\n### Logging\n\nSet the `LOG_HTTP_HEADERS` environment variable to print request headers to\n`STDOUT`. Additionally, set the `LOG_HTTP_BODY` environment variable to print\nentire request bodies.\n\n### Server Hostname\n\nSet the `SEND_SERVER_HOSTNAME` environment variable to `false` to prevent the\nserver from responding with its hostname before echoing the request. The client\nmay send the `X-Send-Server-Hostname` request header to `true` or `false` to\noverride this server-wide setting on a per-request basis.\n\n### Arbitrary Headers\n\nSet the `SEND_HEADER_\u003cheader-name\u003e` variable to send arbitrary additional\nheaders in the response. Underscores in the variable name are converted to\nhyphens in the header. For example, the following environment variables can be\nused to disable CORS:\n\n```bash\nSEND_HEADER_ACCESS_CONTROL_ALLOW_ORIGIN=\"*\"\nSEND_HEADER_ACCESS_CONTROL_ALLOW_METHODS=\"*\"\nSEND_HEADER_ACCESS_CONTROL_ALLOW_HEADERS=\"*\"\n```\n\n## Running the server\n\nThe examples below show a few different ways of running the server with the HTTP\nserver bound to a custom TCP port of `10000`.\n\n### Running locally\n\n```\ngo get -u github.com/jmalloc/echo-server/...\nPORT=10000 echo-server\n```\n\n### Running under Docker\n\nTo run the latest version as a container:\n\n```\ndocker run --detach -p 10000:8080 jmalloc/echo-server\n```\n\nOr, as a swarm service:\n\n```\ndocker service create --publish 10000:8080 jmalloc/echo-server\n```\n\nThe docker container can be built locally with:\n\n```\nmake docker\n```\n\n## License\n\nThis repository is a fork of https://github.com/jmalloc/echo-server, and the license \nremains unchanged, see [LICENSE](./LICENSE)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fably%2Fecho.websocket.org","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fably%2Fecho.websocket.org","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fably%2Fecho.websocket.org/lists"}