GBDX

Place an Order

This tutorial shows how to place an order and check the status of an order. Examples are provided using GBDXtools and making direct API requests.

Last Updated: April 11, 2019

Overview

The Ordering API lets you place an order for a list of catalog IDs. It also lets you check the delivery status of the catalog IDs within an order.

Quickstart Examples

These examples show how to place an order using the Ordering API. The request will return an Order ID. This ID can be used later to check the status of the order.

GBDXtools Examples

Order a Single Catalog ID

from gbdxtools import Interface
gbdx = Interface()

order_id = gbdx.ordering.order('10400100143FC900')
print(order_id)

Order a List of Catalog IDs

from gbdxtools import Interface
gbdx = Interface()

catids = ["104001000506EE00","1010010005231400"]

order_id = gbdx.ordering.order(catids)
print(order_id)

GBDXtools Response

The response to both of these request types is an Order ID. For example,

c9418606-3843-492f-bd94-d7e54bede0c4

Ordering API Example

You can make a request to the Ordering API using Postman or your preferred API client.

API Request

To place an order, make a POST request to https://geobigdata.io/orders/v2/order

The body of the POST will be a list of catalog IDs to be ordered.

JSON

         [
         "104001000506EE00",
         "1010010005231400"
         ]

JSON Response

The response provides the delivery status of each catalog ID. If the state is "delivered", the s3 location will be displayed.

JSON

    {
        "order_id": "7a64034e-3705-46d8-b251-1cdbf7354cc9",
        "acquisitions": [
            {
                "acquisition_id": "1010010005231400",
                "state": "delivered",
                "location": "s3://receiving-dgcs-tdgplatform-com/059084234010_01_003"
            },
            {
                "acquisition_id": "104001000506EE00",
                "state": "delivered",
                "location": "s3://receiving-dgcs-tdgplatform-com/059084235010_01_003"
            }
        ]
    }

In the response, the "acquisition ID" is the catalog ID that was part of the order.

The response includes the following properties:

Property Description
order_id This is the ID assigned to the order. You'll use the Order ID to check the status of the order.
acquisitions Each acquisition that was ordered by catalog ID is listed in this section.
acquisition_id This is another name for the catalog ID. The acquisition IDs in the response map to the catalog IDs that were part of the order request.
state Each catalog ID (or acquisition ID) has a "state" or "status." The states are listed in the table below.
location When a 1B product is delivered to The GBDX Platform, its location will be displayed. This s3 location can be used as input for a task that accepts a url.

Order States

As an order goes through the system, status updates are logged. Orders can have the following states:

Order Status Description
submitted The order has been submitted to the GBDX platform
ordering The catalog IDs are in the process of being ordered from the DigitalGlobe (DG) factory.
placed The order has been placed with the DG factory.
delivered The catalog ID has been delivered from the DG factory and is available. Once a catalog ID has been delivered, the s3 location will be displayed.

failed | The order failed.|

Check the Status of an Order

These example shows how to get the status for the catalog IDs within an order. If the state is "delivered", it will show the s3 location. In this example, "5ac2db9b-2132-4360-89e3-231b6e6a100f" is the order ID.

Note: Order IDs are only available to users from the account that placed the order. To run these examples, you'll need to place an order and use the order ID for that order.

GBDXtools Example

Request Example

PYTHON

from gbdxtools import Interface
gbdx = Interface()

gbdx.ordering.status("5ac2db9b-2132-4360-89e3-231b6e6a100f")

Response Example

PYTHON

[{'acquisition_id': '1010010005231400',
  'state': 'delivered',
  'location': 's3://receiving-dgcs-tdgplatform-com/059084234010_01_003'},
 {'acquisition_id': '104001000506EE00',
  'state': 'delivered',
  'location': 's3://receiving-dgcs-tdgplatform-com/059084235010_01_003'}]

API Request Example

A status request to the API is identical to the order request. In this example, 5ac2db9b-2132-4360-89e3-231b6e6a100f is the order ID.

Request example

Send a GET request to

https://geobigdata.io/orders/v2/order/5ac2db9b-2132-4360-89e3-231b6e6a100f

Response Example


     {
    "order_id": "5ac2db9b-2132-4360-89e3-231b6e6a100f",
    "acquisitions": [
        {
            "acquisition_id": "1010010005231400",
            "state": "delivered",
            "location": "s3://receiving-dgcs-tdgplatform-com/059084234010_01_003"
        },
        {
            "acquisition_id": "104001000506EE00",
            "state": "delivered",
            "location": "s3://receiving-dgcs-tdgplatform-com/059084235010_01_003"
        }
    ]
}

In the response, "acquisition ID" is the catalog ID that was part of the order.


What's Next

Learn how to place an order and receive callback notifications

Ordering with Callbacks Tutorial

Place an Order


This tutorial shows how to place an order and check the status of an order. Examples are provided using GBDXtools and making direct API requests.

Last Updated: April 11, 2019

Suggested Edits are limited on API Reference Pages

You can only suggest edits to Markdown body content, but not to the API spec.