Interesting. I got it reading and writing over https and websockets, now, but the stream opens and then immediately closes.
This is a browser app, but will run on the phone as a PWA and the desktop as an Electron app or similar, so wanted to live-stream a text feed on the landing page (so that it looks alive and everyone can see that the relay feed is active) and live-notifications and etc. Idea is that, if they install Realy they get that over the more-efficient SSE, and it defaults to websockets, otherwise. I pause websocket-streaming, in low-bandwidth, but keep the sse open, if there's enough network to keep it moving.
This is what my test delivers, so far. The SSE is alive and responding, but it closes quickly.
π Testing Realy Relay Complete Interface Suite
π Target: localhost:3334
π Authentication: Available
π Testing HTTP REST Interface...
β
Event count endpoint working
π Event count: 101
β
Event IDs endpoint working
π Event IDs response: [{"s":1000,"i":"2c765e27f763d9dd5934cca0d215f84207a88228e14dad59cca75788250b103f"},{"s":1001,"i":"73...
π Testing WebSocket Interface...
β
WebSocket connected
π€ Sending REQ: ["REQ","test1",{"kinds":[1],"limit":10}]
β° WebSocket test timeout - but connection was established
π Streaming SSE and publishing events using worker threads...
π€ Will publish 5 events during the stream...
β
Generated NIP-98 authentication token
β
WebSocket connection closed normally
β
Decoded nsec1 format to hex
β
Published pre-SSE event #1: 42cbc57414ec7b4e...
β
Published pre-SSE event #2: 32d18392ca0b05be...
β
SSE connection established, status: 200
π SSE stream ended. Total events received: 0
π Creating event #1...
β
Published event #1: fe8aaebcb4fa9368...
π Creating event #2...
β
Published event #2: 12e3e27aadafcf17...
π Creating event #3...
β
Published event #3: 05b42acb60157cc1...
π Creating event #4...
β
Published event #4: 55477815fd5e0a9d...
π Creating event #5...
β
Published event #5: 9e9dd6f79ef521d1...
π Finished publishing 5 events
β° SSE streaming timeout reached
π Worker threads completed. Events received: 0, published: 5
π§ Testing Event Publishing...
π Created test event: {
id: '86885020b165014ca50b1bcedf9e882ba5f5095d19b897f3f07393b8ac613c31',
pubkey: 'fd208ee8c8f283780a9552896e4823cc9dc6bfd442063889577106940fd927c1',
kind: 1,
content: 'Test event from GitRepublic Web GUI - 2025-06-28T0...'
}
π€ Publishing event...
β
Event published successfully
π Response: "event accepted"
π Testing Event Retrieval...
π Found 5 events
β
Retrieved 5 events successfully
1. 2c765e27f763d9dd... (kind 1)
2. 73fa0869485f69bb... (kind 1)
3. ef913a004b96dc8e... (kind 1)
4. 8e2b5f70f842f00d... (kind 1)
5. 4f63f481f8565843... (kind 1)
π Testing Server-Sent Events (SSE)...
β
Generated NIP-98 authentication token
π€ Sending SSE subscription with filter: {"kinds":[1]}
β
SSE endpoint accessible
π Status: 200
β
SSE connection established (streaming endpoint)
π Test Results Summary:
HTTP REST: β
PASS
Event Publishing: β
PASS
Event Retrieval: β
PASS
WebSocket: β
PASS
Server-Sent Events: β
PASS
π― Overall: 5/5 interfaces working
π Realy relay is fully functional and ready for GUI development!
Showing page 1 of
1 pages