curl --request GET \
--url https://api.orbita.melonn.com/sell-orders/{external_order_number}/delivery-documents \
--header 'x-api-key: <api-key>'import requests
url = "https://api.orbita.melonn.com/sell-orders/{external_order_number}/delivery-documents"
headers = {"x-api-key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'x-api-key': '<api-key>'}};
fetch('https://api.orbita.melonn.com/sell-orders/{external_order_number}/delivery-documents', 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.orbita.melonn.com/sell-orders/{external_order_number}/delivery-documents",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"x-api-key: <api-key>"
],
]);
$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.orbita.melonn.com/sell-orders/{external_order_number}/delivery-documents"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("x-api-key", "<api-key>")
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.orbita.melonn.com/sell-orders/{external_order_number}/delivery-documents")
.header("x-api-key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.orbita.melonn.com/sell-orders/{external_order_number}/delivery-documents")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["x-api-key"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"id": 1732571663793215,
"internal_order_number": "M1732571663793215",
"external_order_number": "ORDER-1001",
"label_url": "https://example-bucket.s3.amazonaws.com/tracking-label.pdf?X-Amz-Signature=...",
"evidences": [
{
"url": "https://example-bucket.s3.amazonaws.com/evidence.jpeg?X-Amz-Signature=...",
"creation_date": "2021-01-10T20:21:11.000Z"
}
],
"expires_in": 900
}Get Delivery Documents
Returns temporary download links for the shipping label and the delivery evidence photos of a sell order.
Every link is a pre-signed URL that expires expires_in seconds (900, i.e. 15 minutes)
after the response is generated. Download the files right away, or call this endpoint again
to get fresh links. Documents are looked up on the current delivery attempt of each
package; a link that cannot be generated is returned as null (label) or left out
(evidences).
The response comes in one of two shapes:
- Single label (
label_url+evidencesat the top level): returned when the first package with a current delivery attempt already has a shipping label. - Per package (
sell_order_packagearray): returned otherwise, for example while the labels have not been generated yet. Each package carries its ownlabel_url,tracking_numberandevidences, which may benull/ empty.
The endpoint works for orders in any state. It returns 404 when no order with that
external order number exists for your account.
curl --request GET \
--url https://api.orbita.melonn.com/sell-orders/{external_order_number}/delivery-documents \
--header 'x-api-key: <api-key>'import requests
url = "https://api.orbita.melonn.com/sell-orders/{external_order_number}/delivery-documents"
headers = {"x-api-key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'x-api-key': '<api-key>'}};
fetch('https://api.orbita.melonn.com/sell-orders/{external_order_number}/delivery-documents', 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.orbita.melonn.com/sell-orders/{external_order_number}/delivery-documents",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"x-api-key: <api-key>"
],
]);
$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.orbita.melonn.com/sell-orders/{external_order_number}/delivery-documents"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("x-api-key", "<api-key>")
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.orbita.melonn.com/sell-orders/{external_order_number}/delivery-documents")
.header("x-api-key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.orbita.melonn.com/sell-orders/{external_order_number}/delivery-documents")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["x-api-key"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"id": 1732571663793215,
"internal_order_number": "M1732571663793215",
"external_order_number": "ORDER-1001",
"label_url": "https://example-bucket.s3.amazonaws.com/tracking-label.pdf?X-Amz-Signature=...",
"evidences": [
{
"url": "https://example-bucket.s3.amazonaws.com/evidence.jpeg?X-Amz-Signature=...",
"creation_date": "2021-01-10T20:21:11.000Z"
}
],
"expires_in": 900
}Authorizations
Path Parameters
The order number you assigned to the sell order when you created it.
Response
Delivery documents of the sell order.
Either label_url + evidences (single label) or sell_order_package (per package) is present, never both.
Melonn id of the sell order.
Melonn order number.
Your order number.
Seconds the download links stay valid (900).
900
Single-label shape only. Temporary (pre-signed) download URL of the shipping label.
Single-label shape only. Delivery evidence photos.
Show child attributes
Show child attributes
Per-package shape only. One entry per package of the order.
Show child attributes
Show child attributes