- Home
- Skills
- APIs & Backend
- NASA API Reference
NASA API Reference
Implementation guide for NASA's APOD and Near Earth Object (NEO) API endpoints with caching and query patterns.
$9
NASA API Reference
Example session with this skill installed
I need to fetch the last 3 days of Near Earth Object data. Give me the correct endpoint and curl command for this.
- Read your context and instructions
- Compiled the nasa api reference
I have retrieved the endpoint details and query patterns for the NASA NEO feed. For a 3-day range, you should use the feed endpoint with specific start and end dates.
NASA NEO Feed Implementation
To fetch asteroid data for a specific date range, use the following request structure. Ensure your date range does not exceed 7 days to avoid API rejection.
Endpoint: GET https://api.nasa.gov/neo/rest/v1/feed
Curl Command:
curl "https://api.nasa.gov/neo/rest/v1/feed?start_date=2023-10-01&end_date=2023-10-03&api_key=YOUR_API_KEY"
| Parameter | Type | Description |
|---|---|---|
start_date | YYYY-MM-DD | Starting date for asteroid search |
end_date | YYYY-MM-DD | Ending date for asteroid search |
api_key | string | Your NASA API key (or DEMO_KEY) |
Implementation Notes:
- Caching: This endpoint has an upstream cache TTL of approximately 60 minutes. Do not re-fetch more frequently.
- Handling Empty Sets: If no asteroids are near Earth during this window, the API returns an empty array. Check the array length before processing to avoid errors.
- Rate Limiting: If using
DEMO_KEY, you are limited to 30 requests per hour. Use a personal API key for production workloads.
Next steps
- Replace
YOUR_API_KEYwith a valid key from api.nasa.gov. - Implement a 60-minute local cache to respect the upstream TTL.
- Add a check to differentiate between a 429 Rate Limit error and a valid empty data response.
Connects securely to your tools. The creator never sees your data.
About this skill
Integrating NASA's public data into your application often involves navigating inconsistent parameter requirements and aggressive rate limits. This skill provides a precise reference for consuming Astronomy Picture of the Day (APOD) and Near Earth Object (NEO) data without the trial and error of manual documentation searches.
What it does
- Endpoint selection helps you identify the correct path for APOD images or asteroid tracking data.
- Parameter mapping defines required inputs like date ranges and API keys for every request.
- Query optimization provides patterns for filtering selective parameters to avoid timeouts.
- Cache management offers TTL hints to reduce redundant API calls and stay within rate limits.
- Error handling distinguishes between valid empty sets and API errors to prevent broken retry loops.
How it works
- Identify the data requirement, such as daily astronomy media or near-earth asteroid tracking.
- Select the corresponding endpoint from the reference list:
apod,feed, orbrowse. - Apply query patterns like narrow-to-wide filtering to ensure the request succeeds.
- Implement the suggested 60-minute caching logic to manage public rate limits.
Frameworks & tools
This skill interfaces with the api.nasa.gov public endpoints. It is protocol-agnostic, supporting any stack capable of making HTTPS GET requests via curl, fetch, or standard HTTP libraries.
Why this beats prompting it yourself
Generic LLMs often hallucinate endpoint paths or mix up required parameters for NASA's various API versions. This skill provides a verified field guide that includes specific upstream TTL hints and anti-patterns that prevent your API key from being throttled.
Use cases
- Build a Slack bot that posts the Astronomy Picture of the Day every morning.
- Create a dashboard for tracking asteroids with close approach dates.
- Populate a space-themed educational app with paginated NEO discovery data.
- Automate data collection for astronomy research using narrow-to-wide filtering.
Known limitations
Coverage is restricted to what the upstream public API exposes. Responses are in the native NASA format and require manual normalization before use.
How to use
- 1
Connect your agent to the Agensi MCP
Copy the prompt and paste it into Claude, ChatGPT, Cursor or any agent that supports MCP. It sets up the connection for you. Manual setup
- 2
Sign in to Agensi
Your agent shows a sign-in link. Sign in and click Allow.
- 3
Ask for what you need
Your agent loads this skill and uses it on your task. It always asks before buying a skill.
Reviews
No reviews yet
Be one of the first to try it. Every listed skill goes through the trust checks below.
Security scanned
Checked by our 8-point scan before listing
Fresh listing
Recently published to Agensi
Money-back guarantee
Doesn't do what its page promises? You get your money back.
Trust & safety
Security scan
Security scan passed 5 days ago
Permissions
What's inside
Frequently Asked Questions
New in APIs & Backend
Find more skills like this on the Claude Skills Marketplace, the Codex Skills Marketplace and the Gemini Skills Marketplace, or browse Claude Skills for APIs & Backend.