Subscribe to Celestial Body Events
Receive
Server
Subscribe to events for all celestial bodies in the galaxy
Events related to all types of celestial bodies (planets, satellites, asteroids, comets).
This is a general channel for monitoring the entire galaxy's celestial activity.
header
AuthorizationBearer <JWT>JWT Bearer token authentication for WebSocket connections
bodyType?stringFilter by celestial body type
Value in
"planet""satellite""asteroid""comet"minHabitability?numberFilter by minimum habitability index
Range
0 <= value <= 1const socket = new WebSocket("wss://galaxy.scalar.com/celestial-bodies/events?api_key=YOUR_API_KEY");
socket.addEventListener("message", (event) => {
console.log(event.data);
});