Feeds and Subscriptions
List Subscriptions
https://api.planet.com/analytics/subscriptions
Returns all analytic subscriptions enabled for your API key. Each subscription defines the spatial area of interest (AOI), temporal window (start and end time), and the analytic feed to apply over that region and time period.
Example
- CURL
- Python
curl "https://api.planet.com/analytics/subscriptions" \
-H "Authorization: api-key $PL_API_KEY"
import os
import requests
from requests.auth import HTTPBasicAuth
API_KEY = os.getenv("PL_API_KEY")
if not API_KEY:
raise ValueError(
"Please set the PL_API_KEY environment variable as your Planet API key"
)
def list_analytic_subscriptions():
auth = HTTPBasicAuth(API_KEY, "")
resp = requests.get("https://api.planet.com/analytics/subscriptions", auth=auth)
if not resp.ok:
raise Exception(f"Failed to list analytic subscriptions: {resp.text}")
return resp.json()
Response Properties
Each subscription includes the following properties:
| Field | Description | Example |
|---|---|---|
created | UTC timestamp when the subscription was created | 2019-03-08T18:11:57.488Z |
description | Human-readable description of the subscription | Building Detection in New Cairo |
id | UUID for the subscription | f301b8c9-04e1-49f6-ab31-24a8c25edbd5 |
feedID | UUID for the feed | 1ce86055-cad0-4960-bdf3-32763c17f19b |
startTime | Start of the subscription's temporal window | 2019-01-01T00:00:00.000Z |
endTime | End of the subscription's temporal window (omitted if no end time is set) | 2019-01-31T00:00:00.000Z |
geometry | GeoJSON polygon defining the subscription's spatial extent | See example below |
links | HATEOAS links to the subscription, results, feed, and subscriptions endpoint | See example below |
title | Human-readable title of the subscription | Demo_Subscription_Singapore |
updated | UTC timestamp of the most recent update to subscription results | 2019-04-10T04:40:20.261Z |
Geometry Example
{
"type": "Polygon",
"coordinates": [
[
[103.849296569824, 1.2513119542594],
[103.880882263184, 1.2513119542594],
[103.880882263184, 1.27293604010387],
[103.849296569824, 1.27293604010387],
[103.849296569824, 1.2513119542594]
]
]
}
Links Example
[
{
"href": "https://api.planet.com/analytics/subscriptions/f301b8c9-04e1-49f6-ab31-24a8c25edbd5",
"rel": "self"
},
{
"href": "https://api.planet.com/analytics/collections/f301b8c9-04e1-49f6-ab31-24a8c25edbd5/items",
"rel": "results"
},
{
"href": "https://api.planet.com/analytics/feeds/e2ee4fca-e998-46fc-abe4-2ccaa7b7d285",
"rel": "feed"
},
{
"href": "https://api.planet.com/analytics/subscriptions",
"rel": "subscriptions"
}
]
List Feeds
https://api.planet.com/analytics/feeds
Returns all feeds enabled for your API key. Each feed defines the analytic model, source imagery type, and output format for a specific computer vision capability.
Example
- CURL
- Python
curl "https://api.planet.com/analytics/feeds" \
-H "Authorization: api-key $PL_API_KEY"
import os
import requests
from requests.auth import HTTPBasicAuth
API_KEY = os.getenv("PL_API_KEY")
if not API_KEY:
raise ValueError(
"Please set the PL_API_KEY environment variable as your Planet API key"
)
def list_analytic_feeds():
auth = HTTPBasicAuth(API_KEY, "")
resp = requests.get("https://api.planet.com/analytics/feeds", auth=auth)
if not resp.ok:
raise Exception(f"Failed to list analytic feeds: {resp.text}")
return resp.json()
Response Properties
Each feed includes the following properties:
| Field | Description | Example |
|---|---|---|
created | UTC timestamp when the feed was created | 2019-03-08T18:11:57.488Z |
description | Human-readable description of the feed | Ship detections from rectified PlanetScope imagery |
id | UUID for the feed | f35f37ce-4ba9-4b0d-b7d7-b687834223c3 |
links | HATEOAS links to the feed and feeds collection | See example below |
source | Source imagery configuration including bundle type, item types, and query filters | See example below |
target | Output type: collection for vector feeds or mosaic with series_id for raster feeds | See example below |
title | Human-readable title of the feed | Ship Detections |
updated | UTC timestamp of the most recent feed update | 2019-04-11T17:51:39.771Z |
Links Example
[
{
"href": "https://api.planet.com/analytics/feeds/f35f37ce-4ba9-4b0d-b7d7-b687834223c3",
"rel": "self"
},
{
"href": "https://api.planet.com/analytics/feeds",
"rel": "feeds"
}
]
Source Example
{
"config": {
"bundle": "visual",
"query": {
"filter": {
"config": ["true"],
"field_name": "ground_control",
"type": "StringInFilter"
},
"item_types": ["PSScene3Band"]
}
},
"type": "image"
}
Target Examples
Vector Output:
{
"type": "collection"
}
Raster Output:
{
"config": {
"series_id": "431b62a0-eaf9-45e7-acf1-d58278176d52"
},
"type": "mosaic"
}