Log inSuggest an edit

Using the Planet CLI

Planet Python Client

The Planet Python Client is an open-source project (Apache 2.0 license) with a command-line interface (CLI) and a Python library for interacting with Planet's Data API. We invite our users to contribute code and documentation and to file issues and bug reports.

Install

Install the Planet CLI with:

pip install planet

If you have not already, get your API key at planet.com/account, and add it to your environment:

export PL_API_KEY=a3a64774d30c4749826b6be445489d3b # (not a real key)

Search the Planet Data API for scenes intersecting with your Area, and Time of Interest:

planet data search --item-type PSScene4Band --geom geom.json --date acquired gt 2017-01-10 --date acquired lt 2017-03-10

Planet supports geometry in the GeoJSON format - see the Geometry Quickstart guide on how to use the format.

Add a cloud cover filter:

planet data search --item-type PSScene4Band --geom aoi.json --date acquired gt 2017-01-10 --date acquired lt 2017-03-10 --range cloud_cover lt .1

Download

Download the images in your search:

planet data download --item-type PSScene3Band --geom aoi.json --date acquired gt 2017-01-10 --date acquired lt 2017-03-10 --range cloud_cover lt .1 --asset-type analytic