Basemaps Overview

Planet offers a range of Basemap products, each suited for different applications and use cases. The Global Basemap is best suited for mapping and visual simulation use cases. It is automatically generated annually, covers the entire globe in RGB bands, and has a visual color curve applied.

Authentication

The Basemaps API uses Basic HTTP Authentication and requires that you have a Planet API key. Currently, anyone can sign up for a free account on our website. Once you're signed up, you can find your API key in your account settings. Authenticate by setting username to your API key or by providing a valid api_key as a query parameter to all tile requests.

Authentication via Basic HTTP with Python

import os
# import os module to access enviornmental modules

import requests

from requests.auth import HTTPBasicAuth
# import helper functions to make Basic request to Planet API

PLANET_API_KEY = os.getenv('PL_API_KEY')
# Setup the API Key from the `PL_API_KEY` environment variable

BASE_URL = 'https://api.planet.com/basemaps/v1/mosaics'

if PLANET_API_KEY is None:
  PLANET_API_KEY = '12345'
#pass in your API key

auth = HTTPBasicAuth(PLANET_API_KEY, '')
# HTTPBasicAuth() wants a username & password; you can pass an empty string for the password

res = requests.get(url=BASE_URL, auth=auth)

print(res.status_code)
# make a request to the Basemaps API and test the response

Authentication via cURL

curl --header "Authorization: api-key {your api key}" 
 https://api.planet.com/basemaps/v1/mosaics

Passing API Key via URL Parameter

https://api.planet.com/basemaps/v1/mosaics?api_key={your api key}

Basemaps API

Planet Basemap imagery is distributed as a grid of GeoTIFF files, which are called “basemap quads” or simply “quads.”

Using the Basemaps API you can download a full mosaic or just one or more selected quads.


Rate this guide: