ready-made APIby Arjun Okafor

NASA Open Data

api.nasa.gov

Get NASA's Astronomy Picture of the Day, near-Earth asteroid feeds and lookups, EPIC Earth images from the DSCOVR spacecraft, historical InSight Mars weather, natural event tracking, exoplanet archive queries and NASA image and video library search.

Writ CloudRESTMCPwebhookschedule2 credits / call

No website sign-in or persona needed. Free to install. Try any function below with your own values, no account: 10 free credits a day per device. Cloud calls after that use your own credits. Pricing →

The name api.nasa.gov belongs to its owner. This API is not affiliated with, endorsed by or sponsored by api.nasa.gov. You are responsible for how you use it.

01 · Functions9 functions

The form is the docs.

Choose a function, fill in its inputs, and run it: the answer comes back from the live site, with your values. Without an account you get 10 free credits a day per device for this; install the listing in Writ to keep calling it.

9 functionschoose one to explore
01get_apodGet the Astronomy Picture of the Day (APOD) metadata. Returns a single APOD object when date is specified, or a wrapped array ({items: [...]}) when start_date/end_date or count is used. The primary use case is fetching by a single date. Parameters date, count, and start_date/end_date are mutually exclusive; date takes priority. Every record carries updated_at, an ISO-8601 UTC timestamp of when NASA's API served the record (taken from the response's Date header; NASA publishes no per-record modification time), so it reflects the moment of retrieval rather than an editorial change date. Dates outside NASA's published range (Jun 16, 1995 to today) return an upstream error with NASA's message.02get_neo_feedGet a list of Near Earth Objects (asteroids) based on their closest approach date to Earth. Returns up to 7 days of data grouped by date. If only start_date is provided, end_date defaults to start_date + 7 days.03get_neo_lookupLook up a specific Near Earth Object (asteroid) by its NASA JPL small body SPK-ID. Returns detailed orbital and close approach data.04get_neo_browseBrowse the overall Asteroid dataset. Returns a paginated list of all Near Earth Objects in the database with orbital data.05get_insight_mars_weatherGet Mars weather data from NASA's InSight lander. Returns the last 7 available sols of weather data including temperature, wind, and pressure. Note: InSight mission ended November 2022; data is historical (sols 675-681, October 2020).06search_nasa_librarySearch the NASA Image and Video Library. Returns paginated search results with metadata about images, videos, and audio. Results are in collection.items array with data and links for each item.07get_exoplanet_dataQuery the NASA Exoplanet Archive database using TAP (Table Access Protocol) with ADQL queries. Returns results wrapped in {results: [...]}. Note: SQL LIMIT keyword is not supported; use ADQL TOP syntax instead (e.g. 'select top 10 * from ps').08get_eonet_eventsGet natural event data from NASA's Earth Observatory Natural Event Tracker (EONET). Returns events such as wildfires, storms, and volcanic eruptions with geolocation data in events array.09get_epic_imagesGet DSCOVR EPIC image metadata for the specified date and category, returned as {images: [...]}. Date must use YYYY-MM-DD format; category is natural or enhanced.
When a call does not work
No key · GET

AI assistants and tools that can only open a URL can call it with no key: one URL per function, its inputs in the query string. Each call spends the free keyless allowance, 10 credits a day per IP address.

GET https://api.usewrit.app/api/marketplace/listings/nasa-open-data/run?function_name=get_apod&date=<date>GET https://api.usewrit.app/api/marketplace/listings/nasa-open-data/run?function_name=get_neo_feedGET https://api.usewrit.app/api/marketplace/listings/nasa-open-data/run?function_name=get_neo_lookup&asteroid_id=<asteroid_id>GET https://api.usewrit.app/api/marketplace/listings/nasa-open-data/run?function_name=get_neo_browseGET https://api.usewrit.app/api/marketplace/listings/nasa-open-data/run?function_name=get_insight_mars_weatherGET https://api.usewrit.app/api/marketplace/listings/nasa-open-data/run?function_name=search_nasa_library&q=<q>GET https://api.usewrit.app/api/marketplace/listings/nasa-open-data/run?function_name=get_exoplanet_data&table=psGET https://api.usewrit.app/api/marketplace/listings/nasa-open-data/run?function_name=get_eonet_eventsGET https://api.usewrit.app/api/marketplace/listings/nasa-open-data/run?function_name=get_epic_images&date=2022-12-22&category=natural
02 · Checks and timingsmeasured per function

Built to be called again.

Every function was called on the live site before this API was published, and keeps being measured. The numbers are the listing’s own.

0.54 stypical callmedian of 3 functions’ medians
31measured runsacross 9 functions
5/5daily checks passedlast Dec 3 · pass
—buyer runs succeededno counted buyer runs yet
functionmedian · 95th percentilemedianruns
get_apod Not measured —
get_neo_feed 0.50 s 1
get_neo_lookup Not measured —
get_neo_browse 0.54 s 1
get_insight_mars_weather Not measured —
search_nasa_library Not measured —
get_exoplanet_data Not measured —
get_eonet_events Not measured —
get_epic_images 1.15 s 29
Checked daily 5 of 5 passed · last Dec 3
Repaired when it breaks A function that fails its check is re-tested and rebuilt. Installed copies receive the update; you redeploy nothing.
Buyer runs counted No counted buyer runs published yet; uptime counts real buyers’ runs only. Writ service status →

Historical measurements from the public listing, refreshed Dec 4, 2026. Timing samples are not an uptime claim or a guarantee for your next call.

03 · Your copyyour account

Install your copy. Call it your way.

2 credits
Priced per cloud call.

The listing’s base price is 2 credits per call. Longer runs, residential traffic and CAPTCHA solving can add usage. A site or Writ failure is free; your own input or login failures can be billable. Full usage rates →

cloud
No computer to keep running.

Marketplace copies execute in Writ Cloud, in your own account. Requirements and prices are checked before you use the listing.

REST · MCP
Every way to call it, at once.

Use your API key, connect an assistant, set a schedule with email or webhook delivery, or export answers as a dataset.

read-only
It only reads.

The published functions read data from the source website. No website sign-in or persona is needed for this listing.

private copy
Your account, your usage.

Your installed copy belongs to your account. Its underlying recipe stays sealed with its creator; no creator credentials are included.

04 · Or build your ownwebsite → API

Missing a function? Describe it.

Give Writ a website and say what you want. It builds and tests the API for your task.

On your computeryour machine

Build it in Writ Desktop and run it from your own IP. Execution on your machine costs 0 credits.

Get Writ Desktop →
In Writ Cloudcloud

Keep your API online without leaving your computer running. Cloud calls start at 2 credits, or 20 with a browser.

Build an API →
05 · More ready-madeAll APIs →
06 · Questions
Does NASA have an API?
This page is an independent API and MCP server for api.nasa.gov: Writ built it on the site’s public pages and tests it, and it has 9 functions you can call today. It is not an official NASA product. For an official API, check NASA’s own developer pages.
How do I use the NASA API from Claude, ChatGPT or Cursor?
Install it in Writ, then add Writ’s MCP server (https://api.usewrit.app/mcp) to Claude, ChatGPT, Cursor or any MCP client: your assistant can run this API’s functions and read the results. From your own code, call the same functions over REST with a Writ API key.
How much does a call to the NASA API cost?
2 credits per call, charged only when the call succeeds. New accounts start with 1,000 free credits, then 500 a month on the Free plan, no card.