Get order details

View full order details by order ID.

Legend

❓ - clarification will be provided
⚪️ - discontinued
⏳ - TBD
🟡 - supported but requires changes
🟢 - supported

Request

Comparison

TermOld APINew API
Endpoint🟢 GET /api/order-details🟡 GET v1/orders/{id} Find order by ID
Authorization🟢 Via t (required)🟡 Via the Authorization request header (required)
Order ID🟢 Via o query parameter (request)🟡 Via REST parameter id

Examples

curl --request GET \
  --url 'https://sandbox.market-api.southpole.com/api/order-details?t=token&o=1' \
  --header 'Content-Type: application/json'
curl --request GET \
     --url "https://dcs-compensate-api-sandbox.southpole.com/v1/orders/1" \
     --header 'accept: application/json' \
     --header 'authorization: Bearer token'

Response

Comparison

Data Model (JSON path)Old APINew API
Status🟢 status⚪️ Removed in favour of the HTTP client response status field
Order ID🟢 id🟡 order.id
Customer details🟢 order.name🟡 order.consumer.*
Order status🟢 order.status🟡 order.status (RESERVED, CANCELLED, COMPLETED)
Gateway🟢 order.gateway⚪️ Removed
Total amount🟢 order.totalAmount (in EUR)🟡 order.totalPrice.amount
Currency🟢 order.currency🟡 order.totalPrice.currency
EUR equivalent🟢 order.eur_equivalent⚪️ Removed in favour of a currency specified in the order request
Created date time🟢 order.created_at🟡 order.createdAt
Date paid🟢 order.date_paid⚪️ Removed
Total credits🟢 order.total_credits🟡 order.totalVolume
Compensated projects details🟢 order.projects[].*🟡 order.projects[].* (money and volume breakdown per project)
Order notes🟢 order.nodes⚪️ Removed

Examples

{
  "status": "ok",
  "order": {
    "id": 1556388118,
    "name": "John Doe",
    "msg": "Order Paid",
    "status": "paid",
    "gateway": "Stripe",
    "total_amount": 10.67,
    "currency": "EUR",
    "eur_equivalent": 10.67,
    "created_at": "2019-04-27 18:01:58",
    "date_paid": "2019-04-27 18:01:58",
    "total_credits": 0.97,
    "projects": [
      {
        "no": 300758,
        "name": "Za Hung Hydro",
        "credits": 0.97
      }
    ],
    "notes": ""
  }
}
{
  "consumer": {
    "firstName": "John",
    "lastName": "Doe"
  },
  "createdAt": "2023-01-19T13:26:31Z",
  "id": "1",
  "projects": [
    {
      "contribution": {
        "amount": "30",
        "currency": "EUR"
      },
      "id": "7619267199133",
      "volume": {
        "quantity": "5",
        "unit": "t"
      }
    }
  ],
  "status": "COMPLETED",
  "totalPrice": {
    "amount": "30",
    "currency": "EUR"
  },
  "totalVolume": {
    "quantity": "5",
    "unit": "t"
  },
  "updatedAt": "2023-01-19T13:31:13Z"
}