ParcelRadar.io
ParcelRadar.ioDeveloper Portal
← กลับไปที่ภาพรวม

API Reference

เอกสารอ้างอิง endpoint ทั้งหมดของ Parcel Radar API

Sandbox

นี่คือ API ของ sandbox

คอนโซลด้านล่างเรียกไปยัง sandbox ของ Parcel Radar: ข้อมูลทดสอบ คูเรียร์ทดสอบ และ test QR โดยไม่ใช้เงินจริง กรอก X-API-Key ของ sandbox เพื่อให้สิทธิ์แก่คำขอ จากนั้นจึงเรียกใช้ endpoint ใดก็ได้

Instant Quote — Synchronous

หนึ่งคำขอ หนึ่งการตอบกลับ: POST การจัดส่งของคุณไปที่ /quote แล้วการเรียกจะบล็อกไว้จนกว่าจะได้อัตราค่าจัดส่งจากผู้ให้บริการขนส่งทุกรายครบ (หรือหมดเวลา (timeout) ประมาณ 60 วินาที ซึ่งจะคืนค่า 504) เป็นวิธีเชื่อมต่อที่ง่ายที่สุด — เลือกวิธีนี้ เว้นแต่คุณต้องหลีกเลี่ยงการเปิดคำขอค้างไว้นานถึงหนึ่งนาที (เช่น serverless/edge functions ที่มี timeout สั้น หรือมีการทำงานพร้อมกันจำนวนมาก)

POSThttps://api-sandbox.parcelradar.io/api/partner/v1/instant-quote/quote

ดึงอัตราค่าจัดส่งแบบเรียลไทม์ (sync)

ส่งข้อมูลการจัดส่งและรับอัตราค่าจัดส่งแบบเรียลไทม์จากผู้ให้บริการขนส่งที่รองรับทุกรายในการเรียกครั้งเดียว บล็อกไว้จนกว่าการกระจายไปยังผู้ให้บริการขนส่งจะเสร็จสิ้น (หรือประมาณ 60 วินาที → 504)

ฟิลด์ประเภทจำเป็นค่าที่รับได้ค่าเริ่มต้นหมายเหตุ
originobjectYes--ที่อยู่ต้นทาง (ผู้ส่ง)
countrystringYesISO-2, e.g. "TH"-ตัดให้เหลือ 2 อักขระ และทำเป็นตัวพิมพ์ใหญ่
citystring---ชื่อเมือง เป็นข้อความอิสระ
zipcodestring---รหัสไปรษณีย์
destinationobjectYes--ที่อยู่ปลายทาง (ผู้รับ)
countrystringYesISO-2, e.g. "TH"-ตัดให้เหลือ 2 อักขระ และทำเป็นตัวพิมพ์ใหญ่
citystring---ชื่อเมือง เป็นข้อความอิสระ
zipcodestring---รหัสไปรษณีย์
parcelsarrayYes--หนึ่งรายการต่อพัสดุหนึ่งชิ้น
lengthnumber-> 01ความยาวในหน่วย dunit
widthnumber-> 01ความกว้างในหน่วย dunit
heightnumber-> 01ความสูงในหน่วย dunit
weightnumber-> 01น้ำหนักในหน่วย wunit
wunitstring-"kg", "lb""kg"หน่วยน้ำหนักสำหรับพัสดุ และสำหรับ `chargeableWeight` ในผลลัพธ์
dunitstring-"cm", "in""cm"หน่วยของขนาด
currencystring-"THB", "USD", "EUR", "GBP""THB"สกุลเงินของมูลค่าสินค้า/มูลค่าที่สำแดงสำหรับศุลกากร (goods_currency ของ match-engine) ต้นทุนจะถูกส่งกลับในทั้งสี่สกุลเงินเสมอ
valuenumber->= 0100มูลค่าสินค้าที่สำแดง
ตัวอย่างคำขอ
{
  "origin": {
    "country": "TH",
    "city": "Bangkok",
    "zipcode": "10240"
  },
  "destination": {
    "country": "US",
    "city": "New York",
    "zipcode": "11373"
  },
  "parcels": [
    {
      "length": 20,
      "width": 15,
      "height": 10,
      "weight": 2
    }
  ],
  "wunit": "kg",
  "dunit": "cm",
  "currency": "THB",
  "value": 1500
}

Instant Quote — Asynchronous

ไม่บล็อก มีสามขั้นตอน: POST /inquiry เพื่อเริ่ม, GET /inquiry?id= เพื่อ poll จนกว่าสถานะจะไม่ใช่ "processing" แล้ว GET /results?inquiryId= เพื่อรับอัตราค่าจัดส่ง คืนอัตราค่าจัดส่งเดียวกันกับแบบ sync — เลือกวิธีนี้เมื่อคุณไม่ต้องการเปิดคำขอค้างไว้นาน ต้องการแสดง UI แบบค่อยเป็นค่อยไป หรือทำงานในสภาพแวดล้อมที่ timeout ของคำขอสั้น

ดึงอัตราค่าจัดส่งแบบเรียลไทม์ (async)

สร้าง inquiry แล้ว poll จนกว่าจะ ready จากนั้นดึงผลลัพธ์ — เป็นอัตราค่าจัดส่งชุดเดียวกับ /quote แบบ synchronous โดยไม่ต้องเปิดคำขอค้างไว้ เรียก endpoint ทั้งสามนี้ตามลำดับ

แอปของคุณ
Parcel Radar API
1POST /inquiry
202 · { inquiryId }id สำหรับ poll
2GET /inquiry?id={inquiryId}loop
{ status }จนกว่าจะ "ready"
3GET /results?inquiryId={inquiryId}
{ status, results[] }รายการที่ซื้อโฆษณาก่อน แล้วจึงราคาถูกที่สุด

เคล็ดลับการ poll: เว้นระยะ ~1–2 วินาทีระหว่างการ poll แต่ละครั้ง (จะใช้ exponential backoff แบบสั้น ๆ ก็ได้) และเลิกพยายามหลังจากประมาณ 60 วินาที — เพดานเดียวกับที่ /quote แบบ synchronous ใช้ มีเพียง POST /inquiry เท่านั้นที่ต้องใช้ X-API-Key ส่วนการเรียก poll และ results ต้องใช้เพียง inquiryId ที่ได้กลับมา

POSThttps://api-sandbox.parcelradar.io/api/partner/v1/instant-quote/inquiry

สร้าง inquiry

เริ่ม quote แบบ async คืนค่า inquiryId ทันทีสำหรับ poll — การกระจายไปยังผู้ให้บริการขนส่งทำงานอยู่เบื้องหลัง ใช้ body ของการจัดส่งเดียวกันกับ /quote

ฟิลด์ประเภทจำเป็นค่าที่รับได้ค่าเริ่มต้นหมายเหตุ
originobjectYes--ที่อยู่ต้นทาง (ผู้ส่ง)
countrystringYesISO-2, e.g. "TH"-ตัดให้เหลือ 2 อักขระ และทำเป็นตัวพิมพ์ใหญ่
citystring---ชื่อเมือง เป็นข้อความอิสระ
zipcodestring---รหัสไปรษณีย์
destinationobjectYes--ที่อยู่ปลายทาง (ผู้รับ)
countrystringYesISO-2, e.g. "TH"-ตัดให้เหลือ 2 อักขระ และทำเป็นตัวพิมพ์ใหญ่
citystring---ชื่อเมือง เป็นข้อความอิสระ
zipcodestring---รหัสไปรษณีย์
parcelsarrayYes--หนึ่งรายการต่อพัสดุหนึ่งชิ้น
lengthnumber-> 01ความยาวในหน่วย dunit
widthnumber-> 01ความกว้างในหน่วย dunit
heightnumber-> 01ความสูงในหน่วย dunit
weightnumber-> 01น้ำหนักในหน่วย wunit
wunitstring-"kg", "lb""kg"หน่วยน้ำหนักสำหรับพัสดุ และสำหรับ `chargeableWeight` ในผลลัพธ์
dunitstring-"cm", "in""cm"หน่วยของขนาด
currencystring-"THB", "USD", "EUR", "GBP""THB"สกุลเงินของมูลค่าสินค้า/มูลค่าที่สำแดงสำหรับศุลกากร (goods_currency ของ match-engine) ต้นทุนจะถูกส่งกลับในทั้งสี่สกุลเงินเสมอ
valuenumber->= 0100มูลค่าสินค้าที่สำแดง
ตัวอย่างคำขอ
{
  "origin": {
    "country": "TH",
    "city": "Bangkok",
    "zipcode": "10240"
  },
  "destination": {
    "country": "US",
    "city": "New York",
    "zipcode": "11373"
  },
  "parcels": [
    {
      "length": 20,
      "width": 15,
      "height": 10,
      "weight": 2
    }
  ],
  "wunit": "kg",
  "dunit": "cm",
  "currency": "THB",
  "value": 1500
}
GEThttps://api-sandbox.parcelradar.io/api/partner/v1/instant-quote/inquiry

Poll สถานะของ inquiry

ตรวจสอบว่า inquiry เสร็จแล้วหรือยัง Poll ทุก ๆ ประมาณ 1–2 วินาที จนกว่าสถานะจะไม่ใช่ "processing" แล้วจึงดึงผลลัพธ์

ฟิลด์ประเภทจำเป็นค่าที่รับได้ค่าเริ่มต้นหมายเหตุ
iduuidYesUUID-inquiryId ที่ส่งกลับโดย POST /inquiry
GEThttps://api-sandbox.parcelradar.io/api/partner/v1/instant-quote/results

ดึงผลลัพธ์ของ inquiry

ดึงอัตราค่าจัดส่งรายผู้ให้บริการของ inquiry มีรูปแบบผลลัพธ์เดียวกันกับการตอบกลับของ /quote แบบ synchronous; results จะถูกเติมเมื่อสถานะเป็น "ready"

ฟิลด์ประเภทจำเป็นค่าที่รับได้ค่าเริ่มต้นหมายเหตุ
inquiryIduuidYesUUID-inquiryId ที่ส่งกลับโดย POST /inquiry

Provider detail

ค้นหาเงื่อนไขการจัดส่งหรือ rate card ของผู้ให้บริการด้วย provider id ที่คืนมาในผลลัพธ์ของ quote

GEThttps://api-sandbox.parcelradar.io/api/partner/v1/instant-quote/conditions

ดึงเงื่อนไขของผู้ให้บริการ

เงื่อนไขการจัดส่งของผู้ให้บริการหนึ่งราย — incoterms, transit time, service network, features, weight config, route coverage และ goodsRestriction เมื่อผู้ให้บริการจำกัดสินค้าตาม HS code ส่ง provider id จากผลลัพธ์ของ /quote

ฟิลด์ประเภทจำเป็นค่าที่รับได้ค่าเริ่มต้นหมายเหตุ
iduuidYesUUID-Provider id (ค่า `id` จากผลลัพธ์ของ /quote)
GEThttps://api-sandbox.parcelradar.io/api/partner/v1/instant-quote/ratecard

ดึง ratecard ของผู้ให้บริการ

rate card ของผู้ให้บริการหนึ่งราย — display flags, banners และ (สำหรับผู้ให้บริการแบบ manual-rate) static price curve ส่ง provider id จากผลลัพธ์ของ /quote

ฟิลด์ประเภทจำเป็นค่าที่รับได้ค่าเริ่มต้นหมายเหตุ
iduuidYesUUID-Provider id (ค่า `id` จากผลลัพธ์ของ /quote)

HS codes & duty

การค้นหาชุดเดียวกับฟอร์ม Goods & declared value ใน Member Portal: หา HS code ของสินค้า แล้วดูอัตราอากรของรหัสนั้นที่ประเทศปลายทาง จากนั้นใส่รหัสในออเดอร์ที่ `packages.goods[].hsCode`

GEThttps://api-sandbox.parcelradar.io/api/partner/v1/hs-codes/search

ค้นหา HS code

HS code ที่ตรงกับคำอธิบายหรือรหัส เรียงจากตรงที่สุด ต้องใช้ X-API-Key

ฟิลด์ประเภทจำเป็นค่าที่รับได้ค่าเริ่มต้นหมายเหตุ
qstringYes2 to 100 characters-ชื่อสินค้าเป็นภาษาไทยหรืออังกฤษ (พิมพ์บางส่วนของคำได้) หรือ HS code หรือส่วนต้นของรหัส ("0712", "0712.20")
limitnumber-1 to 2010จำนวนผลลัพธ์สูงสุด
sourcestring-"thai_customs", "karton", "manual"-ค้นหาเฉพาะแหล่งเดียว ไม่ระบุ = ทุกแหล่ง
POSThttps://api-sandbox.parcelradar.io/api/partner/v1/tariff/rates

ดึงอัตราอากร

อากรขาเข้าของแต่ละ HS code ที่ประเทศหนึ่ง เป็นอัตราเดียวกับที่ใช้คิดในใบเสนอราคา ต้องใช้ X-API-Key รหัสที่ไม่มีอัตราไม่ถือเป็นข้อผิดพลาด โดยบรรทัดนั้นจะมี ratePct เป็น null และใช้อัตราอากร % ของผู้ขนส่งแทน

ฟิลด์ประเภทจำเป็นค่าที่รับได้ค่าเริ่มต้นหมายเหตุ
countrystringYesISO-2 code-ประเทศผู้นำเข้า
hsCodesarrayYes1 to 50 codes-HS code ใส่จุดได้
ตัวอย่างคำขอ
{
  "country": "US",
  "hsCodes": [
    "6109.10"
  ]
}

Address Book

ที่อยู่ผู้ส่ง/ผู้รับที่บันทึกไว้ของ tenant ของคุณ — เป็นสมุดเดียวกันกับที่สมาชิกจัดการใน Member Portal ดังนั้นการเปลี่ยนแปลงจะปรากฏที่นั่นด้วย การปิดที่อยู่จะยังคงเก็บไว้และแสดงในรายการ ส่วนการลบจะนำออก

GEThttps://api-sandbox.parcelradar.io/api/partner/v1/address-book

แสดงรายการ address book

หนึ่งหน้าของที่อยู่ที่บันทึกไว้ของ tenant ของคุณ การเรียงลำดับใช้ค่าที่เก็บไว้ ดังนั้น `country` จะเรียงตาม ISO code แทนที่จะเป็นชื่อที่แปลตามภาษา ที่อยู่ที่ถูกปิดจะรวมอยู่ด้วยตามค่าเริ่มต้น

ฟิลด์ประเภทจำเป็นค่าที่รับได้ค่าเริ่มต้นหมายเหตุ
pagenumber->= 00ดัชนีหน้า โดยเริ่มนับจากศูนย์
sizenumber-1–10010ขนาดหน้า (จำกัดไว้ที่ 100)
sortstring-"name", "alias", "country", "city", "phone", "updated"updatedคอลัมน์ที่ใช้เรียงลำดับ (name และ alias แยกกัน)
dirstring-"asc", "desc"descทิศทางการเรียงลำดับ
activestring-"all", "active", "inactive"allกรองตามสถานะเปิด/ปิด ค่าเริ่มต้นคืนทั้งสองสถานะ — ที่อยู่ที่ inactive จะถูกปิดใช้งาน ไม่ใช่ถูกซ่อน
rolestring-"all", "sender", "recipient", "eor", "ior"allเฉพาะรายการที่มี role นี้: eor = Exporter of Record, ior = Importer of Record (ตัวแทนทางอ้อม)
countrystring-ISO-2, e.g. "DE"-เฉพาะรายการในประเทศนี้ ใช้คู่กับ role=ior และประเทศ Ship To ของออเดอร์เพื่อดู Importer of Record ที่ออเดอร์นั้นเลือกได้
POSThttps://api-sandbox.parcelradar.io/api/partner/v1/address-book

สร้างที่อยู่

บันทึกที่อยู่ใหม่ ต้องมี role flag อย่างน้อยหนึ่งค่าเป็น true ที่อยู่หนึ่งรายการมีได้หลาย role และจะแสดงในทุกรายการที่ตรง คืนค่าที่อยู่ตามที่บันทึก รายการ Exporter / Importer of Record (isExporterOfRecord / isImporterOfRecord) เก็บชื่อบริษัทไว้ใน `name` พร้อม `contactName` และ `customsRegNo`

ฟิลด์ประเภทจำเป็นค่าที่รับได้ค่าเริ่มต้นหมายเหตุ
isSenderboolean-true, falsefalseใช้เป็นผู้ส่งได้ ต้องมี role อย่างน้อยหนึ่งค่าเป็น true
isRecipientboolean-true, falsefalseใช้เป็นผู้รับได้ ต้องมี role อย่างน้อยหนึ่งค่าเป็น true
isExporterOfRecordboolean-true, falsefalseExporter of Record (ตัวแทนทางอ้อม) นับเป็น role หนึ่ง
isImporterOfRecordboolean-true, falsefalseImporter of Record (ตัวแทนทางอ้อม) นับเป็น role หนึ่ง
isActiveboolean-true, falsetrueหากไม่ระบุตอนสร้าง = active; หากไม่ระบุตอนอัปเดต = คงสถานะปัจจุบันไว้
namestringYes1–200 chars-ชื่อผู้ติดต่อ; สำหรับรายการ Exporter / Importer of Record คือชื่อบริษัท
contactNamestring-≤ 100 chars-Exporter / Importer of Record: ชื่อผู้ติดต่อ ค่าว่างจะถูกบันทึกเป็น null
customsRegNostring-≤ 50 chars-Exporter / Importer of Record: เลขทะเบียนศุลกากร เช่น EORI "DE123456789012345" ค่าว่างจะถูกบันทึกเป็น null
countryCodestringYesISO-2, e.g. "TH"-จัดเก็บเป็นตัวพิมพ์ใหญ่
aliasstring-≤ 200 chars-ชื่อเล่น/ป้ายกำกับ ค่าว่างจะถูกจัดเก็บเป็น null
phonePrefixstring-1–4 digits, e.g. "66"-รหัสโทรศัพท์ ไม่มี "+" ต้องมี phone มาคู่กัน; รวมกันได้ไม่เกิน 15 หลัก (E.164)
phonestring-4–14 digits-หมายเลขภายในประเทศ เช่น "812345678" รหัสโทรศัพท์ใส่ไว้ใน phonePrefix
emailstring-≤ 200 chars-email ผู้ติดต่อ
addressLinestring-≤ 500 chars-ถนน / บรรทัดที่อยู่
postalCodestring-≤ 12 chars, upper-case-ตัวอักษรและตัวเลข เว้นวรรคเดี่ยวหรือขีดกลาง: "10110", "SW1A 1AA", "100-0001"
provincestring-≤ 200 chars-รัฐ / จังหวัด
districtstring-≤ 200 chars-เขต / อำเภอ
citystring-≤ 200 chars-เทศบาล / เมือง
ตัวอย่างคำขอ
{
  "isSender": true,
  "isRecipient": true,
  "alias": "HQ",
  "name": "Vernice West",
  "phonePrefix": "66",
  "phone": "812345678",
  "email": "hq@acme.com",
  "addressLine": "1 Sukhumvit",
  "countryCode": "TH",
  "postalCode": "10110",
  "province": "Bangkok",
  "district": "Watthana",
  "city": "Bangkok"
}
PUThttps://api-sandbox.parcelradar.io/api/partner/v1/address-book/{id}

อัปเดตที่อยู่

แทนที่ทั้งรายการ (PUT): ส่งที่อยู่ครบทุกฟิลด์ ฟิลด์ optional ที่ไม่ได้ส่งจะถูกล้างเป็น null ไม่ต้องส่ง `isActive` หากต้องการคงสถานะเปิด/ปิดเดิม (สลับด้วย `PATCH /{id}/active`) ฟิลด์ของ Exporter / Importer of Record (isExporterOfRecord, isImporterOfRecord, contactName, customsRegNo) จะคงค่าเดิมหากไม่ได้ส่ง

ฟิลด์ประเภทจำเป็นค่าที่รับได้ค่าเริ่มต้นหมายเหตุ
isSenderbooleanYestrue, falsefalseใช้เป็นผู้ส่งได้ ต้องมี role อย่างน้อยหนึ่งค่าเป็น true หากไม่ระบุ → false (และถ้าไม่มี role อื่นเป็น true จะได้ 400)
isRecipientbooleanYestrue, falsefalseใช้เป็นผู้รับได้ ต้องมี role อย่างน้อยหนึ่งค่าเป็น true หากไม่ระบุ → false (และถ้าไม่มี role อื่นเป็น true จะได้ 400)
isExporterOfRecordboolean-true, falsekeeps currentExporter of Record (ตัวแทนทางอ้อม) นับเป็น role หนึ่ง หากไม่ระบุ → คงค่าที่บันทึกไว้ ระบบที่เขียนก่อนมีฟิลด์นี้จึงไม่ทำให้ role หายไป
isImporterOfRecordboolean-true, falsekeeps currentImporter of Record (ตัวแทนทางอ้อม) นับเป็น role หนึ่ง หากไม่ระบุ → คงค่าที่บันทึกไว้ ระบบที่เขียนก่อนมีฟิลด์นี้จึงไม่ทำให้ role หายไป
isActiveboolean-true, falsekeeps currentหากไม่ระบุตอนสร้าง = active; หากไม่ระบุตอนอัปเดต = คงสถานะปัจจุบันไว้ เปลี่ยน flag ได้ด้วย PATCH /{id}/active
namestringYes1–200 chars-ชื่อผู้ติดต่อ; สำหรับรายการ Exporter / Importer of Record คือชื่อบริษัท หากไม่ระบุ → 400; ที่อยู่จะไม่ถูกเขียน
contactNamestring-≤ 100 charskeeps currentExporter / Importer of Record: ชื่อผู้ติดต่อ ค่าว่างจะถูกบันทึกเป็น null หากไม่ระบุ → คงค่าที่บันทึกไว้; ส่ง "" เพื่อล้างค่า
customsRegNostring-≤ 50 charskeeps currentExporter / Importer of Record: เลขทะเบียนศุลกากร เช่น EORI "DE123456789012345" ค่าว่างจะถูกบันทึกเป็น null หากไม่ระบุ → คงค่าที่บันทึกไว้; ส่ง "" เพื่อล้างค่า
countryCodestringYesISO-2, e.g. "TH"-จัดเก็บเป็นตัวพิมพ์ใหญ่ หากไม่ระบุ → 400; ที่อยู่จะไม่ถูกเขียน
aliasstringYes≤ 200 chars-ชื่อเล่น/ป้ายกำกับ ค่าว่างจะถูกจัดเก็บเป็น null หากไม่ระบุ → ถูกล้างเป็น null (ค่าที่จัดเก็บไว้จะถูกเขียนทับ)
phonePrefixstringYes1–4 digits, e.g. "66"-รหัสโทรศัพท์ ไม่มี "+" ต้องมี phone มาคู่กัน; รวมกันได้ไม่เกิน 15 หลัก (E.164) หากไม่ระบุ → ถูกล้างเป็น null
phonestringYes4–14 digits-หมายเลขภายในประเทศ เช่น "812345678" รหัสโทรศัพท์ใส่ไว้ใน phonePrefix หากไม่ระบุ → ถูกล้างเป็น null
emailstringYes≤ 200 chars-email ผู้ติดต่อ หากไม่ระบุ → ถูกล้างเป็น null
addressLinestringYes≤ 500 chars-ถนน / บรรทัดที่อยู่ หากไม่ระบุ → ถูกล้างเป็น null
postalCodestringYes≤ 12 chars, upper-case-ตัวอักษรและตัวเลข เว้นวรรคเดี่ยวหรือขีดกลาง: "10110", "SW1A 1AA", "100-0001" หากไม่ระบุ → ถูกล้างเป็น null
provincestringYes≤ 200 chars-รัฐ / จังหวัด หากไม่ระบุ → ถูกล้างเป็น null
districtstringYes≤ 200 chars-เขต / อำเภอ หากไม่ระบุ → ถูกล้างเป็น null
citystringYes≤ 200 chars-เทศบาล / เมือง หากไม่ระบุ → ถูกล้างเป็น null
ตัวอย่างคำขอ
{
  "isSender": true,
  "isRecipient": true,
  "isActive": true,
  "alias": "HQ",
  "name": "Vernice West",
  "phonePrefix": "66",
  "phone": "812345678",
  "email": "hq@acme.com",
  "addressLine": "1 Sukhumvit",
  "countryCode": "TH",
  "postalCode": "10110",
  "province": "Bangkok",
  "district": "Watthana",
  "city": "Bangkok"
}
PATCHhttps://api-sandbox.parcelradar.io/api/partner/v1/address-book/{id}/active

เปิดใช้งาน / ปิดใช้งานที่อยู่

เปิดหรือปิดที่อยู่ เป็นการปิดใช้งานแบบ soft: ที่อยู่ยังคงอยู่ในสมุดและยังคืนมาจากรายการ จึงสามารถเปิดกลับได้ Idempotent หากต้องการนำออกอย่างถาวร ให้ใช้ DELETE

ฟิลด์ประเภทจำเป็นค่าที่รับได้ค่าเริ่มต้นหมายเหตุ
isActivebooleanYestrue, false-true = ใช้งานได้, false = ปิดใช้งาน (ยังคงบันทึกไว้และยังแสดงในรายการ)
ตัวอย่างคำขอ
{
  "isActive": false
}
DELETEhttps://api-sandbox.parcelradar.io/api/partner/v1/address-book/{id}

ลบที่อยู่

นำที่อยู่ออกอย่างถาวร ไม่สามารถย้อนกลับได้ และ id จะไม่สามารถอ้างถึงได้อีก หากต้องการเก็บไว้แต่ไม่ใช้งาน ให้ใช้ PATCH /{id}/active ด้วย `isActive: false` แทน

ฟิลด์ประเภทจำเป็นค่าที่รับได้ค่าเริ่มต้นหมายเหตุ
okbooleanYestrue-เป็น true เสมอเมื่อได้ 200 — ที่อยู่ถูกลบแล้ว
iduuidYesUUID-id ที่ถูกลบ ส่งกลับมาให้
ตัวอย่างการตอบกลับ
{
  "ok": true,
  "id": "d65e6140-df1c-4581-8885-e79501964f6f"
}

Orders

ออเดอร์การจัดส่งของ tenant คุณ ใช้ร่วมกับ Member Portal ดู "จากออเดอร์ถึง Shipment Label" ด้านล่างเพื่อดูลำดับการเรียก ตั้งแต่สร้างออเดอร์จนได้ฉลากติดกล่อง

จากออเดอร์ถึง Shipment Label

ออเดอร์ส่งออกใน Member Portal ทีละแท็บ ในรูปแบบการเรียก API: สร้างออเดอร์ ระบุข้อมูลการจัดส่ง เลือกบริการขนส่ง ชำระเงิน แล้วรับ Shipment Label เรียกจากบนลงล่าง เมื่อ flow แยกทาง จะใช้เพียงหนึ่งทางเท่านั้น ทุกการเรียกต้องใช้ X-API-Key และ path อยู่ใต้ /api/partner/v1 (checkout และการจองคูเรียร์ใช้ได้เฉพาะ partner lane)

การเรียกที่ต้องทำการเรียกที่ไม่บังคับaltใช้เพียงหนึ่งทาง
แอปของคุณ
Parcel Radar API
1. สร้างออเดอร์· Create order
1POST /orders
{ id, orderNo, status: CREATED }เก็บ id ไว้
2. ระบุข้อมูลการจัดส่ง· Route Details · Packages
2GET /hs-codes/search?q=ไม่บังคับ
{ items[] }HS code ของสินค้าแต่ละบรรทัด
3PUT /orders/{id}
orderroute + packages + goods
3. เลือกบริการขนส่ง· Service Details
4POST /instant-quote/quote
{ results[] }providerId + ราคา
5GET /orders/{id}/service-options?providerId=
{ options[], extraServices[] }รับถึงที่หรือนำส่งเอง
6POST /orders/{id}/pickup/quoteไม่บังคับ
{ quoteId, feeThb }เฉพาะ api_markup
7GET /dropoff-points?orderId=ไม่บังคับ
{ items[] }เฉพาะแบบนำส่งเอง
8PUT /orders/{id}/dropoff-pointไม่บังคับ
{ dropoffPoint }
9POST /orders/{id}/service
orderParcel Radar คำนวณราคาให้
4. ชำระเงิน (Checkout)· Checkout
10GET /orders/{id}/checkout
{ amount, fingerprint, conditionsAccepted, sufficient }
11POST /orders/{id}/checkout/conditions
{ acceptedAt }ครั้งเดียวต่อผู้ให้บริการ
12POST /orders/{id}/checkout
{ status: SUBMITTED, chargeId }กันวงเงินแล้ว
5. รับ Shipment Label· Shipment Label
13GET /orders/{id}/pickup/handoff
{ kind, claimCode }pickup | dropoff
alt
[kind = pickup (คูเรียร์มารับ)]
14POST /orders/{id}/pickup/compareไม่บังคับ
{ offers[], winner }
15POST /orders/{id}/pickup
{ id: pickupId, status: PENDING }ส่ง idempotencyKey
16POST /orders/{id}/pickup/{pickupId}/book
{ status: BOOKED, trackNo }ต้องมี pickupFrom
17GET /orders/{id}/pickup/{pickupId}/label
{ sheets[] }carton mark + ฉลากคูเรียร์
จบ: พิมพ์ทุก sheet แล้วติดบนทุกกล่อง คูเรียร์จะมารับพัสดุ
[kind = dropoff (นำส่งเอง)]
14GET /orders/{id}/carton-mark
{ sheets[] }พร้อมรหัสรับพัสดุ
จบ: พิมพ์ carton mark แล้วนำพัสดุและรหัสรับพัสดุไปที่จุดรับพัสดุ
6. ติดตามพัสดุ· Tracking
18GET /orders/{id}/pickup/{pickupId}/trackingไม่บังคับ
{ events[] }ช่วงรับพัสดุ
19GET /orders/{id}/trackingไม่บังคับ
{ state, trackingUrl }ส่งให้ลูกค้าของคุณ

ควรรู้

  • Checkout จะกันยอดรวมของออเดอร์ไว้ใน wallet ของ workspace และตัดเงินจริงเมื่อเจ้าหน้าที่อนุมัติการจัดส่ง หากได้ 409 ที่มี code error.wallet.insufficient จะมี shortfall บอกยอดที่ขาด ให้เติมเงิน prepaid wallet ด้วย QR (POST /wallet/topups) หรือใน Member Portal แล้ว checkout อีกครั้ง
  • คุณไม่ต้องส่งราคาเอง: POST /orders/{id}/service รับ providerId (จาก Live Rates), pickupGroupId และ extra services (จาก service-options) และ quoteId จาก POST /orders/{id}/pickup/quote เป็น pickupQuoteId สำหรับตัวเลือกแบบ api_markup แล้ว Parcel Radar จะคำนวณราคาให้ หากแก้ route หรือ packages หลังจากนั้น checkout จะตอบ error.order.checkout.requote ให้เรียก POST /orders/{id}/service อีกครั้ง
  • ฉลากคือชุด sheet แบบ HTML พร้อมขนาดหน้าเป็นมิลลิเมตร (100×100 หรือ 100×150) ให้เรนเดอร์แต่ละ sheet ตามขนาดนั้น เช่น พิมพ์เป็น PDF ด้วย headless browser หนึ่งหน้าต่อหนึ่ง sheet
  • ใช้ idempotencyKey เดิมเมื่อเรียก POST /orders/{id}/pickup ซ้ำ key เดียวกันจะได้การจองเดิมเสมอ จึงไม่จองคูเรียร์ซ้ำ
GEThttps://api-sandbox.parcelradar.io/api/partner/v1/orders

List orders

A page of the tenant's orders, newest first.

ฟิลด์ประเภทจำเป็นค่าที่รับได้ค่าเริ่มต้นหมายเหตุ
statusstring-"all", "CREATED", "PROCESSING", "IN_TRANSIT", "DELIVERED", "EXCEPTION", "ON_HOLD", "RETURNING", "RETURNED"allLifecycle filter.
qstring---Free-text match on order no + countries.
pagenumber->= 00ดัชนีหน้า โดยเริ่มนับจากศูนย์
sizenumber-1–10010ขนาดหน้า (จำกัดไว้ที่ 100)
sortstring-"order", "status", "from", "to", "provider", "updated"updatedColumn to order by.
dirstring-"asc", "desc"descทิศทางการเรียงลำดับ
POSThttps://api-sandbox.parcelradar.io/api/partner/v1/orders

Create an order

Create an order from the two required routing countries.

ฟิลด์ประเภทจำเป็นค่าที่รับได้ค่าเริ่มต้นหมายเหตุ
fromCountrystringYesISO-2, in the country list-Origin. Upper-cased; a code not in the list is rejected (400).
toCountrystringYesISO-2, in the country list-Destination. Upper-cased; a code not in the list is rejected (400).
ตัวอย่างคำขอ
{
  "fromCountry": "TH",
  "toCountry": "US"
}
GEThttps://api-sandbox.parcelradar.io/api/partner/v1/orders/{id}

Get an order

Fetch one order by id.

ฟิลด์ประเภทจำเป็นค่าที่รับได้ค่าเริ่มต้นหมายเหตุ
iduuidYes--Order id.
orderNostringYese.g. "RDOR202607000042"-รหัสอ้างอิง (RDOR + YYYYMM + ลำดับ 6 หลัก) ไม่ซ้ำกันในแต่ละ tenant
statusstringYes"CREATED", "PROCESSING", "IN_TRANSIT", "DELIVERED", "EXCEPTION", "ON_HOLD", "RETURNING", "RETURNED"-Lifecycle state.
fromCountrystringYesISO-2, e.g. "TH"-Origin, upper-cased.
toCountrystringYesISO-2, e.g. "US"-Destination, upper-cased.
serviceProviderstring---Chosen carrier, else null.
routeobject---Route milestone (ship-from / deliver-to).
fromobject---ที่อยู่ต้นทาง (ผู้ส่ง)
namestring---ชื่อผู้ติดต่อ
aliasstring---ชื่อเล่น/ป้ายกำกับ
isSenderboolean---Sender role.
isRecipientboolean---Recipient role.
phonePrefixstring---Dial code, digits only.
phoneNumberstring---National number.
emailstring---email ผู้ติดต่อ
addressLinestring---ถนน / บรรทัดที่อยู่
countryCodestring-ISO-2-Country.
postalCodestring---รหัสไปรษณีย์
provincestring---State / province.
districtstring---County / district.
citystring---City.
toobject---Deliver-to address.
namestring---ชื่อผู้ติดต่อ
aliasstring---ชื่อเล่น/ป้ายกำกับ
isSenderboolean---Sender role.
isRecipientboolean---Recipient role.
phonePrefixstring---Dial code, digits only.
phoneNumberstring---National number.
emailstring---email ผู้ติดต่อ
addressLinestring---ถนน / บรรทัดที่อยู่
countryCodestring-ISO-2-Country.
postalCodestring---รหัสไปรษณีย์
provincestring---State / province.
districtstring---County / district.
citystring---City.
exporterOfRecordobject---Exporter of Record ในฐานะตัวแทนทางอ้อม (ไม่บังคับ): ยื่นใบขนสินค้าขาออกในนามตนเองแทน Ship From ส่ง null หรือไม่ส่ง = ไม่มี จะถูกล็อกพร้อม route เมื่อออเดอร์ checkout แล้ว
addressBookIduuid---รายการใน Address Book ที่คัดลอกมา (ถ้ามี) ใช้เพื่ออ้างอิงเท่านั้น
namestringYes--ชื่อบริษัท ต้องระบุเมื่อส่ง object นี้มา
contactNamestring---ชื่อผู้ติดต่อ
phonePrefixstring---Dial code, digits only.
phonestring---National number.
emailstring---email ผู้ติดต่อ
addressLinestring---ถนน / บรรทัดที่อยู่
countryCodestringYesISO-2-ต้องเป็นประเทศเดียวกับฝั่งของตน: ประเทศของ Ship From สำหรับผู้ส่งออก และประเทศของ Ship To สำหรับผู้นำเข้า มิฉะนั้นจะได้ 409 error.order.route.recordCountry
postalCodestring---รหัสไปรษณีย์
provincestring---State / province.
districtstring---County / district.
citystring---City.
subDistrictstring---ตำบล / แขวง
customsRegNostring---เลขทะเบียนศุลกากร (EORI, เลขทะเบียนผู้ส่งออก / ผู้นำเข้าของไทย, …)
importerOfRecordobject---Importer of Record ในฐานะตัวแทนทางอ้อม (ไม่บังคับ): ผ่านพิธีการศุลกากรขาเข้าในนามตนเองแทน Ship To ส่ง null หรือไม่ส่ง = ไม่มี จะถูกล็อกพร้อม route เมื่อออเดอร์ checkout แล้ว
addressBookIduuid---รายการใน Address Book ที่คัดลอกมา (ถ้ามี) ใช้เพื่ออ้างอิงเท่านั้น
namestringYes--ชื่อบริษัท ต้องระบุเมื่อส่ง object นี้มา
contactNamestring---ชื่อผู้ติดต่อ
phonePrefixstring---Dial code, digits only.
phonestring---National number.
emailstring---email ผู้ติดต่อ
addressLinestring---ถนน / บรรทัดที่อยู่
countryCodestringYesISO-2-ต้องเป็นประเทศเดียวกับฝั่งของตน: ประเทศของ Ship From สำหรับผู้ส่งออก และประเทศของ Ship To สำหรับผู้นำเข้า มิฉะนั้นจะได้ 409 error.order.route.recordCountry
postalCodestring---รหัสไปรษณีย์
provincestring---State / province.
districtstring---County / district.
citystring---City.
subDistrictstring---ตำบล / แขวง
customsRegNostring---เลขทะเบียนศุลกากร (EORI, เลขทะเบียนผู้ส่งออก / ผู้นำเข้าของไทย, …)
packagesobject---Packages milestone.
itemsarray---The parcels.
idstring---Line id.
typestring-"box", "pallet", "envelope", "tube", "poly_mail", "container", "bulk_cargo"-Packaging type.
descriptionstring---Goods description.
quantitystring---Piece count (numeric string).
weightstring---Weight per piece (numeric string).
weightUnitstring-"kg", "lb"-Weight unit.
lengthstring---Length (numeric string).
widthstring---Width (numeric string).
heightstring---Height (numeric string).
dimUnitstring-"cm", "in"-หน่วยของขนาด
valuestring---Declared value (numeric string).
valueCurrencystring-"THB", "USD", "EUR", "GBP"-Declared-value currency.
goodsarray---ของที่อยู่ในพัสดุ ตรงกับบรรทัด Goods & declared value ใน Member Portal ควรใช้ส่วนนี้แทน description และ value ของแต่ละ item เพราะเมื่อมีส่วนนี้จะใช้เป็นมูลค่าที่สำแดงแทน
idstring---Line id.
descriptionstring---สินค้าคืออะไร
hsCodestring---HS code ของสินค้า ค้นหาได้ด้วย GET /hs-codes/search
valuestring---มูลค่าที่สำแดงของบรรทัดนี้ (สตริงตัวเลข)
currencystring-"THB", "USD", "EUR", "GBP"-Declared-value currency.
requireDocumentboolean-true, false-flag สถานะของ Package Documents — true = ต้องมีเอกสาร, false = ยืนยันแล้วว่า "ไม่ต้องมี", null = ยังไม่ได้ตั้งค่า ไม่ใช่ตัวไฟล์ (ไฟล์อยู่ใน `attachments`)
serviceobject---Service milestone (chosen rate + config).
providerIdstring---Chosen carrier id.
providerCodestring---Carrier code.
providerNamestring---Carrier display name.
priceobject---The quote Parcel Radar computed (POST /orders/{id}/service). Send it back unchanged.
thbnumber---Total price, THB.
zoneNamestring---Rated zone.
customsThbnumber---Customs component, THB.
pickupThbnumber---Pickup component, THB (optional).
shipDatestring-YYYY-MM-DD-Ship date.
pickupGroupIdstring---Pickup-option group (null = provider default).
pickupGroupNamestring---Pickup group name.
pickupAddressstring---Pickup address.
pickupInstructionsstring---Pickup instructions.
optionsarray---Selected service-option names (string[]).
referencesarray---Shipment references (string[]).
notestring---Internal note.
notificationsobject---Notifications milestone.
senderobject---Sender notification prefs.
emailstring---Notified email.
languagestring-"en", "th"-Email language.
optionsarray-"created", "in_transit", "delivered", "exception"-Events to notify on (string[]).
recipientsarray---Recipient notification prefs.
emailstring---Notified email.
languagestring-"en", "th"-Email language.
optionsarray-"created", "in_transit", "delivered", "exception"-Events to notify on (string[]).
createdAtstringYes--timestamp แบบ ISO-8601
updatedAtstringYes--timestamp แบบ ISO-8601
attachmentsarray---FILES ของเอกสารที่อัปโหลด (metadata) — ฝังไว้ในการ GET/PUT order รายการเดียว จะถูกละไว้เมื่อ order ไม่มีเอกสาร แยกจาก `requireDocument` (ตัวนั้นคือ flag สถานะ ส่วนอันนี้คือตัวไฟล์) จัดการผ่าน documents sub-resource ด้านล่าง
iduuidYes--id ของเอกสาร
namestringYes--ชื่อที่แสดง
descriptionstring---หมายเหตุ (ไม่บังคับ)
docTypestringYes"INVOICE", "RECEIPT", "TAX", "VAT", "PACKING_LIST", "CUSTOMS", "OTHER"-ประเภทของเอกสาร
contentTypestring---MIME type ตามที่อัปโหลด
sizeBytesnumberYes--ขนาดไฟล์หลังถอดรหัส หน่วยเป็น byte
createdAtstringYes--timestamp แบบ ISO-8601
ตัวอย่างการตอบกลับ
{
  "id": "af1326f0-eaf8-4dbd-801e-43d1daf99a23",
  "orderNo": "RDOR202607000039",
  "status": "PROCESSING",
  "fromCountry": "TH",
  "toCountry": "US",
  "serviceProvider": "DHL Express",
  "route": {
    "from": {
      "name": "Green Parker",
      "alias": "Office",
      "isSender": true,
      "isRecipient": false,
      "phonePrefix": "66",
      "phoneNumber": "973331702",
      "email": "green@acme.com",
      "addressLine": "514 Miriam Knolls",
      "countryCode": "TH",
      "postalCode": "10110",
      "province": "Bangkok",
      "district": "Watthana",
      "city": "Bangkok"
    },
    "to": {
      "name": "Martha Howell",
      "alias": "HQ",
      "isSender": false,
      "isRecipient": true,
      "phonePrefix": "1",
      "phoneNumber": "5692748790",
      "email": "martha@acme.com",
      "addressLine": "274 Wellington Road",
      "countryCode": "US",
      "postalCode": "90001",
      "province": "California",
      "district": "Los Angeles County",
      "city": "Los Angeles"
    }
  },
  "packages": {
    "items": [
      {
        "id": "pkg-1",
        "type": "box",
        "description": "Wooden soap",
        "quantity": "1",
        "weight": "1",
        "weightUnit": "kg",
        "length": "42.10",
        "width": "54.80",
        "height": "33.50",
        "dimUnit": "cm",
        "value": "457",
        "valueCurrency": "THB"
      }
    ]
  },
  "requireDocument": true,
  "service": {
    "providerId": "019e984a-f8b4-726f-8f02-0b51e7016f46",
    "providerCode": "RADIMEXP",
    "providerName": "DHL Express",
    "price": {
      "thb": 100,
      "zoneName": "Default",
      "customsThb": 0,
      "pickupThb": 0
    },
    "shipDate": "2026-07-19",
    "pickupGroupId": null,
    "pickupGroupName": null,
    "pickupAddress": "",
    "pickupInstructions": "Ring the bell at the front desk.",
    "options": [],
    "references": [
      "PO-412553",
      "REF-A9BSA"
    ],
    "note": "Handle with care."
  },
  "notifications": {
    "sender": {
      "email": "green@acme.com",
      "language": "en",
      "options": [
        "created",
        "in_transit",
        "delivered",
        "exception"
      ]
    },
    "recipients": [
      {
        "email": "martha@acme.com",
        "language": "en",
        "options": [
          "created",
          "delivered"
        ]
      }
    ]
  },
  "createdAt": "2026-07-17T09:45:27Z",
  "updatedAt": "2026-07-19T18:11:24Z",
  "attachments": [
    {
      "id": "7a1b9c2d-0e3f-4a5b-8c6d-9e0f1a2b3c4d",
      "name": "commercial-invoice.pdf",
      "description": "Signed invoice",
      "docType": "INVOICE",
      "contentType": "application/pdf",
      "sizeBytes": 20480,
      "createdAt": "2026-07-18T04:12:00Z"
    }
  ]
}
PUThttps://api-sandbox.parcelradar.io/api/partner/v1/orders/{id}

Update an order

แทนที่ทั้งออเดอร์ (PUT): ส่งออเดอร์ครบทุกส่วน ฟิลด์ที่ไม่ได้ส่งจะถูกล้าง สถานะไม่เปลี่ยน (ใช้ suspend) ราคาของ service (providerId, providerCode, providerName, price, fingerprint, pickupGroupId, pickupGroupName, hasPrinter) เป็นของ Parcel Radar: ตั้งค่าด้วย POST /orders/{id}/service แล้วส่งกลับมาโดยไม่แก้ไข (หรือไม่ส่ง service เพื่อล้าง)

ฟิลด์ประเภทจำเป็นค่าที่รับได้ค่าเริ่มต้นหมายเหตุ
fromCountrystringYesISO-2, in the country list-Origin. Must be in the country list; omitted or unknown → 400.
toCountrystringYesISO-2, in the country list-Destination. Must be in the country list; omitted or unknown → 400.
serviceProviderstringYes≤ 200 chars-Chosen carrier. Omitted → cleared to null.
routeobjectYes--Route milestone object. Omitted → cleared.
fromobject---ที่อยู่ต้นทาง (ผู้ส่ง)
namestring---ชื่อผู้ติดต่อ
aliasstring---ชื่อเล่น/ป้ายกำกับ
isSenderboolean---Sender role.
isRecipientboolean---Recipient role.
phonePrefixstring---Dial code, digits only.
phoneNumberstring---National number.
emailstring---email ผู้ติดต่อ
addressLinestring---ถนน / บรรทัดที่อยู่
countryCodestring-ISO-2-Country.
postalCodestring---รหัสไปรษณีย์
provincestring---State / province.
districtstring---County / district.
citystring---City.
toobject---Deliver-to address.
namestring---ชื่อผู้ติดต่อ
aliasstring---ชื่อเล่น/ป้ายกำกับ
isSenderboolean---Sender role.
isRecipientboolean---Recipient role.
phonePrefixstring---Dial code, digits only.
phoneNumberstring---National number.
emailstring---email ผู้ติดต่อ
addressLinestring---ถนน / บรรทัดที่อยู่
countryCodestring-ISO-2-Country.
postalCodestring---รหัสไปรษณีย์
provincestring---State / province.
districtstring---County / district.
citystring---City.
exporterOfRecordobject---Exporter of Record ในฐานะตัวแทนทางอ้อม (ไม่บังคับ): ยื่นใบขนสินค้าขาออกในนามตนเองแทน Ship From ส่ง null หรือไม่ส่ง = ไม่มี จะถูกล็อกพร้อม route เมื่อออเดอร์ checkout แล้ว
addressBookIduuid---รายการใน Address Book ที่คัดลอกมา (ถ้ามี) ใช้เพื่ออ้างอิงเท่านั้น
namestringYes--ชื่อบริษัท ต้องระบุเมื่อส่ง object นี้มา
contactNamestring---ชื่อผู้ติดต่อ
phonePrefixstring---Dial code, digits only.
phonestring---National number.
emailstring---email ผู้ติดต่อ
addressLinestring---ถนน / บรรทัดที่อยู่
countryCodestringYesISO-2-ต้องเป็นประเทศเดียวกับฝั่งของตน: ประเทศของ Ship From สำหรับผู้ส่งออก และประเทศของ Ship To สำหรับผู้นำเข้า มิฉะนั้นจะได้ 409 error.order.route.recordCountry
postalCodestring---รหัสไปรษณีย์
provincestring---State / province.
districtstring---County / district.
citystring---City.
subDistrictstring---ตำบล / แขวง
customsRegNostring---เลขทะเบียนศุลกากร (EORI, เลขทะเบียนผู้ส่งออก / ผู้นำเข้าของไทย, …)
importerOfRecordobject---Importer of Record ในฐานะตัวแทนทางอ้อม (ไม่บังคับ): ผ่านพิธีการศุลกากรขาเข้าในนามตนเองแทน Ship To ส่ง null หรือไม่ส่ง = ไม่มี จะถูกล็อกพร้อม route เมื่อออเดอร์ checkout แล้ว
addressBookIduuid---รายการใน Address Book ที่คัดลอกมา (ถ้ามี) ใช้เพื่ออ้างอิงเท่านั้น
namestringYes--ชื่อบริษัท ต้องระบุเมื่อส่ง object นี้มา
contactNamestring---ชื่อผู้ติดต่อ
phonePrefixstring---Dial code, digits only.
phonestring---National number.
emailstring---email ผู้ติดต่อ
addressLinestring---ถนน / บรรทัดที่อยู่
countryCodestringYesISO-2-ต้องเป็นประเทศเดียวกับฝั่งของตน: ประเทศของ Ship From สำหรับผู้ส่งออก และประเทศของ Ship To สำหรับผู้นำเข้า มิฉะนั้นจะได้ 409 error.order.route.recordCountry
postalCodestring---รหัสไปรษณีย์
provincestring---State / province.
districtstring---County / district.
citystring---City.
subDistrictstring---ตำบล / แขวง
customsRegNostring---เลขทะเบียนศุลกากร (EORI, เลขทะเบียนผู้ส่งออก / ผู้นำเข้าของไทย, …)
packagesobjectYes--Packages milestone object. Omitted → cleared.
itemsarray---The parcels.
idstring---Line id.
typestring-"box", "pallet", "envelope", "tube", "poly_mail", "container", "bulk_cargo"-Packaging type.
descriptionstring---Goods description.
quantitystring---Piece count (numeric string).
weightstring---Weight per piece (numeric string).
weightUnitstring-"kg", "lb"-Weight unit.
lengthstring---Length (numeric string).
widthstring---Width (numeric string).
heightstring---Height (numeric string).
dimUnitstring-"cm", "in"-หน่วยของขนาด
valuestring---Declared value (numeric string).
valueCurrencystring-"THB", "USD", "EUR", "GBP"-Declared-value currency.
goodsarray---ของที่อยู่ในพัสดุ ตรงกับบรรทัด Goods & declared value ใน Member Portal ควรใช้ส่วนนี้แทน description และ value ของแต่ละ item เพราะเมื่อมีส่วนนี้จะใช้เป็นมูลค่าที่สำแดงแทน
idstring---Line id.
descriptionstring---สินค้าคืออะไร
hsCodestring---HS code ของสินค้า ค้นหาได้ด้วย GET /hs-codes/search
valuestring---มูลค่าที่สำแดงของบรรทัดนี้ (สตริงตัวเลข)
currencystring-"THB", "USD", "EUR", "GBP"-Declared-value currency.
requireDocumentboolean-true, false-flag สถานะของ Package Documents (true = ต้องมี, false = "ไม่ต้องมี", ไม่ส่ง = ถูกล้าง) หากต้องการเพิ่มไฟล์ ให้ใช้ `attachments` ด้านล่าง (หรือ documents sub-resource)
serviceobjectYes--Service milestone object. Omitted → cleared.
providerIdstring---Chosen carrier id.
providerCodestring---Carrier code.
providerNamestring---Carrier display name.
priceobject---The quote Parcel Radar computed (POST /orders/{id}/service). Send it back unchanged.
thbnumber---Total price, THB.
zoneNamestring---Rated zone.
customsThbnumber---Customs component, THB.
pickupThbnumber---Pickup component, THB (optional).
shipDatestring-YYYY-MM-DD-Ship date.
pickupGroupIdstring---Pickup-option group (null = provider default).
pickupGroupNamestring---Pickup group name.
pickupAddressstring---Pickup address.
pickupInstructionsstring---Pickup instructions.
optionsarray---Selected service-option names (string[]).
referencesarray---Shipment references (string[]).
notestring---Internal note.
notificationsobjectYes--Notifications milestone object. Omitted → cleared.
senderobject---Sender notification prefs.
emailstring---Notified email.
languagestring-"en", "th"-Email language.
optionsarray-"created", "in_transit", "delivered", "exception"-Events to notify on (string[]).
recipientsarray---Recipient notification prefs.
emailstring---Notified email.
languagestring-"en", "th"-Email language.
optionsarray-"created", "in_transit", "delivered", "exception"-Events to notify on (string[]).
attachmentsarray---ไฟล์เอกสาร (base64) แบบไม่บังคับที่จะ ADD ในการเรียกครั้งนี้ — เป็นการต่อท้าย ไม่ใช่การแทนที่ (เอกสารเดิมยังอยู่; นำออกด้วย DELETE ของ sub-resource) แต่ละรายการคือ upload body และการตอบกลับจะฝังรายการผลลัพธ์ไว้
namestringYes≤ 200 chars-ชื่อที่แสดง
descriptionstring-≤ 500 chars-หมายเหตุ (ไม่บังคับ)
docTypestringYes"INVOICE", "RECEIPT", "TAX", "VAT", "PACKING_LIST", "CUSTOMS", "OTHER"-หนึ่งในประเภทของเอกสาร
contentBase64stringYes--byte ของไฟล์แบบ base64 (ยอมรับ prefix แบบ `data:…;base64,`) หลังถอดรหัส ≤ 10 MB
contentTypestring-≤ 200 chars-MIME type (เช่น application/pdf)
ตัวอย่างคำขอ
{
  "fromCountry": "TH",
  "toCountry": "DE",
  "serviceProvider": "DHL",
  "route": {
    "from": {
      "name": "Green Parker",
      "isSender": true,
      "isRecipient": false,
      "phonePrefix": "66",
      "phoneNumber": "973331702",
      "email": "green@acme.com",
      "addressLine": "514 Miriam Knolls",
      "countryCode": "TH",
      "postalCode": "10110",
      "province": "Bangkok",
      "district": "Watthana",
      "city": "Bangkok"
    },
    "to": {
      "name": "Jonas Becker",
      "isSender": false,
      "isRecipient": true,
      "phonePrefix": "49",
      "phoneNumber": "3012345678",
      "email": "jonas@example.de",
      "addressLine": "Torstrasse 101",
      "countryCode": "DE",
      "postalCode": "10119",
      "province": "Berlin",
      "district": "Mitte",
      "city": "Berlin"
    },
    "exporterOfRecord": {
      "name": "Siam Export Co., Ltd.",
      "contactName": "Somchai Jaidee",
      "phonePrefix": "66",
      "phone": "21234567",
      "email": "export@siamexport.co.th",
      "addressLine": "99 Rama IV Road",
      "countryCode": "TH",
      "postalCode": "10500",
      "province": "Bangkok",
      "district": "Bang Rak",
      "city": "Bangkok",
      "subDistrict": "Suriyawong",
      "customsRegNo": "0105551234567"
    },
    "importerOfRecord": {
      "addressBookId": "5b1f0c3a-7e2d-4c9b-a1f4-3d8e6b2c9a10",
      "name": "Hanse Zollservice GmbH",
      "contactName": "Anna Schmidt",
      "phonePrefix": "49",
      "phone": "40123456",
      "email": "zoll@hanse-zoll.de",
      "addressLine": "Am Sandtorkai 12",
      "countryCode": "DE",
      "postalCode": "20457",
      "province": "Hamburg",
      "city": "Hamburg",
      "customsRegNo": "DE123456789012345"
    }
  },
  "packages": {
    "items": []
  },
  "requireDocument": true,
  "service": null,
  "notifications": null,
  "attachments": [
    {
      "name": "commercial-invoice.pdf",
      "docType": "INVOICE",
      "contentType": "application/pdf",
      "contentBase64": "JVBERi0xLjcKJ..."
    }
  ]
}
POSThttps://api-sandbox.parcelradar.io/api/partner/v1/orders/{id}/suspend

Suspend an order

Put an order on hold (→ ON_HOLD). Only from CREATED or PROCESSING.

ฟิลด์ประเภทจำเป็นค่าที่รับได้ค่าเริ่มต้นหมายเหตุ
iduuidYes--Order id.
orderNostringYese.g. "RDOR202607000042"-รหัสอ้างอิง (RDOR + YYYYMM + ลำดับ 6 หลัก) ไม่ซ้ำกันในแต่ละ tenant
statusstringYes"CREATED", "PROCESSING", "IN_TRANSIT", "DELIVERED", "EXCEPTION", "ON_HOLD", "RETURNING", "RETURNED"-Lifecycle state.
fromCountrystringYesISO-2, e.g. "TH"-Origin, upper-cased.
toCountrystringYesISO-2, e.g. "US"-Destination, upper-cased.
serviceProviderstring---Chosen carrier, else null.
routeobject---Route milestone (ship-from / deliver-to).
fromobject---ที่อยู่ต้นทาง (ผู้ส่ง)
namestring---ชื่อผู้ติดต่อ
aliasstring---ชื่อเล่น/ป้ายกำกับ
isSenderboolean---Sender role.
isRecipientboolean---Recipient role.
phonePrefixstring---Dial code, digits only.
phoneNumberstring---National number.
emailstring---email ผู้ติดต่อ
addressLinestring---ถนน / บรรทัดที่อยู่
countryCodestring-ISO-2-Country.
postalCodestring---รหัสไปรษณีย์
provincestring---State / province.
districtstring---County / district.
citystring---City.
toobject---Deliver-to address.
namestring---ชื่อผู้ติดต่อ
aliasstring---ชื่อเล่น/ป้ายกำกับ
isSenderboolean---Sender role.
isRecipientboolean---Recipient role.
phonePrefixstring---Dial code, digits only.
phoneNumberstring---National number.
emailstring---email ผู้ติดต่อ
addressLinestring---ถนน / บรรทัดที่อยู่
countryCodestring-ISO-2-Country.
postalCodestring---รหัสไปรษณีย์
provincestring---State / province.
districtstring---County / district.
citystring---City.
exporterOfRecordobject---Exporter of Record ในฐานะตัวแทนทางอ้อม (ไม่บังคับ): ยื่นใบขนสินค้าขาออกในนามตนเองแทน Ship From ส่ง null หรือไม่ส่ง = ไม่มี จะถูกล็อกพร้อม route เมื่อออเดอร์ checkout แล้ว
addressBookIduuid---รายการใน Address Book ที่คัดลอกมา (ถ้ามี) ใช้เพื่ออ้างอิงเท่านั้น
namestringYes--ชื่อบริษัท ต้องระบุเมื่อส่ง object นี้มา
contactNamestring---ชื่อผู้ติดต่อ
phonePrefixstring---Dial code, digits only.
phonestring---National number.
emailstring---email ผู้ติดต่อ
addressLinestring---ถนน / บรรทัดที่อยู่
countryCodestringYesISO-2-ต้องเป็นประเทศเดียวกับฝั่งของตน: ประเทศของ Ship From สำหรับผู้ส่งออก และประเทศของ Ship To สำหรับผู้นำเข้า มิฉะนั้นจะได้ 409 error.order.route.recordCountry
postalCodestring---รหัสไปรษณีย์
provincestring---State / province.
districtstring---County / district.
citystring---City.
subDistrictstring---ตำบล / แขวง
customsRegNostring---เลขทะเบียนศุลกากร (EORI, เลขทะเบียนผู้ส่งออก / ผู้นำเข้าของไทย, …)
importerOfRecordobject---Importer of Record ในฐานะตัวแทนทางอ้อม (ไม่บังคับ): ผ่านพิธีการศุลกากรขาเข้าในนามตนเองแทน Ship To ส่ง null หรือไม่ส่ง = ไม่มี จะถูกล็อกพร้อม route เมื่อออเดอร์ checkout แล้ว
addressBookIduuid---รายการใน Address Book ที่คัดลอกมา (ถ้ามี) ใช้เพื่ออ้างอิงเท่านั้น
namestringYes--ชื่อบริษัท ต้องระบุเมื่อส่ง object นี้มา
contactNamestring---ชื่อผู้ติดต่อ
phonePrefixstring---Dial code, digits only.
phonestring---National number.
emailstring---email ผู้ติดต่อ
addressLinestring---ถนน / บรรทัดที่อยู่
countryCodestringYesISO-2-ต้องเป็นประเทศเดียวกับฝั่งของตน: ประเทศของ Ship From สำหรับผู้ส่งออก และประเทศของ Ship To สำหรับผู้นำเข้า มิฉะนั้นจะได้ 409 error.order.route.recordCountry
postalCodestring---รหัสไปรษณีย์
provincestring---State / province.
districtstring---County / district.
citystring---City.
subDistrictstring---ตำบล / แขวง
customsRegNostring---เลขทะเบียนศุลกากร (EORI, เลขทะเบียนผู้ส่งออก / ผู้นำเข้าของไทย, …)
packagesobject---Packages milestone.
itemsarray---The parcels.
idstring---Line id.
typestring-"box", "pallet", "envelope", "tube", "poly_mail", "container", "bulk_cargo"-Packaging type.
descriptionstring---Goods description.
quantitystring---Piece count (numeric string).
weightstring---Weight per piece (numeric string).
weightUnitstring-"kg", "lb"-Weight unit.
lengthstring---Length (numeric string).
widthstring---Width (numeric string).
heightstring---Height (numeric string).
dimUnitstring-"cm", "in"-หน่วยของขนาด
valuestring---Declared value (numeric string).
valueCurrencystring-"THB", "USD", "EUR", "GBP"-Declared-value currency.
goodsarray---ของที่อยู่ในพัสดุ ตรงกับบรรทัด Goods & declared value ใน Member Portal ควรใช้ส่วนนี้แทน description และ value ของแต่ละ item เพราะเมื่อมีส่วนนี้จะใช้เป็นมูลค่าที่สำแดงแทน
idstring---Line id.
descriptionstring---สินค้าคืออะไร
hsCodestring---HS code ของสินค้า ค้นหาได้ด้วย GET /hs-codes/search
valuestring---มูลค่าที่สำแดงของบรรทัดนี้ (สตริงตัวเลข)
currencystring-"THB", "USD", "EUR", "GBP"-Declared-value currency.
requireDocumentboolean-true, false-flag สถานะของ Package Documents — true = ต้องมีเอกสาร, false = ยืนยันแล้วว่า "ไม่ต้องมี", null = ยังไม่ได้ตั้งค่า ไม่ใช่ตัวไฟล์ (ไฟล์อยู่ใน `attachments`)
serviceobject---Service milestone (chosen rate + config).
providerIdstring---Chosen carrier id.
providerCodestring---Carrier code.
providerNamestring---Carrier display name.
priceobject---The quote Parcel Radar computed (POST /orders/{id}/service). Send it back unchanged.
thbnumber---Total price, THB.
zoneNamestring---Rated zone.
customsThbnumber---Customs component, THB.
pickupThbnumber---Pickup component, THB (optional).
shipDatestring-YYYY-MM-DD-Ship date.
pickupGroupIdstring---Pickup-option group (null = provider default).
pickupGroupNamestring---Pickup group name.
pickupAddressstring---Pickup address.
pickupInstructionsstring---Pickup instructions.
optionsarray---Selected service-option names (string[]).
referencesarray---Shipment references (string[]).
notestring---Internal note.
notificationsobject---Notifications milestone.
senderobject---Sender notification prefs.
emailstring---Notified email.
languagestring-"en", "th"-Email language.
optionsarray-"created", "in_transit", "delivered", "exception"-Events to notify on (string[]).
recipientsarray---Recipient notification prefs.
emailstring---Notified email.
languagestring-"en", "th"-Email language.
optionsarray-"created", "in_transit", "delivered", "exception"-Events to notify on (string[]).
createdAtstringYes--timestamp แบบ ISO-8601
updatedAtstringYes--timestamp แบบ ISO-8601
attachmentsarray---FILES ของเอกสารที่อัปโหลด (metadata) — ฝังไว้ในการ GET/PUT order รายการเดียว จะถูกละไว้เมื่อ order ไม่มีเอกสาร แยกจาก `requireDocument` (ตัวนั้นคือ flag สถานะ ส่วนอันนี้คือตัวไฟล์) จัดการผ่าน documents sub-resource ด้านล่าง
iduuidYes--id ของเอกสาร
namestringYes--ชื่อที่แสดง
descriptionstring---หมายเหตุ (ไม่บังคับ)
docTypestringYes"INVOICE", "RECEIPT", "TAX", "VAT", "PACKING_LIST", "CUSTOMS", "OTHER"-ประเภทของเอกสาร
contentTypestring---MIME type ตามที่อัปโหลด
sizeBytesnumberYes--ขนาดไฟล์หลังถอดรหัส หน่วยเป็น byte
createdAtstringYes--timestamp แบบ ISO-8601
ตัวอย่างการตอบกลับ
{
  "id": "3f9a1c62-8d47-4a1e-9b0c-2e5f6a7b8c90",
  "orderNo": "RDOR202607000042",
  "status": "ON_HOLD",
  "fromCountry": "TH",
  "toCountry": "US",
  "serviceProvider": null,
  "route": null,
  "packages": null,
  "requireDocument": null,
  "service": null,
  "notifications": null,
  "createdAt": "2026-07-16T09:00:00Z",
  "updatedAt": "2026-07-16T13:40:00Z"
}

Service & drop-off

แท็บ Service Details: ตัวเลือกรับพัสดุถึงที่และนำส่งเอง และ extra services ของผู้ให้บริการสำหรับออเดอร์ ค่ารับพัสดุแบบ API-cost และจุดรับพัสดุ จากนั้น POST /orders/{id}/service จะบันทึกสิ่งที่เลือกและ Parcel Radar คำนวณราคาให้ คุณไม่ต้องส่งราคาเอง

GEThttps://api-sandbox.parcelradar.io/api/partner/v1/orders/{id}/service-options

ดูตัวเลือกรับถึงที่และนำส่งเองของผู้ให้บริการ

ตัวเลือกที่ Member Portal แสดงใต้แต่ละราคา: หนึ่งรายการต่อกลุ่มตัวเลือกรับพัสดุ คิดราคาจาก packages ที่บันทึกไว้ของออเดอร์ เรียงจากถูกสุด และ extra services ของผู้ให้บริการพร้อมราคา ส่ง `groupId` ที่เลือกไปที่ POST /orders/{id}/service ซึ่งจะกำหนดว่า Shipment Label จะจองคูเรียร์หรือพิมพ์ carton mark สำหรับนำส่งเอง

ฟิลด์ประเภทจำเป็นค่าที่รับได้ค่าเริ่มต้นหมายเหตุ
providerIduuidYes--A provider id from a Live Rates result.
POSThttps://api-sandbox.parcelradar.io/api/partner/v1/orders/{id}/pickup/quote

ขอราคาค่ารับพัสดุแบบ API-cost

สำหรับตัวเลือกที่ costMode เป็น api_markup: ราคารับพัสดุของคูเรียร์สำหรับพัสดุของออเดอร์นี้บวก markup ของเรา ส่ง `quoteId` เป็น `pickupQuoteId` ไปที่ POST /orders/{id}/service เพื่อใช้ค่ารับพัสดุนี้ ซึ่งใช้ได้ตราบที่ออเดอร์ไม่มีการเปลี่ยนแปลงและใบเสนอราคายังใช้ได้ มิฉะนั้นจะขอราคาคูเรียร์ใหม่ (ส่ง `from` เดิมเป็น `pickupFrom`) ได้ `available: false` (พร้อม `reason`) เมื่อไม่มีคูเรียร์ในกลุ่มเสนอราคาได้

ฟิลด์ประเภทจำเป็นค่าที่รับได้ค่าเริ่มต้นหมายเหตุ
providerIduuidYes--The service's provider.
groupIduuidYes--The option's groupId.
fromobject---A "Pick up from" other than the order's Ship-From.
namestringYes--ชื่อผู้ติดต่อ
phonestringYes--Phone the courier calls, e.g. "0812345678".
addressstringYes--House number, building, street.
subDistrictstringYes--Tambon / khwaeng (ตำบล / แขวง), in Thai.
districtstringYes--Amphoe / khet (อำเภอ / เขต), in Thai.
provincestringYes--Province (จังหวัด), in Thai.
zipcodestringYes5 digits-Postcode.
ตัวอย่างคำขอ
{
  "providerId": "019e984a-f8b4-726f-8f02-0b51e7016f46",
  "groupId": "a7c4e3d2-1b0a-4f9e-8d7c-6b5a4f3e2d1c"
}
POSThttps://api-sandbox.parcelradar.io/api/partner/v1/orders/{id}/service

เลือกบริการขนส่ง (Parcel Radar คำนวณราคา)

บันทึกบริการขนส่งของออเดอร์แบบเดียวกับแท็บ Service ใน Member Portal: ระบุผู้ให้บริการ กลุ่มตัวเลือกรับพัสดุ และ extra services แล้ว Parcel Radar จะคำนวณราคาให้ ทั้งค่าขนส่ง (เรียกคูเรียร์แบบ live ตอนนั้น) ค่ารับพัสดุ และ extra services ตามอัตราสมาชิกและแคมเปญของคุณ (ออเดอร์ที่สร้างจากใบเสนอราคาจะใช้ราคาตามใบเสนอราคาขณะที่ใบเสนอราคายังไม่หมดอายุ และพัสดุไม่หนักกว่า ไม่ไกลกว่า และมูลค่าไม่สูงกว่าที่เสนอราคาไว้) คุณไม่ต้องส่งราคาเอง และ PUT /orders/{id} จะปฏิเสธราคาที่ส่งมา ใช้ได้ก่อน checkout เท่านั้น (CREATED หรือ PENDING_FUNDING) ให้เรียกอีกครั้งหลังแก้ route หรือ packages ฟิลด์ที่ไม่ได้ส่งจะคงค่าที่บันทึกไว้ ผลลัพธ์คือออเดอร์ในรูปแบบเดียวกับ GET /orders/{id}

ฟิลด์ประเภทจำเป็นค่าที่รับได้ค่าเริ่มต้นหมายเหตุ
providerIduuidYes--A provider id from a Live Rates result for this order.
pickupGroupIduuid---An option's groupId from service-options. Omitted = the provider's default path (the option with groupId null), which must exist.
pickupFromobject---For an api_markup option: the "Pick up from" the courier is quoted from, when not the order's Ship-From.
namestringYes--ชื่อผู้ติดต่อ
phonestringYes--Phone the courier calls, e.g. "0812345678".
addressstringYes--House number, building, street.
subDistrictstringYes--Tambon / khwaeng (ตำบล / แขวง), in Thai.
districtstringYes--Amphoe / khet (อำเภอ / เขต), in Thai.
provincestringYes--Province (จังหวัด), in Thai.
zipcodestringYes5 digits-Postcode.
pickupQuoteIduuid---For an api_markup option: the quoteId from POST /orders/{id}/pickup/quote, to keep the fee you were shown. Used while nothing on the order changed since; otherwise the courier is asked again.
optionsarray-≤ 20-Extra services, by id or name from service-options (string[]).
hasPrinterboolean---Whether you can print the courier's label, for an option that asks. Omitted = not asked (none is kept).
shipDatestring-YYYY-MM-DD-Ship date.
pickupAddressstring-≤ 500 chars-Pickup address note.
pickupInstructionsstring-≤ 500 chars-Instructions to the courier.
referencesarray-≤ 20, each ≤ 100 chars-Your shipment references (string[]).
notestring-≤ 500 chars-A note.
ตัวอย่างคำขอ
{
  "providerId": "019e984a-f8b4-726f-8f02-0b51e7016f46",
  "pickupGroupId": "a7c4e3d2-1b0a-4f9e-8d7c-6b5a4f3e2d1c",
  "options": [
    "Insurance"
  ],
  "shipDate": "2026-11-06",
  "references": [
    "PO-412553"
  ]
}
GEThttps://api-sandbox.parcelradar.io/api/partner/v1/dropoff-points

ดูจุดรับพัสดุสำหรับออเดอร์

The Shops and Warehouses the order may be dropped off at, nearest first (same postcode, district, province, then name), with the provinces to filter by.

ฟิลด์ประเภทจำเป็นค่าที่รับได้ค่าเริ่มต้นหมายเหตุ
orderIduuidYes--The order.
qstring---Name or address contains.
provincestring---Only this province.
pagenumber->= 00Zero-based page.
sizenumber-1–5020Page size.
PUThttps://api-sandbox.parcelradar.io/api/partner/v1/orders/{id}/dropoff-point

เลือกจุดรับพัสดุ

Pick, change or clear (`tenantId: null`) where the parcel will be brought, from CREATED until the parcel is received.

ฟิลด์ประเภทจำเป็นค่าที่รับได้ค่าเริ่มต้นหมายเหตุ
tenantIduuid---A point from GET /dropoff-points; null clears the pick.
ตัวอย่างคำขอ
{
  "tenantId": "d1c2b3a4-0000-4000-8000-000000000001"
}

Order Documents

ไฟล์ที่แนบกับ Package Documents ของ order (invoice, packing list, …) โดย byte จะส่งแบบ base64 — ไม่ใช่ multipart และยังฝังไว้เป็น `attachments` ในการ GET order รายการเดียว

GEThttps://api-sandbox.parcelradar.io/api/partner/v1/orders/{orderId}/documents

แสดงรายการเอกสารของ order

Package Documents ที่อัปโหลดไว้ของ order (เฉพาะ metadata เรียงจากใหม่สุดก่อน) นี่คือ FILES — แยกจาก `documents` milestone (สถานะ JSON ของแท็บ) รายการเดียวกันนี้ถูกฝังไว้เป็น `attachments` ในการ GET order รายการเดียว

ฟิลด์ประเภทจำเป็นค่าที่รับได้ค่าเริ่มต้นหมายเหตุ
iduuidYes--id ของเอกสาร
namestringYes--ชื่อที่แสดง
descriptionstring---หมายเหตุ (ไม่บังคับ)
docTypestringYes"INVOICE", "RECEIPT", "TAX", "VAT", "PACKING_LIST", "CUSTOMS", "OTHER"-ประเภทของเอกสาร
contentTypestring---MIME type ตามที่อัปโหลด
sizeBytesnumberYes--ขนาดไฟล์หลังถอดรหัส หน่วยเป็น byte
createdAtstringYes--timestamp แบบ ISO-8601
ตัวอย่างการตอบกลับ
[
  {
    "id": "7a1b9c2d-0e3f-4a5b-8c6d-9e0f1a2b3c4d",
    "name": "commercial-invoice.pdf",
    "description": "Signed invoice",
    "docType": "INVOICE",
    "contentType": "application/pdf",
    "sizeBytes": 20480,
    "createdAt": "2026-07-18T04:12:00Z"
  }
]
POSThttps://api-sandbox.parcelradar.io/api/partner/v1/orders/{orderId}/documents

อัปโหลดเอกสารของ order

แนบไฟล์เข้ากับ order โดย byte จะส่งเป็น base64 ใน `contentBase64` (ยอมรับ prefix แบบ `data:…;base64,`) — เป็น JSON ธรรมดา ไม่ใช่ multipart ขนาดหลังถอดรหัส ≤ 10 MB

ฟิลด์ประเภทจำเป็นค่าที่รับได้ค่าเริ่มต้นหมายเหตุ
namestringYes≤ 200 chars-ชื่อที่แสดง
descriptionstring-≤ 500 chars-หมายเหตุ (ไม่บังคับ)
docTypestringYes"INVOICE", "RECEIPT", "TAX", "VAT", "PACKING_LIST", "CUSTOMS", "OTHER"-หนึ่งในประเภทของเอกสาร
contentBase64stringYes--byte ของไฟล์แบบ base64 (ยอมรับ prefix แบบ `data:…;base64,`) หลังถอดรหัส ≤ 10 MB
contentTypestring-≤ 200 chars-MIME type (เช่น application/pdf)
ตัวอย่างคำขอ
{
  "name": "commercial-invoice.pdf",
  "description": "Signed invoice",
  "docType": "INVOICE",
  "contentType": "application/pdf",
  "contentBase64": "JVBERi0xLjcKJ..."
}
PUThttps://api-sandbox.parcelradar.io/api/partner/v1/orders/{orderId}/documents/{docId}

อัปเดตเอกสาร

แทนที่ metadata ของเอกสาร (name / description / docType) ใส่ `contentBase64` เพื่อแทนที่ byte ของไฟล์ด้วย; ไม่ใส่เพื่อคงไฟล์ที่จัดเก็บไว้

ฟิลด์ประเภทจำเป็นค่าที่รับได้ค่าเริ่มต้นหมายเหตุ
namestringYes≤ 200 chars-ชื่อที่แสดง
descriptionstring-≤ 500 chars-หมายเหตุ (ไม่บังคับ)
docTypestringYes"INVOICE", "RECEIPT", "TAX", "VAT", "PACKING_LIST", "CUSTOMS", "OTHER"-หนึ่งในประเภทของเอกสาร
contentBase64string---byte ของไฟล์ใหม่ (base64) เพื่อแทนที่ค่าที่จัดเก็บไว้; ไม่ใส่/เว้นว่างเพื่อคงค่าเดิม หลังถอดรหัส ≤ 10 MB
contentTypestring-≤ 200 chars-MIME type ของ byte ที่ใช้แทนที่
ตัวอย่างคำขอ
{
  "name": "commercial-invoice-v2.pdf",
  "description": "Re-signed invoice",
  "docType": "INVOICE"
}
GEThttps://api-sandbox.parcelradar.io/api/partner/v1/orders/{orderId}/documents/{docId}

ดาวน์โหลดเอกสาร

ดึงเอกสารหนึ่งรายการพร้อม byte ของมัน (base64) ถอดรหัส `contentBase64` เป็น Blob/ไฟล์ แล้วบันทึกด้วยชื่อ `name`

ฟิลด์ประเภทจำเป็นค่าที่รับได้ค่าเริ่มต้นหมายเหตุ
namestringYes--ชื่อที่แสดง (บันทึกไฟล์ด้วยชื่อนี้)
contentTypestring---MIME type ตามที่อัปโหลด
contentBase64stringYes--byte ของไฟล์แบบ base64 — ถอดรหัสเป็น Blob/ไฟล์
ตัวอย่างการตอบกลับ
{
  "name": "commercial-invoice.pdf",
  "contentType": "application/pdf",
  "contentBase64": "JVBERi0xLjcKJ..."
}
DELETEhttps://api-sandbox.parcelradar.io/api/partner/v1/orders/{orderId}/documents/{docId}

ลบเอกสาร

นำเอกสารออกจาก order

ฟิลด์ประเภทจำเป็นค่าที่รับได้ค่าเริ่มต้นหมายเหตุ

Checkout

แท็บ Checkout: อ่านยอดรวม ยอมรับเงื่อนไขของผู้ให้บริการ แล้วกันยอดรวมไว้ใน wallet ของ workspace (→ SUBMITTED) เงินจะถูกตัดเมื่อเจ้าหน้าที่อนุมัติการจัดส่ง ก่อนหน้านั้นการ withdraw จะคืนยอดที่กันไว้

GEThttps://api-sandbox.parcelradar.io/api/partner/v1/orders/{id}/checkout

ดูข้อมูล checkout

What checkout would hold, whether the wallet covers it, and whether the conditions are accepted. Changes nothing; safe to poll. Echo `fingerprint` and `amount` into POST /checkout.

ฟิลด์ประเภทจำเป็นค่าที่รับได้ค่าเริ่มต้นหมายเหตุ
orderIduuidYes--The order.
orderNostringYes--Its number.
statusstringYes--The order's status.
amountnumberYes--The total checkout holds (VAT included), THB. Send it back as `expectedAmount`.
vatTotalnumber---The VAT inside `amount`: 7 % on Parcel Radar's own fees (pickup, extra services) only. The carrier's charge and the duties & taxes on the goods carry no VAT — goods exported from Thailand are VAT-free, and the destination duty is passed through as priced. Read it from here; never add VAT on top of the duties yourself.
additionalCostsTotalnumber---Officer-added costs inside `amount` (0 when none).
currencystringYes--"THB".
walletBalancenumber---The prepaid wallet's balance.
walletAvailablenumber---Balance minus credit held by other orders.
sufficientbooleanYes--Whether the prepaid wallet covers `amount`.
alreadyChargedbooleanYes--true once the order is checked out.
fingerprintstring---The quote being charged. Send it back as `fingerprint`.
conditionsAcceptedbooleanYes--Whether the selected provider's conditions are accepted. Checkout refuses until they are.
accountsarrayYes--Every account that could pay — PREPAID first, then an ADVANCE credit line if the workspace has one. Pick one by its `accountId`.
accountIduuid---Send it as `accountId` to POST /checkout to charge this account. null only on a Prepaid wallet never opened yet — omitting `accountId` charges that one too.
accountTypestringYes"PREPAID", "ADVANCE"-PREPAID = your workspace's own money (topped up in the Member Portal). ADVANCE = a credit line Parcel Radar granted, repaid on its bill.
balancenumberYes--The account's balance, THB.
reservednumberYes--Held by your other checked-out orders.
availablenumberYes--Spendable now: what this checkout is judged against.
creditLimitnumber---ADVANCE only: the granted ceiling. null on PREPAID.
outstandingnumber---ADVANCE only: drawn and not yet repaid. null on PREPAID.
currencystringYes--"THB".
sufficientbooleanYes--Whether this account can pay `amount` now: enough available AND no credit hold. Parcel Radar's verdict — check out with an account where it is true.
creditHeldbooleanYes--ADVANCE only: a credit hold refuses this account whatever its balance (409 error.wallet.creditHeld / error.credit.parentOverAllocated). Always false on PREPAID.
creditHeldReasonstring-"GROUP_HOLD", "WRITE_OFF", "OVERDUE", "PARENT_OVER_ALLOCATED", null-Why the hold: a group hold, a write-off, an overdue bill, or the parent group's line below its allocations.
chargedAccountIduuid---Once checked out: the account the hold sits on. null before.
chargedAccountTypestring-"PREPAID", "ADVANCE", null-Its kind.
payerNamestring---The workspace that pays: always the order's own (a super portal never pays for a sub-portal's order).
withdrawBlockedByBookingboolean---true while a live courier booking stops a withdraw (cancel the booking first).
ตัวอย่างการตอบกลับ
{
  "orderId": "3f9a1c62-8d47-4a1e-9b0c-2e5f6a7b8c90",
  "orderNo": "RDOR202611000042",
  "status": "CREATED",
  "amount": 1240,
  "vatTotal": 81.12,
  "additionalCostsTotal": 0,
  "currency": "THB",
  "walletBalance": 5000,
  "walletAvailable": 5000,
  "sufficient": true,
  "alreadyCharged": false,
  "fingerprint": "{\"origin\":{\"country\":\"TH\",…}}",
  "conditionsAccepted": false,
  "accounts": [
    {
      "accountId": "a1b2c3d4-0000-4000-8000-0000000000a1",
      "accountType": "PREPAID",
      "balance": 5000,
      "reserved": 0,
      "available": 5000,
      "creditLimit": null,
      "outstanding": null,
      "currency": "THB",
      "sufficient": true,
      "creditHeld": false,
      "creditHeldReason": null
    },
    {
      "accountId": "a1b2c3d4-0000-4000-8000-0000000000a2",
      "accountType": "ADVANCE",
      "balance": 60000,
      "reserved": 0,
      "available": 60000,
      "creditLimit": 100000,
      "outstanding": 40000,
      "currency": "THB",
      "sufficient": true,
      "creditHeld": false,
      "creditHeldReason": null
    }
  ],
  "chargedAccountId": null,
  "chargedAccountType": null,
  "payerName": "Acme Co., Ltd.",
  "withdrawBlockedByBooking": false
}
POSThttps://api-sandbox.parcelradar.io/api/partner/v1/orders/{id}/checkout/conditions

ยอมรับเงื่อนไขของผู้ให้บริการ

Accept the selected provider's conditions (prohibited goods, liability, surcharges — GET /instant-quote/conditions shows them). Recorded for that provider: choosing another one asks again.

ฟิลด์ประเภทจำเป็นค่าที่รับได้ค่าเริ่มต้นหมายเหตุ
acceptedAtstringYes--timestamp แบบ ISO-8601
ตัวอย่างการตอบกลับ
{
  "acceptedAt": "2026-11-04T02:15:09Z"
}
POSThttps://api-sandbox.parcelradar.io/api/partner/v1/orders/{id}/checkout

Checkout

Hold the order's total on the wallet (→ SUBMITTED). The amount is never an input: it is the order's own total. Send back what you read from GET /checkout so a changed price is refused instead of charged. On error.wallet.insufficient the body carries `shortfall`, `amount`, `balance`: top the prepaid wallet up (POST /wallet/topups) or in the Member Portal, and check out again.

ฟิลด์ประเภทจำเป็นค่าที่รับได้ค่าเริ่มต้นหมายเหตุ
fingerprintstring---From GET /checkout. A different quote → 409 error.order.checkout.stale.
expectedAmountnumber---The `amount` you read. A different total → 409 error.order.checkout.stale.
accountIduuid---The account to charge: the `accountId` of one of GET /checkout's `accounts` — PREPAID or ADVANCE. Omitted = the PREPAID wallet. You choose by id, never by kind; an id that is not one of your workspace's accounts is a 404.
ตัวอย่างคำขอ
{
  "fingerprint": "{\"origin\":{\"country\":\"TH\",…}}",
  "expectedAmount": 1240,
  "accountId": "a1b2c3d4-0000-4000-8000-0000000000a2"
}
DELETEhttps://api-sandbox.parcelradar.io/api/partner/v1/orders/{id}/checkout

ยกเลิก checkout

Release the hold and return the order to CREATED, so it can be edited again. Only while SUBMITTED, and not while a courier booking is live (cancel it first).

ฟิลด์ประเภทจำเป็นค่าที่รับได้ค่าเริ่มต้นหมายเหตุ
orderIduuidYes--The order.
orderNostringYes--Its number.
statusstringYes"SUBMITTED" (checkout), "CREATED" (withdraw)-The order's new status.
chargeIdstring---The held charge.
amountnumberYes--The amount held (or released).
currencystringYes--"THB".
balancenumber---The account's balance — unchanged by a hold.
availablenumber---Spendable after the hold.
ตัวอย่างการตอบกลับ
{
  "orderId": "3f9a1c62-8d47-4a1e-9b0c-2e5f6a7b8c90",
  "orderNo": "RDOR202611000042",
  "status": "CREATED",
  "chargeId": "c0a8012e-7f11-4b39-9a4e-2f6d1b7c9e10",
  "amount": 1240,
  "currency": "THB",
  "balance": 5000,
  "available": 5000
}

Shipment Label

แท็บ Shipment Label สำหรับออเดอร์ที่ checkout แล้ว handoff บอกว่าใช้ทางไหน: pickup (เทียบราคา จอง และสร้างการจัดส่งกับคูเรียร์ แล้วพิมพ์ฉลาก) หรือ dropoff (พิมพ์ carton mark แล้วนำพัสดุไปส่งเอง)

GEThttps://api-sandbox.parcelradar.io/api/partner/v1/orders/{id}/pickup/handoff

รับถึงที่หรือนำส่งเอง?

Which Shipment Label branch applies — decided by the saved service's pickupGroupId, never by the caller — plus a drop-off's point and claim code.

ฟิลด์ประเภทจำเป็นค่าที่รับได้ค่าเริ่มต้นหมายเหตุ
kindstringYes"pickup", "dropoff"-pickup = book a courier; dropoff = print the carton mark and bring the parcel in. From the saved service's pickupGroupId; an order without one is a drop-off.
destinationsarray---Where a courier would take it (pickup only).
dropoffPointobject---The picked drop-off point ({ tenantId, name, address, publicPhone, publicHours }), or null.
claimCodestring---A checked-out drop-off's code, shown at the counter.
dropoffHintstring-"CHECK_OUT_FIRST", "CHOOSE_ANOTHER_SHOP", "PICKUP_SERVICE", "NOT_ACCEPTING", null-What blocks a drop-off, if anything.
labelRequiredboolean---Whether the courier needs the printed label.
tenantIdentitystring---Your workspace's Member ID (RDT-…), as the labels print it.
ตัวอย่างการตอบกลับ
{
  "kind": "pickup",
  "destinations": [
    {
      "key": "WAREHOUSE",
      "label": "Parcel Radar warehouse",
      "address": {
        "name": "Parcel Radar",
        "province": "Bangkok",
        "zipcode": "10260"
      }
    }
  ],
  "dropoffPoint": null,
  "claimCode": null,
  "dropoffHint": null,
  "labelRequired": true,
  "tenantIdentity": "RDT-4K7Q2M"
}
GEThttps://api-sandbox.parcelradar.io/api/partner/v1/orders/{id}/pickup/destinations

ดูปลายทางของการรับพัสดุ

Where a courier would take this order, resolved to addresses (key WAREHOUSE or PROVIDER).

ฟิลด์ประเภทจำเป็นค่าที่รับได้ค่าเริ่มต้นหมายเหตุ
keystringYes"WAREHOUSE", "PROVIDER"-Pass as `destination`.
labelstringYes--Its name.
addressobjectYes--Its address.
namestringYes--ชื่อผู้ติดต่อ
phonestringYes--Phone the courier calls, e.g. "0812345678".
addressstringYes--House number, building, street.
subDistrictstringYes--Tambon / khwaeng (ตำบล / แขวง), in Thai.
districtstringYes--Amphoe / khet (อำเภอ / เขต), in Thai.
provincestringYes--Province (จังหวัด), in Thai.
zipcodestringYes5 digits-Postcode.
ตัวอย่างการตอบกลับ
[
  {
    "key": "WAREHOUSE",
    "label": "Parcel Radar warehouse",
    "address": {
      "name": "Parcel Radar",
      "phone": "021234567",
      "address": "99/9 Sukhumvit 101",
      "subDistrict": "บางจาก",
      "district": "พระโขนง",
      "province": "กรุงเทพมหานคร",
      "zipcode": "10260"
    }
  }
]
POSThttps://api-sandbox.parcelradar.io/api/partner/v1/orders/{id}/pickup/compare

เทียบคูเรียร์

Every courier that could collect this order's parcels, with its price and whether it can take them, and the winner. Books nothing. The parcels and addresses come from the order.

ฟิลด์ประเภทจำเป็นค่าที่รับได้ค่าเริ่มต้นหมายเหตุ
destinationstring-"WAREHOUSE", "PROVIDER""WAREHOUSE"Where the courier takes it.
fromobject---A "Pick up from" other than the order's Ship-From.
namestringYes--ชื่อผู้ติดต่อ
phonestringYes--Phone the courier calls, e.g. "0812345678".
addressstringYes--House number, building, street.
subDistrictstringYes--Tambon / khwaeng (ตำบล / แขวง), in Thai.
districtstringYes--Amphoe / khet (อำเภอ / เขต), in Thai.
provincestringYes--Province (จังหวัด), in Thai.
zipcodestringYes5 digits-Postcode.
ตัวอย่างคำขอ
{
  "destination": "WAREHOUSE"
}
POSThttps://api-sandbox.parcelradar.io/api/partner/v1/orders/{id}/pickup

จองคูเรียร์

Reserve the winning courier (status PENDING) — nothing is booked at the courier yet. Checked-out orders only. `idempotencyKey` is required: generate one per attempt and reuse it on a retry, so a retried call returns the same booking.

