{"id":27129188,"url":"https://github.com/gotz1480/websocket-client","last_synced_at":"2025-04-07T19:22:04.429Z","repository":{"id":125834517,"uuid":"416573051","full_name":"gotz1480/websocket-client","owner":"gotz1480","description":"A simple web client which sends HTTP/1.1 GET requests given a hostname/IPv4 address and port. Implemented using websocket.h library from C/Unix.","archived":false,"fork":false,"pushed_at":"2021-10-13T20:44:07.000Z","size":19,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-04-04T13:13:21.067Z","etag":null,"topics":["c-webclient","websocket-client","websocket-library","websockets"],"latest_commit_sha":null,"homepage":"","language":"C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/gotz1480.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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,"publiccode":null,"codemeta":null}},"created_at":"2021-10-13T03:14:53.000Z","updated_at":"2023-06-21T21:50:13.000Z","dependencies_parsed_at":null,"dependency_job_id":"ebf13866-6cb5-4f85-b5d2-401c2c83fc17","html_url":"https://github.com/gotz1480/websocket-client","commit_stats":null,"previous_names":["gotz1480/websocket-client"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gotz1480%2Fwebsocket-client","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gotz1480%2Fwebsocket-client/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gotz1480%2Fwebsocket-client/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gotz1480%2Fwebsocket-client/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/gotz1480","download_url":"https://codeload.github.com/gotz1480/websocket-client/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247713352,"owners_count":20983695,"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":["c-webclient","websocket-client","websocket-library","websockets"],"created_at":"2025-04-07T19:22:03.753Z","updated_at":"2025-04-07T19:22:04.415Z","avatar_url":"https://github.com/gotz1480.png","language":"C","funding_links":[],"categories":[],"sub_categories":[],"readme":"# websocket-client\nA simple web client which sends HTTP/1.1 GET requests given a hostname/IPv4 address and port and then prints the responses (if more than one, chunked) on screen as well as server data (name, aliases, IPv4 addresses and IPv6 addresses). Implemented using websocket.h library from C/Unix.\n\nCompilation: ``` gcc client.c -o client.o ```\n\nUsage: \n - Using hostname: ``` ./client.o -hostname www.example.com -port 80 ```\n - Using IP address (IPv4): ``` ./client.o -ipaddr 74.6.231.21 -port 80 ```\n\nThe last example sends a GET request to www.yahoo.com.\n\nIn both examples the default port for internet traffic is utilized (PORT 80).\n\nExample of output (www.example.com:80):\n\n```\nMethod: -hostname\nCreating socket ...\nSocket created!\nConnecting to server www.example.com...\nname: www.example.com\nIPv4 address: 93.184.216.34\nIPv6 address: 5db8:d822::\nConnected!\nRequest:\nGET / HTTP/1.1\nHost:www.example.com:80\nConnection: close\n\n\nSending request ...\n---------------------------------------------------------------\n\n\nResponse 0:\nHTTP/1.1 200 OK\nAccept-Ranges: bytes\nAge: 488150\nCache-Control: max-age=604800\nContent-Type: text/html; charset=UTF-8\nDate: Wed, 13 Oct 2021 03:21:56 GMT\nEtag: \"3147526947\"\nExpires: Wed, 20 Oct 2021 03:21:56 GMT\nLast-Modified: Thu, 17 Oct 2019 07:18:26 GMT\nServer: ECS (agb/A445)\nVary: Accept-Encoding\nX-Cache: HIT\nContent-Length: 1256\nConnection: close\n\n\u003c!doctype html\u003e\n\u003chtml\u003e\n\u003chead\u003e\n    \u003ctitle\u003eExample Domain\u003c/title\u003e\n\n    \u003cmeta charset=\"utf-8\" /\u003e\n    \u003cmeta http-equiv=\"Content-type\" content=\"text/html; charset=utf-8\" /\u003e\n    \u003cmeta name=\"viewport\" content=\"width=device-width, initial-scale=1\" /\u003e\n    \u003cstyle type=\"text/css\"\u003e\n    body {\n        background-color: #f0f0f2;\n        margin: 0;\n        padding: 0;\n        font-family: -apple-system, system-ui, BlinkMacSystemFont, \"Segoe UI\", \"Open Sans\", \"Helvetica Neue\", Helvetica, Arial, sans-serif;\n        \n    }\n    div {\n        width: 600px;\n        margin: 5em auto;\n        padding: 2em;\n        background-color: #fdfdff;\n        border-radius: 0.5em;\n        box-shadow: 2px 3px 7px 2px rgba(0,0,0,0.02);\n    }\n    a:link, a:visited {\n        color: #38488f;\n        text-decoration: none;\n    }\n    @media (max-width: 700px) {\n        div {\n            margin: 0 auto;\n            width: auto;\n        }\n    }\n    \u003c/style\u003e    \n\u003c/head\u003e\n\n\u003cbody\u003e\n\u003cdiv\u003e\n    \u003ch1\u003eExample Domain\u003c/h1\u003e\n    \u003cp\u003eThis domain is for use in illustrative examples in documents. You may use this\n    domai\n\nResponse length: 1448\n---------------------------------------------------------------\n\n\nResponse 1:\nn in literature without prior coordination or asking for permission.\u003c/p\u003e\n    \u003cp\u003e\u003ca href=\"https://www.iana.org/domains/example\"\u003eMore information...\u003c/a\u003e\u003c/p\u003e\n\u003c/div\u003e\n\u003c/body\u003e\n\u003c/html\u003e\n\n\nResponse length: 178\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgotz1480%2Fwebsocket-client","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgotz1480%2Fwebsocket-client","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgotz1480%2Fwebsocket-client/lists"}