Food, Health & Nature
Planets API
Physical fact sheets for every planet in the solar system, sourced from NASA data.
Request Headers
| Name | Required | Description |
|---|---|---|
X-RapidAPI-Key | required | Your RapidAPI key. Get one free. |
X-RapidAPI-Host | required | planets.p.rapidapi.com |
Endpoints
GET
/v1/planets Physical fact sheet for a solar-system planet
Parameters
| Name | Type | Required | Default | Constraints |
|---|---|---|---|---|
name | string | required | — | matches \S |
Code Examples
curl --request GET \
--url 'https://planets.p.rapidapi.com/v1/planets?name=example' \
--header 'x-rapidapi-key: YOUR_API_KEY' \
--header 'x-rapidapi-host: planets.p.rapidapi.com' const url = "https://planets.p.rapidapi.com/v1/planets?name=example";
const options = {
method: "GET",
headers: {
"x-rapidapi-key": "YOUR_API_KEY",
"x-rapidapi-host": "planets.p.rapidapi.com"
}
};
const response = await fetch(url, options);
const data = await response.json();
console.log(data); import requests
url = "https://planets.p.rapidapi.com/v1/planets"
querystring = {"name": "example"}
headers = {
"x-rapidapi-key": "YOUR_API_KEY",
"x-rapidapi-host": "planets.p.rapidapi.com"
}
response = requests.get(url, headers=headers, params=querystring)
print(response.json()) Interactive Example
$ GET /v1/planets?name=mars
{"name":"Mars","mass_kg":6.417e23,"radius_km":3389.5,"gravity_ms2":3.71,"day_hours":24.7,"year_days":687.0,"distance_from_sun_km":2.279e8,"moons":2,"temperature_c":-65.0} Subscribe & License
Access this API with commercial-ready tiers on RapidAPI. Flexible plans designed for side-projects, startups, and high-volume production architectures.
Developer Support
Need help integrating or have a custom endpoint request? Our engineering team is here to assist with authentication, payload schemas, and high-frequency rate limit increases.
System Performance
Monitored 24/7 with a 99.9% uptime SLA. Built atop cloud-native microservices with globally distributed edge caching to ensure ultra-low latency response times.
All Systems Operational