ฟิลด์ประเภทจำเป็นค่าที่รับได้ค่าเริ่มต้นหมายเหตุ
idempotencyKeystringYes1–100 chars-Your key for this attempt. Reuse it when you retry.
destinationstring-"WAREHOUSE", "PROVIDER""WAREHOUSE"Where the courier takes it.
courierCodestring---Only when the comparison tied at the cheapest price; anything else is refused.
fromobject---A "Pick up from" other than the order's Ship-From.
namestringYes--ชื่อผู้ติดต่อ
phonestringYes--Phone the courier calls, e.g. "0812345678".
addressstringYes--House number, building, street.
subDistrictstringYes--Tambon / khwaeng (ตำบล / แขวง), in Thai.
districtstringYes--Amphoe / khet (อำเภอ / เขต), in Thai.
provincestringYes--Province (จังหวัด), in Thai.
zipcodestringYes5 digits-Postcode.
notestring-≤ 500 chars-A note for the driver.
ตัวอย่างคำขอ
{
  "idempotencyKey": "7b0f3c1e-order-42-try-1",
  "destination": "WAREHOUSE"
}
GEThttps://api-sandbox.parcelradar.io/api/partner/v1/orders/{id}/pickup

ดูการจองของออเดอร์

Every courier booking on the order, newest first — cancelled ones included.

ฟิลด์ประเภทจำเป็นค่าที่รับได้ค่าเริ่มต้นหมายเหตุ
iduuidYes--The booking (pickupId).
orderIduuidYes--The order.
statusstringYes"PENDING", "BOOKED", "PICKUP_REQUESTED", "COLLECTED", "CANCELLED", "FAILED"-PENDING = reserved; BOOKED = the shipment exists at the courier and the label prints.
courierCodestring---The courier.
trackNostring---The courier's tracking number (first carton) once BOOKED.
quotedPriceThbnumber---The courier's price.
destinationstring-"WAREHOUSE", "PROVIDER"-Where the courier takes it.
lastErrorstring---Why the last booking attempt failed.
shipmentsarray---One per carton: { cartonNo, trackNo, refCode, vendorOrderId, cancelled }.
bookedAtstring---When the shipment was created.
cancelDeadlinestring---Until when DELETE may still cancel it.
labelRequiredboolean---false: the courier needs no printed label.
ตัวอย่างการตอบกลับ
[
  {
    "id": "8c1d2e3f-4a5b-4c6d-8e7f-90a1b2c3d4e5",
    "orderId": "3f9a1c62-8d47-4a1e-9b0c-2e5f6a7b8c90",
    "status": "BOOKED",
    "courierCode": "DPKERRY",
    "trackNo": "KEX123456789TH",
    "quotedPriceThb": 45,
    "destination": "WAREHOUSE",
    "lastError": null,
    "shipments": [
      {
        "cartonNo": 1,
        "trackNo": "KEX123456789TH",
        "refCode": "BKK-01",
        "vendorOrderId": "IS-889120",
        "cancelled": false
      }
    ],
    "bookedAt": "2026-11-04T02:20:41Z",
    "cancelDeadline": "2026-11-04T10:00:00Z",
    "labelRequired": true
  }
]
POSThttps://api-sandbox.parcelradar.io/api/partner/v1/orders/{id}/pickup/{pickupId}/book

สร้างการจัดส่งกับคูเรียร์

Create the shipment at the courier for a reserved (PENDING) booking: one shipment per carton, each with a real tracking number, so the courier label prints (→ BOOKED). A courier that needs no label is asked to collect at the same time. Booking a BOOKED row returns it unchanged. This is a real shipment at the courier.

ฟิลด์ประเภทจำเป็นค่าที่รับได้ค่าเริ่มต้นหมายเหตุ
pickupFromobjectYes--Where the courier collects; the label prints it as the sender.
namestringYes--ชื่อผู้ติดต่อ
phonestringYes--Phone the courier calls, e.g. "0812345678".
addressstringYes--House number, building, street.
subDistrictstringYes--Tambon / khwaeng (ตำบล / แขวง), in Thai.
districtstringYes--Amphoe / khet (อำเภอ / เขต), in Thai.
provincestringYes--Province (จังหวัด), in Thai.
zipcodestringYes5 digits-Postcode.
ตัวอย่างคำขอ
{
  "pickupFrom": {
    "name": "Green Parker",
    "phone": "0973331702",
    "address": "514 Sukhumvit 55",
    "subDistrict": "คลองตันเหนือ",
    "district": "วัฒนา",
    "province": "กรุงเทพมหานคร",
    "zipcode": "10110"
  }
}
GEThttps://api-sandbox.parcelradar.io/api/partner/v1/orders/{id}/pickup/{pickupId}/label

รับ Shipment Label

The end of the flow: the Parcel Radar carton mark plus the courier's label, one HTML sheet per carton with its page size in mm. Render each sheet at that size (e.g. print to PDF with a headless browser) and stick them on the cartons. Before BOOKED the courier sheet is a `preview`; a cancelled booking's is `voided`.

ฟิลด์ประเภทจำเป็นค่าที่รับได้ค่าเริ่มต้นหมายเหตุ
sheetsarrayYes--One sheet per carton and kind.
kindstringYes"parcelradar", "courier"-parcelradar = the Parcel Radar carton mark; courier = the courier's label.
htmlstringYes--The sheet, as self-contained HTML. Render it at widthMm × heightMm.
widthMmnumberYes--Page width, mm.
heightMmnumberYes--Page height, mm.
copynumberYes--This sheet's carton number (1-based).
copiesnumberYes--How many cartons.
previewboolean---true before the booking is BOOKED: the barcode is a placeholder (the order number). Book first, then print.
voidedboolean---true for a cancelled or failed booking: nothing on it may be used. Do not print it.
compactobject---The same sheet for a 100×65 mm roll ({ html, widthMm, heightMm }), or null.
missingarrayYes--Kinds with no template (string[]); empty when every sheet rendered.
ตัวอย่างการตอบกลับ
{
  "sheets": [
    {
      "kind": "parcelradar",
      "html": "<div class=\"label\">…</div>",
      "widthMm": 100,
      "heightMm": 150,
      "copy": 1,
      "copies": 1,
      "preview": false,
      "voided": false,
      "compact": null
    },
    {
      "kind": "courier",
      "html": "<div class=\"label\">…</div>",
      "widthMm": 100,
      "heightMm": 150,
      "copy": 1,
      "copies": 1,
      "preview": false,
      "voided": false,
      "compact": null
    }
  ],
  "missing": []
}
GEThttps://api-sandbox.parcelradar.io/api/partner/v1/orders/{id}/carton-mark

รับ carton mark

The drop-off branch's label: the Parcel Radar carton mark alone (with a checked-out drop-off's claim code and its QR). Nothing is booked.

ฟิลด์ประเภทจำเป็นค่าที่รับได้ค่าเริ่มต้นหมายเหตุ
sheetsarrayYes--One sheet per carton and kind.
kindstringYes"parcelradar", "courier"-parcelradar = the Parcel Radar carton mark; courier = the courier's label.
htmlstringYes--The sheet, as self-contained HTML. Render it at widthMm × heightMm.
widthMmnumberYes--Page width, mm.
heightMmnumberYes--Page height, mm.
copynumberYes--This sheet's carton number (1-based).
copiesnumberYes--How many cartons.
previewboolean---true before the booking is BOOKED: the barcode is a placeholder (the order number). Book first, then print.
voidedboolean---true for a cancelled or failed booking: nothing on it may be used. Do not print it.
compactobject---The same sheet for a 100×65 mm roll ({ html, widthMm, heightMm }), or null.
missingarrayYes--Kinds with no template (string[]); empty when every sheet rendered.
ตัวอย่างการตอบกลับ
{
  "sheets": [
    {
      "kind": "parcelradar",
      "html": "<div class=\"label\">…</div>",
      "widthMm": 100,
      "heightMm": 100,
      "copy": 1,
      "copies": 1,
      "preview": false,
      "voided": false,
      "compact": null
    }
  ],
  "missing": []
}
DELETEhttps://api-sandbox.parcelradar.io/api/partner/v1/orders/{id}/pickup/{pickupId}

ยกเลิกการจอง

Cancel the courier collection and every carton's shipment. Idempotent. Allowed until the booking's cancelDeadline; never once collected.

ฟิลด์ประเภทจำเป็นค่าที่รับได้ค่าเริ่มต้นหมายเหตุ
cancelledbooleanYes--true.
ตัวอย่างการตอบกลับ
{
  "cancelled": true
}
GEThttps://api-sandbox.parcelradar.io/api/partner/v1/orders/{id}/pickup/{pickupId}/tracking

ติดตามช่วงรับพัสดุ

The courier's timeline for this booking, fetched now. `trackNo` picks one carton's number (default: the first).

ฟิลด์ประเภทจำเป็นค่าที่รับได้ค่าเริ่มต้นหมายเหตุ
trackNostring---One of this booking's tracking numbers.
langstring-"en", "th"-The language the courier's feed answers in, where it has one.

Tracking & export documents

ติดตามออเดอร์ ทั้งลิงก์ติดตามสาธารณะและไทม์ไลน์ และอ่านข้อมูลที่ใช้พิมพ์เอกสารส่งออก

GEThttps://api-sandbox.parcelradar.io/api/partner/v1/orders/{id}/tracking

รับลิงก์ติดตามพัสดุ

The order's public tracking page — made to be handed to your customer — and the carriers following it.

ฟิลด์ประเภทจำเป็นค่าที่รับได้ค่าเริ่มต้นหมายเหตุ
statestringYes"READY", "PENDING", "NONE", "HIDDEN", "DISABLED"-READY once the link exists; trackingUrl is null until then.
trackingNostring---The order's tracking number.
trackingUrlstring---The public tracking page.
carrierNamestring---The main carrier.
carrierTrackingNostring---Its tracking number.
carrierLegsarray---{ eventType, carrierName, trackingNo, watching } per leg.
ตัวอย่างการตอบกลับ
{
  "state": "READY",
  "trackingNo": "PX4K7Q2M9",
  "trackingUrl": "https://paxel.app/t/PX4K7Q2M9",
  "carrierName": "DHL Express",
  "carrierTrackingNo": "1234567890",
  "carrierLegs": []
}
GEThttps://api-sandbox.parcelradar.io/api/partner/v1/orders/{id}/tracking/timeline

ดูไทม์ไลน์การติดตาม

The checkpoints and events the tracking page shows your customer.

ฟิลด์ประเภทจำเป็นค่าที่รับได้ค่าเริ่มต้นหมายเหตุ
trackingNostring---The order's tracking number.
trackingUrlstring---The public tracking page.
checkpointsarrayYes--{ eventType, name, checkpointStatus, courierName, courierTrackingNo, events[{ name, detail, occurredAt }] }.
ตัวอย่างการตอบกลับ
{
  "trackingNo": "PX4K7Q2M9",
  "trackingUrl": "https://paxel.app/t/PX4K7Q2M9",
  "checkpoints": [
    {
      "eventType": "FIRST_MILE",
      "name": "Picked up",
      "checkpointStatus": "DONE",
      "courierName": "Kerry Express",
      "courierTrackingNo": "KEX123456789TH",
      "events": [
        {
          "name": "Picked up by courier",
          "detail": null,
          "occurredAt": "2026-11-04T07:41:00Z"
        }
      ]
    }
  ]
}
GEThttps://api-sandbox.parcelradar.io/api/partner/v1/orders/{id}/export-documents

ดูข้อมูลเอกสารส่งออก

What the order's export documents (commercial invoice, packing list, …) print from: the order, its goods and costs, and each document's template as layout blocks with a page size. Export orders only.

ฟิลด์ประเภทจำเป็นค่าที่รับได้ค่าเริ่มต้นหมายเหตุ
exportOrderbooleanYes--Whether the order is an export.
goodsDeclaredbooleanYes--Whether the goods lines are filled in.
orderobject---ออเดอร์ในรูปแบบที่เอกสารพิมพ์ออกมา route จะมี exporterOfRecord / importerOfRecord เมื่อออเดอร์ระบุไว้
costsarray---The cost lines.
templatesarray---{ code, blocks, pageWidthMm, pageHeightMm } ต่อเอกสาร: เฉพาะเอกสารที่ Parcel Radar เปิดใช้สำหรับปลายทางและผู้ให้บริการของออเดอร์นี้ เช่น "proforma-invoice", "commercial-invoice", "packing-list", "loa"
ตัวอย่างการตอบกลับ
{
  "exportOrder": true,
  "goodsDeclared": true,
  "order": {
    "orderNo": "RDOR202611000042"
  },
  "costs": [],
  "templates": [
    {
      "code": "commercial-invoice",
      "blocks": [],
      "pageWidthMm": 210,
      "pageHeightMm": 297
    },
    {
      "code": "packing-list",
      "blocks": [],
      "pageWidthMm": 210,
      "pageHeightMm": 297
    }
  ]
}

GPS tracker

ผูกอุปกรณ์ติดตาม GPS ของ Paxel กับออเดอร์ เพื่อให้หน้าติดตามพัสดุแสดงตำแหน่งของพัสดุ: ส่งหมายเลขซีเรียลที่พิมพ์อยู่บนอุปกรณ์พร้อมออเดอร์ โดยระบุใน path เป็นหมายเลขออเดอร์ (RDOR… ตามที่อยู่บนฉลาก ตัวพิมพ์ใดก็ได้) หรือ id ของออเดอร์ อุปกรณ์หนึ่งชิ้นผูกได้ทีละหนึ่งออเดอร์ และออเดอร์หนึ่งมีอุปกรณ์ได้ทีละหนึ่งชิ้น ทั้งสองกรณีชิ้นที่สองจะถูกปฏิเสธจนกว่าจะถอดชิ้นแรกออก ออเดอร์ต้องมีหน้าติดตามพัสดุก่อน ซึ่งจะสร้างขึ้นเมื่อ checkout

PUThttps://api-sandbox.parcelradar.io/api/partner/v1/orders/{order}/tracking-device

ผูกอุปกรณ์ติดตามกับออเดอร์

ผูกอุปกรณ์ติดตามที่มีหมายเลขซีเรียลนี้กับหน้าติดตามพัสดุของออเดอร์ หมายเลขซีเรียลต้องเป็นอุปกรณ์ติดตามของ Parcel Radar ที่เปิดใช้งานแล้วและไม่ได้ผูกกับออเดอร์อื่น และออเดอร์ต้องไม่มีอุปกรณ์ติดตามอื่นผูกอยู่ หากมี ให้ถอดออกก่อน (DELETE) การส่งอุปกรณ์เดิมซ้ำจะไม่เปลี่ยนแปลงอะไร สมาชิกเจ้าของ key ต้องมีสิทธิ์แก้ไขออเดอร์

ฟิลด์ประเภทจำเป็นค่าที่รับได้ค่าเริ่มต้นหมายเหตุ
serialNumberstringYesletters and digits, ≤ 64-หมายเลขซีเรียลที่พิมพ์อยู่บนอุปกรณ์ติดตาม เช่น "220606000473" ตัวอักษรเป็นตัวพิมพ์ใหญ่หรือเล็กก็ได้
ตัวอย่างคำขอ
{
  "serialNumber": "220606000473"
}
GEThttps://api-sandbox.parcelradar.io/api/partner/v1/orders/{order}/tracking-device

ดูอุปกรณ์ติดตามของออเดอร์

อุปกรณ์ติดตามที่ผูกกับออเดอร์อยู่ตอนนี้ พร้อมตำแหน่งล่าสุดที่รายงาน attached เป็น false เมื่อไม่มีอุปกรณ์ผูกอยู่ สมาชิกเจ้าของ key ต้องมีสิทธิ์ดูออเดอร์

ฟิลด์ประเภทจำเป็นค่าที่รับได้ค่าเริ่มต้นหมายเหตุ
orderNostringYes--The order.
shipmentReadybooleanYes--ออเดอร์มีหน้าติดตามพัสดุแล้วหรือยัง ซึ่งจะสร้างขึ้นเมื่อ checkout และผูกอุปกรณ์ติดตามได้หลังจากนั้นเท่านั้น
attachedbooleanYes--ขณะนี้มีอุปกรณ์ติดตามผูกกับออเดอร์หรือไม่
serialNumberstring---หมายเลขซีเรียลของอุปกรณ์ติดตาม เป็น null เมื่อไม่มีอุปกรณ์ผูกอยู่
namestring---ชื่อรุ่นของอุปกรณ์ติดตาม
statusstring-"ACTIVATED", "DEACTIVATED", "EXPIRED"-สถานะของอุปกรณ์ติดตาม
latitudestring---ตำแหน่งล่าสุดที่รายงาน (องศาทศนิยม) เป็น null จนกว่าอุปกรณ์จะรายงานตำแหน่ง
longitudestring---ตำแหน่งล่าสุดที่รายงาน (องศาทศนิยม)
lastSeenstring-ISO-8601 UTC-เวลาที่รายงานตำแหน่งล่าสุด
ตัวอย่างการตอบกลับ
{
  "orderNo": "RDOR202611000103",
  "shipmentReady": true,
  "attached": true,
  "serialNumber": "220606000473",
  "name": "PaXel Tracker (Pro)",
  "status": "ACTIVATED",
  "latitude": "13.7387779",
  "longitude": "100.5670745",
  "lastSeen": "2026-11-06T06:17:45Z"
}
DELETEhttps://api-sandbox.parcelradar.io/api/partner/v1/orders/{order}/tracking-device

ถอดอุปกรณ์ติดตามออกจากออเดอร์

ถอดอุปกรณ์ติดตามออกจากออเดอร์ เพื่อให้ใช้กับออเดอร์อื่นได้ การเรียกซ้ำ หรือเรียกกับออเดอร์ที่ไม่มีอุปกรณ์ จะไม่เปลี่ยนแปลงอะไร สมาชิกเจ้าของ key ต้องมีสิทธิ์แก้ไขออเดอร์

ฟิลด์ประเภทจำเป็นค่าที่รับได้ค่าเริ่มต้นหมายเหตุ
orderNostringYes--The order.
shipmentReadybooleanYes--ออเดอร์มีหน้าติดตามพัสดุแล้วหรือยัง ซึ่งจะสร้างขึ้นเมื่อ checkout และผูกอุปกรณ์ติดตามได้หลังจากนั้นเท่านั้น
attachedbooleanYes--ขณะนี้มีอุปกรณ์ติดตามผูกกับออเดอร์หรือไม่
serialNumberstring---หมายเลขซีเรียลของอุปกรณ์ติดตาม เป็น null เมื่อไม่มีอุปกรณ์ผูกอยู่
namestring---ชื่อรุ่นของอุปกรณ์ติดตาม
statusstring-"ACTIVATED", "DEACTIVATED", "EXPIRED"-สถานะของอุปกรณ์ติดตาม
latitudestring---ตำแหน่งล่าสุดที่รายงาน (องศาทศนิยม) เป็น null จนกว่าอุปกรณ์จะรายงานตำแหน่ง
longitudestring---ตำแหน่งล่าสุดที่รายงาน (องศาทศนิยม)
lastSeenstring-ISO-8601 UTC-เวลาที่รายงานตำแหน่งล่าสุด
ตัวอย่างการตอบกลับ
{
  "orderNo": "RDOR202611000103",
  "shipmentReady": true,
  "attached": false,
  "serialNumber": null,
  "name": null,
  "status": null,
  "latitude": null,
  "longitude": null,
  "lastSeen": null
}

Wallet top-up

เติมเงิน prepaid wallet ของ workspace ด้วย QR แบบเดียวกับเมนู Wallet ใน Member Portal: เปิด QR ตามยอดเงิน แสดงให้ผู้จ่ายพร้อมเวลานับถอยหลัง แล้วอ่านสถานะจนกว่าจะไม่เป็น PENDING ระบบจะเติมเงินเข้า wallet เพียงครั้งเดียว ทันทีที่พบการชำระครั้งแรก ไม่ว่าจากการเรียกดูสถานะของคุณ จาก Member Portal หรือจากการตรวจของ Parcel Radar เองทุก 30 วินาที ดังนั้นแม้คุณหยุดถาม เงินก็ยังเข้า เปิด QR ได้ครั้งละหนึ่งรายการต่อ workspace บน sandbox environment QR จะเป็น TEST QR: สแกนด้วยกล้องโทรศัพท์ (หรือเปิด testPayUrl) เพื่อชำระ โดยไม่ใช้เงินจริง

POSThttps://api-sandbox.parcelradar.io/api/partner/v1/wallet/topups

เปิด QR เติมเงิน

เปิด QR เพื่อเติมเงิน prepaid wallet ของ workspace เป็นจำนวน `amount` บาท แสดง `qrImageDataUri` (หรือวาดจาก `qrPayload`) ให้ผู้จ่ายพร้อมนับถอยหลังจาก `expiresInSeconds` ชำระได้ด้วยแอปธนาคารไทยใดก็ได้ภายใน 30 นาที จากนั้นเรียก GET /wallet/topups/{merchantOrderNo} ทุกไม่กี่วินาทีจนกว่าสถานะจะไม่เป็น PENDING สมาชิกเจ้าของ key ต้องมีสิทธิ์ Top up wallet

ฟิลด์ประเภทจำเป็นค่าที่รับได้ค่าเริ่มต้นหมายเหตุ
amountnumberYes10.00 – 1,000,000.00, ≤ 2 decimals-ยอดเงิน (บาท) ที่จะเติมเข้า prepaid wallet
ตัวอย่างคำขอ
{
  "amount": 500
}
GEThttps://api-sandbox.parcelradar.io/api/partner/v1/wallet/topups/{merchantOrderNo}

ดูสถานะการเติมเงิน

สถานะการเติมเงิน ระหว่างที่เป็น PENDING Parcel Radar จะถาม payment gateway ก่อน การเรียกนี้จึงอาจเป็นครั้งที่เติมเงินเข้า wallet ให้เรียกทุก 3–5 วินาทีขณะแสดง QR สถานะ SUCCESS จะมีเลขใบเสร็จ การชำระที่ธนาคารยืนยันหลัง QR หมดอายุเล็กน้อยยังคงได้รับเงิน: รายการ EXPIRED อาจเปลี่ยนเป็น SUCCESS ได้ภายในราว 15 นาที สมาชิกเจ้าของ key ต้องมีสิทธิ์ View wallet

ฟิลด์ประเภทจำเป็นค่าที่รับได้ค่าเริ่มต้นหมายเหตุ
merchantOrderNostringYesRDQR…-เลขรายการเติมเงิน เก็บไว้เพื่อใช้ดูสถานะ
statusstringYes"PENDING", "SUCCESS", "EXPIRED", "CANCELLED", "FAILED"-PENDING = ชำระ QR ได้จนถึง expiresAt, SUCCESS = ชำระแล้วและเติมเข้า prepaid wallet แล้ว, EXPIRED / CANCELLED / FAILED = ไม่ได้ชำระ ให้เปิด QR ใหม่
amountnumberYes--ยอดเงินของ QR (บาท)
currencystringYes"THB"-เป็น THB เสมอ
paymentMethodstringYes"QR"-วิธีชำระเงิน
qrImageDataUristring-data:image/png;base64,…-QR เป็นรูป PNG ใช้กับ <img src> ได้ทันที มีเฉพาะขณะ PENDING หลังจากนั้นเป็น null
qrPayloadstring---ข้อความของ QR (Thai QR / PromptPay) สำหรับวาด QR เอง มีเฉพาะขณะ PENDING สำหรับ TEST QR จะเป็น testPayUrl
expiresAtstring-ISO-8601 UTC-เวลาที่ QR หมดอายุ คือ 30 นาทีหลังเปิด
expiresInSecondsnumberYes>= 0-เวลานับถอยหลัง: จำนวนวินาทีที่เหลือถึง expiresAt นับโดย Parcel Radar ตอนตอบกลับ (นาฬิกาเครื่องผู้ใช้จึงไม่มีผล) เป็น 0 เมื่อไม่ใช่ PENDING แล้ว
serverTimestringYesISO-8601 UTC-เวลาของ Parcel Radar ตอนตอบกลับ ใช้คู่กับ expiresInSeconds
createdAtstring-ISO-8601 UTC-เวลาที่เปิด QR
confirmedAtstring-ISO-8601 UTC-เวลาที่เติมเงินเข้า wallet เป็น null จนกว่าจะ SUCCESS
receiptNostring-RDTR…-เลขใบเสร็จการเติมเงิน เป็น null จนกว่าจะ SUCCESS
providerTradeNostring---เลขอ้างอิงของ payment gateway เป็น null จนกว่าจะ SUCCESS
mockbooleanYes--true สำหรับ TEST QR จาก gateway ทดสอบของ sandbox environment (ไม่ใช้เงินจริง) บน production เป็น false เสมอ
testPayUrlstring---เฉพาะ TEST QR: ลิงก์สาธารณะที่อยู่ใน QR การเปิดลิงก์ (สแกน QR ด้วยกล้องโทรศัพท์ หรือเปิดในเบราว์เซอร์ใดก็ได้ ไม่ต้องเข้าสู่ระบบ) จะชำระรายการนี้ ส่งต่อให้ผู้ที่ทำหน้าที่ผู้จ่ายได้ เป็น null สำหรับ QR จริง
ตัวอย่างการตอบกลับ
{
  "merchantOrderNo": "RDQR20261104120000123A1B2C3",
  "status": "SUCCESS",
  "amount": 500,
  "currency": "THB",
  "paymentMethod": "QR",
  "qrImageDataUri": null,
  "qrPayload": null,
  "expiresAt": "2026-11-04T12:30:00Z",
  "expiresInSeconds": 0,
  "serverTime": "2026-11-04T12:04:10Z",
  "createdAt": "2026-11-04T12:00:00Z",
  "confirmedAt": "2026-11-04T12:03:51Z",
  "receiptNo": "RDTR202611000042",
  "providerTradeNo": "FP2026110412035100017",
  "mock": false,
  "testPayUrl": null
}
POSThttps://api-sandbox.parcelradar.io/api/partner/v1/wallet/topups/{merchantOrderNo}/cancel

ยกเลิก QR เติมเงิน

ปิด QR ที่ยังไม่มีใครชำระ เพื่อเปิด QR ใหม่ได้ Parcel Radar จะถาม gateway อีกครั้งก่อน: หากมีการชำระเข้ามาแล้วจะเติมเงินให้และผลลัพธ์เป็น SUCCESS ให้ตรวจสถานะในผลลัพธ์ การเรียกซ้ำหรือเรียกกับรายการที่จบแล้วไม่มีผลใด

ฟิลด์ประเภทจำเป็นค่าที่รับได้ค่าเริ่มต้นหมายเหตุ
merchantOrderNostringYesRDQR…-เลขรายการเติมเงิน เก็บไว้เพื่อใช้ดูสถานะ
statusstringYes"PENDING", "SUCCESS", "EXPIRED", "CANCELLED", "FAILED"-PENDING = ชำระ QR ได้จนถึง expiresAt, SUCCESS = ชำระแล้วและเติมเข้า prepaid wallet แล้ว, EXPIRED / CANCELLED / FAILED = ไม่ได้ชำระ ให้เปิด QR ใหม่
amountnumberYes--ยอดเงินของ QR (บาท)
currencystringYes"THB"-เป็น THB เสมอ
paymentMethodstringYes"QR"-วิธีชำระเงิน
qrImageDataUristring-data:image/png;base64,…-QR เป็นรูป PNG ใช้กับ <img src> ได้ทันที มีเฉพาะขณะ PENDING หลังจากนั้นเป็น null
qrPayloadstring---ข้อความของ QR (Thai QR / PromptPay) สำหรับวาด QR เอง มีเฉพาะขณะ PENDING สำหรับ TEST QR จะเป็น testPayUrl
expiresAtstring-ISO-8601 UTC-เวลาที่ QR หมดอายุ คือ 30 นาทีหลังเปิด
expiresInSecondsnumberYes>= 0-เวลานับถอยหลัง: จำนวนวินาทีที่เหลือถึง expiresAt นับโดย Parcel Radar ตอนตอบกลับ (นาฬิกาเครื่องผู้ใช้จึงไม่มีผล) เป็น 0 เมื่อไม่ใช่ PENDING แล้ว
serverTimestringYesISO-8601 UTC-เวลาของ Parcel Radar ตอนตอบกลับ ใช้คู่กับ expiresInSeconds
createdAtstring-ISO-8601 UTC-เวลาที่เปิด QR
confirmedAtstring-ISO-8601 UTC-เวลาที่เติมเงินเข้า wallet เป็น null จนกว่าจะ SUCCESS
receiptNostring-RDTR…-เลขใบเสร็จการเติมเงิน เป็น null จนกว่าจะ SUCCESS
providerTradeNostring---เลขอ้างอิงของ payment gateway เป็น null จนกว่าจะ SUCCESS
mockbooleanYes--true สำหรับ TEST QR จาก gateway ทดสอบของ sandbox environment (ไม่ใช้เงินจริง) บน production เป็น false เสมอ
testPayUrlstring---เฉพาะ TEST QR: ลิงก์สาธารณะที่อยู่ใน QR การเปิดลิงก์ (สแกน QR ด้วยกล้องโทรศัพท์ หรือเปิดในเบราว์เซอร์ใดก็ได้ ไม่ต้องเข้าสู่ระบบ) จะชำระรายการนี้ ส่งต่อให้ผู้ที่ทำหน้าที่ผู้จ่ายได้ เป็น null สำหรับ QR จริง
ตัวอย่างการตอบกลับ
{
  "merchantOrderNo": "RDQR20261104120000123A1B2C3",
  "status": "CANCELLED",
  "amount": 500,
  "currency": "THB",
  "paymentMethod": "QR",
  "qrImageDataUri": null,
  "qrPayload": null,
  "expiresAt": "2026-11-04T12:30:00Z",
  "expiresInSeconds": 0,
  "serverTime": "2026-11-04T12:00:00Z",
  "createdAt": "2026-11-04T12:00:00Z",
  "confirmedAt": null,
  "receiptNo": null,
  "providerTradeNo": null,
  "mock": false,
  "testPayUrl": null
}
POSThttps://api-sandbox.parcelradar.io/api/partner/v1/wallet/topups/{merchantOrderNo}/mock-pay

ชำระ TEST QR (sandbox environment)

เฉพาะ sandbox environment: ให้ gateway ทดสอบชำระ TEST QR (`mock: true`) ทันที หรือหลัง `delaySeconds` วินาที เพื่อทดสอบการจัดการสถานะโดยไม่ต้องใช้โทรศัพท์ การเปิด `testPayUrl` ของรายการให้ผลเหมือนกัน การชำระจะเข้ามาผ่านการแจ้งเตือนของ gateway เหมือนการชำระจริง QR จริงจะถูกปฏิเสธและไม่มีการชำระ

ฟิลด์ประเภทจำเป็นค่าที่รับได้ค่าเริ่มต้นหมายเหตุ
delaySecondsnumber-0 – 6000จำนวนวินาทีก่อนผู้จ่ายจำลองจะชำระ