Connecting to NASA
Using API Key Authentication
Most NASA API endpoints (APOD, NeoWS, DONKI, TechTransfer) require a NASA API key. Register for a free key at https://api.nasa.gov. The default DEMO_KEY provides limited access (30 requests/hour, 50 requests/day); a registered key allows 1,000 requests/hour.
The following endpoints do not require an API key and work without authentication: EONET (Earth Observatory Natural Event Tracker), EPIC (Earth Polychromatic Imaging Camera), NASA Image and Video Library, and TechPort.
After obtaining your API key, set the following connection properties:
- AuthScheme: Set this to APIKey.
- APIKey: Set this to your NASA API key. Use DEMO_KEY for limited testing.
Example Connection String
Profile=C:\profiles\NASA.apip;AuthScheme=APIKey;APIKey=YOUR_NASA_API_KEY
Connecting to NASA
Once the authentication is configured, you can connect to NASA and query data from any of the available tables such as AstronomyPictureOfDay, NearEarthObjectFeed, EonetEvents, and NasaImageLibrary.
Available Tables
The NASA API Profile provides access to the following tables:
- AstronomyPictureOfDay: Returns the Astronomy Picture of the Day with title, explanation, and image or video URLs. Supports date and date-range filtering.
- NearEarthObjectFeed: Near Earth Object feed for a date range (max 7 days). StartDate input is required.
- NearEarthObjectBrowse: Browse the complete NASA NEO catalog with pagination (40,000+ objects).
- NearEarthObjectLookup: Retrieve full orbital data for a specific asteroid by ID (requires AsteroidId).
- DonkiCoronalMassEjection: Coronal Mass Ejection events. Supports date-range filtering via StartDate/EndDate inputs.
- DonkiGeomagneticStorm: Geomagnetic Storm events. Supports date-range filtering.
- DonkiSolarFlare: Solar Flare events. Supports date-range filtering.
- DonkiSolarEnergeticParticle: Solar Energetic Particle events. Supports date-range filtering.
- DonkiMagnetopauseCrossing: Magnetopause Crossing events. Supports date-range filtering.
- DonkiRadiationBeltEnhancement: Radiation Belt Enhancement events. Supports date-range filtering.
- DonkiHighSpeedStream: High Speed Stream events. Supports date-range filtering.
- DonkiNotifications: Space weather notification messages. Filterable by event type and date range.
- EonetEvents: Natural events including hurricanes, wildfires, earthquakes, and volcanic activity. No API key required.
- EonetCategories: Reference list of EONET event categories. No API key required.
- EonetSources: Data source organizations contributing natural event reports. No API key required.
- EonetLayers: Satellite imagery layer definitions from the GIBS service. No API key required.
- EpicNatural: Natural color Earth imagery metadata from the DSCOVR spacecraft. No API key required.
- EpicEnhanced: Enhanced color Earth imagery metadata from the DSCOVR spacecraft. No API key required.
- NasaImageLibrary: Search NASA's media archive of photos, videos, and audio. Supports full-text search and filtering by center, media type, and date range. No API key required.
- TechTransferPatent: NASA patent portfolio. Keywords filter is required.
- TechTransferSoftware: NASA software portfolio. Keywords filter is required.
- TechTransferSpinoff: NASA spinoff technologies. Keywords filter is required.
- TechPortProjects: NASA TechPort project records. Supports incremental sync via LastModifiedDate filter. No API key required.
Important Notes
- EONET, EPIC, NASA Image and Video Library, and TechPort endpoints do not require an API key.
- NearEarthObjectFeed requires StartDate to be specified as a filter (max 7-day range).
- NearEarthObjectLookup requires AsteroidId to be specified as a filter.
- TechTransferPatent, TechTransferSoftware, and TechTransferSpinoff require Keywords to be specified as a filter.
- Date fields use ISO 8601 format (yyyy-MM-dd).
- Rate limits apply to api.nasa.gov endpoints: DEMO_KEY is limited to 30 requests/hour and 50 requests/day; a registered key allows 1,000 requests/hour.
API Documentation
For more information about the NASA Open APIs, see the official NASA Open APIs documentation.
Usage Examples
AstronomyPictureOfDay:
SELECT * FROM AstronomyPictureOfDay WHERE StartDate = '2024-01-01' AND EndDate = '2024-01-07'
NearEarthObjectFeed:
SELECT * FROM NearEarthObjectFeed WHERE StartDate = '2024-01-01' AND EndDate = '2024-01-07'
NearEarthObjectBrowse:
SELECT * FROM NearEarthObjectBrowse
NearEarthObjectLookup:
SELECT * FROM NearEarthObjectLookup WHERE AsteroidId = '3542519'
DonkiCoronalMassEjection:
SELECT * FROM DonkiCoronalMassEjection WHERE StartDate = '2024-01-01' AND EndDate = '2024-01-31'
DonkiGeomagneticStorm:
SELECT * FROM DonkiGeomagneticStorm WHERE StartDate = '2024-01-01' AND EndDate = '2024-01-31'
DonkiSolarFlare:
SELECT * FROM DonkiSolarFlare WHERE StartDate = '2024-01-01' AND EndDate = '2024-01-31'
DonkiSolarEnergeticParticle:
SELECT * FROM DonkiSolarEnergeticParticle WHERE StartDate = '2024-01-01' AND EndDate = '2024-01-31'
DonkiMagnetopauseCrossing:
SELECT * FROM DonkiMagnetopauseCrossing WHERE StartDate = '2024-01-01' AND EndDate = '2024-01-31'
DonkiRadiationBeltEnhancement:
SELECT * FROM DonkiRadiationBeltEnhancement WHERE StartDate = '2024-01-01' AND EndDate = '2024-01-31'
DonkiHighSpeedStream:
SELECT * FROM DonkiHighSpeedStream WHERE StartDate = '2024-01-01' AND EndDate = '2024-01-31'
DonkiNotifications:
SELECT * FROM DonkiNotifications WHERE NotificationType = 'FLR'
EonetEvents:
SELECT * FROM EonetEvents WHERE EventClosureDate IS NULL SELECT * FROM EonetEvents LIMIT 50
EonetCategories:
SELECT * FROM EonetCategories
EonetSources:
SELECT * FROM EonetSources
EonetLayers:
SELECT * FROM EonetLayers
EpicNatural:
SELECT * FROM EpicNatural
EpicEnhanced:
SELECT * FROM EpicEnhanced
NasaImageLibrary:
SELECT * FROM NasaImageLibrary WHERE AssetTitle = 'Apollo 11' SELECT * FROM NasaImageLibrary WHERE NasaCenter = 'JSC'
TechTransferPatent:
SELECT * FROM TechTransferPatent WHERE Keywords = 'solar'
TechTransferSoftware:
SELECT * FROM TechTransferSoftware WHERE Keywords = 'aircraft'
TechTransferSpinoff:
SELECT * FROM TechTransferSpinoff WHERE Keywords = 'satellite'
TechPortProjects:
SELECT * FROM TechPortProjects WHERE LastModifiedDate >= '2024-01-01'
Connection Properties
The connection string properties are the various options that can be used to establish a connection. This section provides a complete list of the options you can configure in the connection string for this provider.
| Property | Description |
| APIKey | Your NASA API key for authenticating requests to api.nasa.gov endpoints. |
| AuthScheme | The scheme used for authentication. Accepted entries are APIKey or None. Allowed values are: BASIC, NONE, NTLM, OAUTH, APIKEY, OAUTH_CLIENT |