NASA Open APIs Photos API

The Photos API from NASA Open APIs — 2 operation(s) for photos.

Operations 2

GET /rovers/{rover}/photos Get Photos for a Rover #
GET /rovers/{rover}/latest_photos Get Most Recent Photos for a Rover #

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/nasa-gov-photos-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

nasa-gov-photos-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: NASA Mars Rover Photos API
  description: 'Image data gathered by NASA''s Curiosity, Opportunity, Spirit, and Perseverance rovers on Mars. Each photo

    can be queried by Earth date or Martian sol with optional camera filter.

    '
  version: '1.0'
  contact:
    name: NASA Open APIs
    url: https://api.nasa.gov/
  license:
    name: US Government Work (Public Domain)
servers:
- url: https://api.nasa.gov/mars-photos/api/v1
security:
- ApiKeyAuth: []
tags:
- name: Photos
paths:
  /rovers/{rover}/photos:
    get:
      summary: Get Photos for a Rover
      operationId: getRoverPhotos
      tags:
      - Photos
      parameters:
      - name: rover
        in: path
        required: true
        schema:
          type: string
          enum:
          - curiosity
          - opportunity
          - spirit
          - perseverance
      - name: sol
        in: query
        description: Martian sol the photos were taken on. One of sol or earth_date is required.
        schema:
          type: integer
          minimum: 0
      - name: earth_date
        in: query
        description: Earth date the photos were taken on (YYYY-MM-DD).
        schema:
          type: string
          format: date
      - name: camera
        in: query
        description: Filter by camera abbreviation.
        schema:
          type: string
          enum:
          - FHAZ
          - RHAZ
          - MAST
          - CHEMCAM
          - MAHLI
          - MARDI
          - NAVCAM
          - PANCAM
          - MINITES
      - name: page
        in: query
        schema:
          type: integer
      - $ref: '#/components/parameters/ApiKey'
      responses:
        '200':
          description: Photos taken on the requested sol/date.
  /rovers/{rover}/latest_photos:
    get:
      summary: Get Most Recent Photos for a Rover
      operationId: getRoverLatestPhotos
      tags:
      - Photos
      parameters:
      - name: rover
        in: path
        required: true
        schema:
          type: string
      - $ref: '#/components/parameters/ApiKey'
      responses:
        '200':
          description: Most recent photos returned by the rover.
components:
  parameters:
    ApiKey:
      name: api_key
      in: query
      required: true
      schema:
        type: string
        default: DEMO_KEY
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: query
      name: api_key