# Space Weather Alert — Aurora Visibility & HF Radio Blackout (`m_ctim/space-weather-alert`) Actor

Current geomagnetic Kp index, GOES X-ray flare class, NOAA R-scale radio blackout severity, computed aurora-visible latitude, and active NOAA space weather alerts, in one snapshot.

- **URL**: https://apify.com/m\_ctim/space-weather-alert.md
- **Developed by:** [Timothy Kelvin](https://apify.com/m_ctim) (community)
- **Categories:** Other
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

Pay per usage

This Actor is paid per platform usage. The Actor is free to use, and you only pay for the Apify platform usage, which gets cheaper the higher subscription plan you have.

Learn more: https://docs.apify.com/platform/actors/running/actors-in-store#pay-per-usage

## What's an Apify Actor?

Actors are web data automations that power AI and operations. They run on the Apify platform to scrape websites, process data, connect APIs, and automate workflows.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.
Actors are written with capital "A".

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.
The best way to integrate Actors is as follows.

- **AI agents and MCP clients** — the [Apify MCP server](https://docs.apify.com/integrations/mcp.md) at `https://mcp.apify.com` (remote, streamable HTTP, OAuth on first use).
- **Agentic workflows and local Actor development** — [Agent Skills](https://apify.com/.well-known/agent-skills/index.json) with the [Apify CLI](https://docs.apify.com/cli/docs.md): `npm install -g apify-cli`, then `apify login`.
- **JavaScript/TypeScript projects** — the official [JS/TS client](https://docs.apify.com/api/client/js/docs.md): `npm install apify-client`.
- **Python projects** — the official [Python client](https://docs.apify.com/api/client/python/docs.md): `pip install apify-client`.
- **Any other language** — the [REST API](https://docs.apify.com/api/v2.md).

For usage examples, see the [API](#api) section below.

For more details, see Apify documentation as [Markdown index](https://docs.apify.com/llms.txt) and [Markdown full-text](https://docs.apify.com/llms-full.txt).

# README

## Space Weather Alert — Aurora Visibility & HF Radio Blackout

One snapshot combining the space-weather numbers ham radio operators, aurora
chasers, and HF/satellite comms people currently check by hand across
several NOAA pages:

- **Geomagnetic Kp index** — plus a computed aurora-visible latitude, so you
  get "aurora may be visible above ~54°N" instead of a bare number
- **GOES X-ray flare class & NOAA R-scale** — the same R1–R5 radio-blackout
  severity scale NOAA itself publishes, derived from live X-ray flux
- **Active NOAA space weather alerts/watches/warnings** — the official text
  bulletins, most recent first

Built for ham radio operators tracking HF propagation, aurora
photographers/tourism operators planning by visibility latitude, and anyone
who currently refreshes spaceweather.gov manually.

### Input

```json
{ "maxAlerts": 10 }
```

| Field | Type | Description |
|---|---|---|
| `maxAlerts` | integer (default `10`) | How many of the most recent NOAA alert/watch/warning messages to include. |

### Output

One record per run:

```json
{
  "geomagnetic": {
    "kpIndex": 4,
    "observedAt": "2026-08-08T00:00:00",
    "auroraVisibleLatitude": 58.3
  },
  "radioBlackout": {
    "xrayFlux": 0.0000253,
    "flareClass": "M2.5",
    "observedAt": "2026-08-08T01:02:00Z",
    "rScale": "R1",
    "rScaleDescription": "Minor radio blackout"
  },
  "activeAlerts": [
    {
      "productId": "K04W",
      "issuedAt": "2026-08-04 08:10:52.687",
      "message": "Space Weather Message Code: WARK04\r\n..."
    }
  ],
  "fetchedAt": "2026-08-08T01:40:00.000Z"
}
```

### How it works

Three direct calls to NOAA's own public JSON feeds — no scraping, no proxy,
no key:

- Kp index: `services.swpc.noaa.gov/products/noaa-planetary-k-index.json`
- X-ray flux: `services.swpc.noaa.gov/json/goes/primary/xrays-6-hour.json` (the `0.1-0.8nm` long channel, GOES's standard flare-classification band)
- Alerts: `services.swpc.noaa.gov/products/alerts.json`

**R-scale thresholds** and **flare-class letters** follow NOAA's own
published definitions (see
[swpc.noaa.gov/noaa-scales-explanation](https://www.swpc.noaa.gov/noaa-scales-explanation)).
**Aurora-visible latitude** is a widely published approximate viewline table
by Kp index — a planning signal, not a guarantee; local weather, light
pollution, and time of night all matter too.

### Pricing note

Billed per **snapshot** (one run = one charge), regardless of how many
alerts are active. Cheap enough to schedule hourly for continuous
monitoring without the cost multiplying with alert volume.

### Related products

- [US Weather Forecast & Alerts Tracker](https://github.com/timmKal01/us-weather-tracker) — ground-level NWS forecasts and alerts for a location
- [Field Operations Risk Briefing](https://github.com/timmKal01/field-operations-risk-briefing) — combines weather with GPS/radio conditions for field crews
- [Earthquake Alert](https://github.com/timmKal01/earthquake-alert) — a different hazard type (seismic activity) for the same kind of monitoring use case

# Actor input Schema

## `maxAlerts` (type: `integer`):

How many of the most recent NOAA space weather alert/watch/warning messages to include in the snapshot.

## Actor input object example

```json
{
  "maxAlerts": 10
}
```

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {};

// Run the Actor and wait for it to finish
const run = await client.actor("m_ctim/space-weather-alert").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = {}

# Run the Actor and wait for it to finish
run = client.actor("m_ctim/space-weather-alert").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{}' |
apify call m_ctim/space-weather-alert --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,m_ctim/space-weather-alert"
        }
    }
}

```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/ubGcggxYZYpre3gzW/builds/o2EyK69OKrTDVnOgL/openapi.json
