Keyboard shortcuts

Press ← or → to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Spaceflight Tracker

The Spaceflight tab keeps you connected to what is happening above the atmosphere: rocket launches, current ISS crew, orbital transits, and upcoming space events.


Tab layout

Sub-tabContent
LaunchesUpcoming and recent rocket launches with details and video links
AstronautsCrew currently in orbit
Space EventsSpacewalks, dockings, and mission milestones
ISSReal-time ISS position + pass predictions for your location

Launches

Module: backend/space/spaceflight_tracker.py

Data source: Launch Library 2 (The Space Devs)

API base: https://ll.thespacedevs.com/2.2.0/

Cache TTL: 2 hours (CACHE_TTL_SPACEFLIGHT_LAUNCHES).

Launch Library 2 is the de-facto standard for launch data. The free tier allows ~15 requests/hour; MyAstroBoard’s cache keeps live calls minimal.

What is displayed

FieldDescription
Mission nameLaunch or payload name
Agency/providerLaunch operator (SpaceX, ULA, Roscosmos…)
VehicleRocket family and variant
Launch sitePad location
NETNo Earlier Than date-time (in your local timezone)
StatusGo, TBD, Hold, Success, Failure, Partial Failure
Launch videoEmbedded webcast URL (YouTube, SpaceflightNow…)
Mission imageLaunch patch or vehicle image (cached locally)

Image caching

Launch images from the LL2 CDN are downloaded and served locally via GET /api/spaceflight/img/<filename>. This avoids CORS issues and makes the UI work without external CDN access. A .url sidecar file is written alongside each image so it can be re-fetched if deleted.

Rate limiting

If the LL2 API returns HTTP 429 (rate limit), all further calls to the same endpoint are suppressed for 1 hour (_BACKOFF_TTL = 3600 s) to respect the free-tier quota.

Video URLs

GET /api/spaceflight/launch/<launch_id>/vidurls returns available video stream URLs for a given launch, fetched on demand (not cached) to ensure the latest live-stream link is returned.


Astronauts

Module: backend/space/spaceflight_tracker.py

Cache TTL: 6 hours (CACHE_TTL_SPACEFLIGHT_ASTRONAUTS).

Fetches from Launch Library 2 the list of all people currently in orbit:

FieldDescription
NameAstronaut full name
AgencySpace agency
VehicleSpacecraft they arrived on
RoleMission role (Commander, Flight Engineer…)
Days in spaceDays since launch
Profile imageLocally cached from LL2 CDN

API: GET /api/spaceflight/astronauts


Space events

Module: backend/space/spaceflight_tracker.py

Cache TTL: 2 hours (CACHE_TTL_SPACEFLIGHT_EVENTS).

Space events include EVAs (spacewalks), dockings, undockings, and other mission milestones tracked by Launch Library 2.

API: GET /api/spaceflight/events


ISS passes

Module: backend/space/iss_passes.py

Cache TTL: 6 hours (CACHE_TTL_ISS_PASSES).

TLE data

Pass prediction requires up-to-date Two-Line Element (TLE) data. The service tries three sources in priority order:

PrioritySourceNotes
1Celestrak GP catalogAuthoritative, NORAD #25544
2api.wheretheiss.atIndependent aggregator
3tle.ivanstanojevic.meIndependent aggregator

TLE data is cached locally in data/cache/iss_tle_cache.json for up to 6 hours. (Skyfield’s own ephemeris files are stored separately under data/cache/skyfield/.) If all sources fail, the last valid TLE is used for up to 3 hours before the prediction is considered unreliable.

After Celestrak blocked the server, an admin can clear the block with POST /api/iss/celestrak/restart (/api/css/celestrak/restart for the CSS); the banner offers the button to admins only.

Pass prediction algorithm

Library: Skyfield with EarthSatellite propagation (SGP4 model).

The service predicts passes over a 20-day window (max 30) from the configured location.

For each pass:

FieldDescription
start_time / end_timeRise and set in local timezone
duration_secondsTotal pass duration
max_altitude_degMaximum elevation above the horizon
start_azimuth_deg / end_azimuth_degDirection at rise and set
visibility_classvisible (ISS in sunlight, ground in darkness), daylight, night_only, below_horizon
visibility_score0-100 quality score

Passes with max altitude < 10° (MIN_EVENT_ALTITUDE_DEG) are filtered out.

Visible passes require:

  • ISS illuminated by the Sun
  • Observer in darkness (Sun altitude < −4°, MAX_VISIBLE_SKY_SUN_ALTITUDE_DEG)

Solar transits

A solar transit occurs when the ISS passes directly in front of the solar disk. This is a rare photographic opportunity.

The service refines transit timing to 0.1 s resolution (SOLAR_TRANSIT_REFINE_SAMPLE_SECONDS) and checks whether the ISS angular path crosses the Sun’s angular disk (radius ≈ 0.267°).

Lunar transits

Similarly, a lunar transit occurs when the ISS crosses the lunar disk. Both transit types are returned separately in the API response.

ISS real-time location

GET /api/iss/location returns the current ISS ground position (latitude, longitude, altitude, velocity). The ground track ±50 minutes is computed once per 5 minutes (server-side cache _TRACK_CACHE_TTL_SECONDS = 300) to reduce SGP4 computation.

API endpoints

MethodPathDescription
GET/api/iss/passesUpcoming passes, solar transits, and lunar transits
GET/api/iss/locationReal-time ISS position and ground track
POST/api/iss/celestrak/restartClear the Celestrak block flag (admin only)

The /api/iss/passes response includes:

KeyContent
passesList of predicted passes
solar_transitsList of solar transit events
lunar_transitsList of lunar transit events
next_visible_passageNext pass with visibility_class = visible
next_solar_transitNext solar transit
next_lunar_transitNext lunar transit
total_passes / total_solar_transits / total_lunar_transitsCounts

Push notification triggers

TriggerEventDefault lead
N3ISS solar or lunar transit10 min

See NOTIFICATIONS.md for the full notification system.

Last updated 2026-11-13