← Planets
Alderaan
Attributes
| Rotation period | 24 |
|---|---|
| Orbital period | 364 |
| Diameter | 12500 |
| Climate | temperate |
| Gravity | 1 standard |
| Terrain | grasslands, mountains |
| Surface water | 40 |
| Population | 2000000000 |
Related records
Use this record
curl
curl https://swapi.build/api/planets/2
JavaScript
fetch('https://swapi.build/api/planets/2').then((r) => r.json())
Python
requests.get('https://swapi.build/api/planets/2').json()
MCP
Connect your agent once:
claude mcp add --transport http swapi-build https://swapi.build/mcp
then call the tool sw_get with:
{"resource":"PLANETS","id":2}
GET /api/planets/2 200
{
"climate": "temperate",
"created": "2014-12-10T11:35:48.479000Z",
"diameter": "12500",
"edited": "2014-12-20T20:58:18.420000Z",
"films": [
"https://swapi.build/api/films/1",
"https://swapi.build/api/films/6"
],
"gravity": "1 standard",
"name": "Alderaan",
"orbital_period": "364",
"population": "2000000000",
"residents": [
"https://swapi.build/api/people/5",
"https://swapi.build/api/people/68",
"https://swapi.build/api/people/81"
],
"rotation_period": "24",
"surface_water": "40",
"terrain": "grasslands, mountains",
"url": "https://swapi.build/api/planets/2"
}