# NOAA SWPC on Onekey > 2 endpoints for NOAA SWPC (2 stable, 0 beta), 5 credits each. Category: Maps, weather & space. One key, one JSON shape. Base URL: https://api.onekey.dev Auth: header `x-api-key: `. Call shape: `GET /v1/{platform}/{endpoint}?{params}`. Every response is `{success, data, metadata, error}`; check `success` first. Cost is in `metadata.credits_charged`. Free when served from cache (0.2 credit for a cached response over 100 KB). Failed and not-found calls are refunded. Status: stable = verified against the live source; beta = not yet verified, fields may be missing. Page: https://onekey.dev/platforms/swpc Reference (Markdown): https://onekey.dev/docs/api/swpc.md All docs: https://onekey.dev/llms.txt ## Canonical fields returned Unified-schema fields (same names on every platform), with how many of the 2 mapped NOAA SWPC endpoints return each: - `content.createdAt` (ISO 8601 date): 2 - `content.id` (string): 1 - `content.text` (string): 1 - plus 2 platform-specific fields under `ext.` ## Endpoints ### swpc.alerts NOAA space weather alerts, watches and warnings. - Price: 5 credits per fresh call. Status: stable. Returns: a list. - Request: `GET https://api.onekey.dev/v1/swpc/alerts` with header `x-api-key: YOUR_API_KEY` - Parameters: none - Fields returned: `content.id`, `content.createdAt`, `content.text` - Reference: https://onekey.dev/docs/api/swpc/alerts.md ### swpc.kp_index Planetary K-index (geomagnetic activity), 1-minute samples. - Price: 5 credits per fresh call. Status: stable. Returns: a list. - Request: `GET https://api.onekey.dev/v1/swpc/kp_index` with header `x-api-key: YOUR_API_KEY` - Parameters: none - Fields returned: `content.createdAt`, `ext.kp`, `ext.estimatedKp` - Reference: https://onekey.dev/docs/api/swpc/kp_index.md ## Sample request ```bash curl "https://api.onekey.dev/v1/swpc/alerts" \ -H "x-api-key: YOUR_API_KEY" ```