Skip to main content
Get order
curl --request GET \
  --url https://api.maple.inc/v1/orders/{orderId} \
  --header 'Authorization: Bearer <token>'
import requests

url = "https://api.maple.inc/v1/orders/{orderId}"

headers = {"Authorization": "Bearer <token>"}

response = requests.get(url, headers=headers)

print(response.text)
const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};

fetch('https://api.maple.inc/v1/orders/{orderId}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));
<?php

$curl = curl_init();

curl_setopt_array($curl, [
CURLOPT_URL => "https://api.maple.inc/v1/orders/{orderId}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
package main

import (
"fmt"
"net/http"
"io"
)

func main() {

url := "https://api.maple.inc/v1/orders/{orderId}"

req, _ := http.NewRequest("GET", url, nil)

req.Header.Add("Authorization", "Bearer <token>")

res, _ := http.DefaultClient.Do(req)

defer res.Body.Close()
body, _ := io.ReadAll(res.Body)

fmt.Println(string(body))

}
HttpResponse<String> response = Unirest.get("https://api.maple.inc/v1/orders/{orderId}")
.header("Authorization", "Bearer <token>")
.asString();
require 'uri'
require 'net/http'

url = URI("https://api.maple.inc/v1/orders/{orderId}")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'

response = http.request(request)
puts response.read_body
{
  "object": "order",
  "id": "<string>",
  "livemode": true,
  "created": 123,
  "status": "<string>",
  "payment_status": "<string>",
  "location_id": "<string>",
  "fulfillment_type": "<string>",
  "customer": {
    "name": "<string>",
    "phone_last_four": "<string>"
  },
  "line_items": [
    {
      "name": "<string>",
      "menu_entity_id": "<string>",
      "quantity": 123,
      "base_price": 123,
      "tax": 123,
      "modifiers": [
        {
          "name": "<string>",
          "menu_entity_id": "<string>",
          "quantity": 123,
          "price": 123
        }
      ]
    }
  ],
  "totals": {
    "currency": "<string>",
    "subtotal": 123,
    "tax": 123,
    "surcharge": 123,
    "tip": 123,
    "delivery_fee": 123,
    "delivery_tip": 123,
    "total": 123
  },
  "external_id": "<string>",
  "payment": {
    "provider": "<string>",
    "status": "<string>",
    "payment_link_url": "<string>"
  }
}
{
"_tag": "DeveloperApiUnauthorized",
"message": "<string>"
}
{
"_tag": "DeveloperApiForbidden",
"message": "<string>"
}
{
"_tag": "DeveloperApiNotFound",
"message": "<string>"
}

Authorizations

Authorization
string
header
required

API key — mpk_test_… for the sandbox, mpk_live_… for production. Issued by Maple during partner onboarding.

Path Parameters

orderId
string
required

Response

Success

object
enum<string>
required
Available options:
order
id
string
required
livemode
boolean
required

True when the order belongs to the live environment; false for test-mode data.

created
required
status
string
required
payment_status
string | null
required
location_id
string | null
required
fulfillment_type
string
required
customer
object
required
line_items
object[]
required
totals
object
required

All amounts in integer USD cents. total = subtotal + tax + surcharge + tip + delivery fees.

external_id
string | null
required
payment
object
required