{"id":79465,"library":"sinatra-websocket","title":"Sinatra WebSocket","description":"Upgrades any Sinatra request to a WebSocket connection.","status":"active","version":"0.3.1","language":"ruby","source_language":null,"source_url":"https://github.com/simulacre/sinatra-websocket","tags":["sinatra","websocket","real-time","http"],"install":[{"cmd":"gem install sinatra-websocket","lang":"bash","label":"gem install"},{"cmd":"# Gemfile\ngem 'sinatra-websocket', '~> 0.3.1'","lang":"ruby","label":"Gemfile"}],"dependencies":[],"imports":[{"symbol":"Sinatra::WebSocket","correct":"require 'sinatra/websocket'"}],"quickstart":{"code":"require 'sinatra/websocket'\n\nget '/chat' do\n  if request.websocket?\n    request.websocket do |ws|\n      ws.on_message do |msg|\n        ws.send \"Echo: #{msg}\"\n      end\n    end\n  end\nend","lang":"ruby","description":"Handle WebSocket connections in Sinatra."},"warnings":[{"fix":"Use a server like Thin: `gem install thin` and run with `thin start`.","message":"Requires a WebSocket-capable server (e.g., Thin or Puma with support).","severity":"gotcha","affected_versions":">= 0"}],"env_vars":null,"search_vec":"'connect':10 'http':16 'real':14 'real-tim':13 'request':6 'sinatra':1,5,11 'time':15 'upgrad':3 'websocket':2,9,12","created_at":"2026-06-18T04:51:41.692855+00:00","updated_at":"2026-06-18T04:51:41.692855+00:00","problems":[],"ecosystem":"rubygems","meta_description":null,"install_score":null,"quickstart_score":null,"quickstart_tag":null,"pypi_latest":null,"cli_name":null,"cli_version":null,"type":"library","homepage":"http://github.com/simulacre/sinatra-websocket","github":"https://github.com/simulacre/sinatra-websocket","docs":"http://www.rubydoc.info/gems/sinatra-websocket/","changelog":null,"pypi":null,"npm":null,"openapi_spec":null,"status_page":null,"smithery":null,"categories":["web-framework"],"base_url":null,"auth_type":null,"provenance":{"verified_status":null,"verified_at":null,"last_verified":"2026-06-18","next_check":"2026-12-15","install_tag":null}}