Planet API Client
Project description
PRE-ALPHA SOFTWARE - MAY CHANGE
Initial, incomplete, strawman effort at a Python client to Planet’s public API.
Documentation
https://planetlabs.github.io/planet-client-python/index.html
Installation
Recommend using a virtual environment.
Shellish:
git clone git@github.com:planetlabs/planet-client-python.git cd planet-client-python pip install -e .
Enabling bash completion (planet <tab> <tab>):
eval "$(_PLANET_COMPLETE=source planet)"
Usage
As a library
Pending
Command line use
Basics and help:
planet
OR specific command help:
planet get-scenes-list --help
To do anything real, one must provide an API key. This can be done via the environment variable PL_API_KEY or the flag -k or –api-key.
Examples
Get a visual ortho scene by id (writes to working directory):
planet download 20141008_170544_0907
Get an analytic ortho scene by id:
planet download 20141008_170544_0907 --analytic
Get scene metadata by id (and pretty print):
planet fetch_scene_info -pp 20141008_170544_0907
Testing
Install Test Dependencies
A few extra libraries are needed for testing:
pip install -e .[test]
Running the Tests
There are two suites of tests, one for the cli, the other for the library module.
Both can be run using:
py.test
Distributing
This requires that development libraries are installed:
pip install -e .[test]
An executable python file can be built by running:
pex . -o dist/planet -m planet.scripts:cli
This can be executed directly on systems with a python executable and in an environment (bash shell) capable of interpreting a shebang.
TODO!
more command line flags/tools (query filters, for example)
more docs
more tests
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file planet-0.0.1.tar.gz
.
File metadata
- Download URL: planet-0.0.1.tar.gz
- Upload date:
- Size: 8.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 78815e333fb5c8c2a918fd15d6c66a906f833045a790f2bce08310e7b87d5af2 |
|
MD5 | d71fa309a7b58a06524207d8956eaf7d |
|
BLAKE2b-256 | d8462cb38e594923ff4ae855268901862eab0caa969aadb57672450b8b2fba07 |
Provenance
File details
Details for the file planet-0.0.1-py2-none-any.whl
.
File metadata
- Download URL: planet-0.0.1-py2-none-any.whl
- Upload date:
- Size: 11.9 kB
- Tags: Python 2
- Uploaded using Trusted Publishing? No
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 81c6d73e0f4332c795ef4715a2e76451634d79c2acb914d3ccc6508f873866a1 |
|
MD5 | 80f69fd2d2fdd425c896999c206dc314 |
|
BLAKE2b-256 | d08a7ec67d32af9f240e1fc80b2798a385b29225c5924d7ef175bb4c71580dbd |