訂單明細查詢 /Order/DetailQueryList
Request 請求內容
根節點
參數 | 名稱 | 型態 | 必要性 | 說明 |
OCOD4S | 客戶訂單號碼陣列 | 組合 | M | |
QueryType | 查詢類別 | INT | O | 0:查詢客戶訂單號碼 1:查詢訂單號碼 預設為0 |
客戶訂單號碼陣列(OCOD4S)
參數 | 名稱 | 型態 | 必要性 | 說明 |
客戶訂單號碼 | S(40) | M |
回傳參數說明
主檔
參數 | 名稱 | 型態 | 說明 |
OCOD1 | 訂單單號 | S(11) | TMS內紀錄的訂單單號 |
ODATE | 訂單日期 | S(10) | TMS內紀錄的訂單日期 |
ODAT2 | 出貨日期 | S(10) | TMS內訂單如果尚未轉出貨,則此欄位為空白 |
OCOD3 | 出貨單號 | S(11) | TMS內訂單如果尚未轉出貨,則此欄位為空白 |
OCOD4 | 客戶訂單號碼 | S(40) | TMS內紀錄的客戶訂單號碼 |
OCCOD | 訂單客戶代號 | S(16) | TMS內紀錄的客戶代號 |
OCNAM | 訂單客戶名稱 | S(12) | TMS內紀錄的訂單客戶名稱 |
OPNAM | 訂單聯絡人 | S(40) | TMS內紀錄的訂單聯絡人 |
OTOT1 | 小計 | Decimal | TMS內紀錄的未稅金額 |
OTAXM | 稅金 | Decimal | TMS內紀錄的稅金金額 |
OTOT2 | 總計 | Decimal | TMS內紀錄的未稅金額+稅金金額 |
OBAK1 | 訂單備註1 | S(200) | TMS內紀錄的訂單備註 |
OBAK2 | 訂單備註2 | S(200) | TMS內紀錄的訂單備註 |
OBAK3 | 訂單備註3 | S(200) | TMS內紀錄的訂單備註 |
OADD1 | 發票地址 | S(50) | TMS內紀錄的發票寄送地址 |
OWAY | 送貨方式 | S(50) | TMS內紀錄的送貨方式 |
OPAY | 付款備註 | S(100) | TMS內紀錄的付款備註 |
OTONO | 付款方式代號 | S(2) | TMS內紀錄的付款方式代號 |
OTONA | 付款方式名稱 | S(20) | TMS內紀錄的付款方式名稱 |
OTax | 訂單稅別 | INT | TMS內紀錄的訂單稅別 1.應稅 2.零稅 3.免稅 9.混稅 |
ReceiveName | 收件人名稱 | S(100) | |
ReceiveTEL | 收件人電話 | S(20) | |
ReceiveMobile | 收件人手機 | S(20) | |
ReceiveZIPCode | 收件人郵遞區號 | S(10) | |
ReceiveAddr | 收件人地址 | S(200) | |
ReceiveCTCOD | 發票統編 | S(8) | |
ReceiveComName | 發票公司抬頭 | S(100) | |
CarrierType | 載具種類代碼 | S(6) | |
CarrierId2 | 載具號碼 | S(64) | |
NPOBAN | 捐贈碼 | S(10) | |
RETOLL | 物流代收 | INT | 0 未啟用代收 1 啟用代收 |
RETOLL_PRICE | 代收金額 | DECIMAL | |
Items | 明細 | 組合 |
明細
參數 | 名稱 | 型態 | 說明 |
OSEQ | 訂單序號 | INT | TMS內紀錄的訂單序號 |
ICODE | 產品代號 | S(17) | TMS內紀錄的產品代號 |
INAME | 產品名稱 | S(40) | TMS內紀錄的產品名稱 |
Unit | 單位 | S(4) | TMS內紀錄的產品單位 |
Qty | 數量 | DECIMAL | TMS內紀錄的產品數量 |
Price | 價格 | DECIMAL | TMS內紀錄的產品價格 |
Total | 合計 | DECIMAL | TMS內紀錄的產品合計 |
DTaxType | 稅別 | S(1) | TMS內紀錄的產品稅別,此欄位才代表TMS內紀錄的產品稅別 |
Stock | 倉庫代號 | S(4) | TMS內紀錄的產品倉庫代號 |
Remark | 備註 | S(60) | TMS內紀錄的產品備註 |
Request範例
https://website/Order/DetailQueryList
//請求Header內容
api-pno:TMSDEMOWEB
api-timestamp:1715096310
api-ClientSign:9826161962A7287991EC1A936D20B5F59B4D34B1B3D1D76742AAE0F529442062D42E490EAEFE679C174FFD13C318C011334294D29DC83F3EA90DB7B0F78798C5
//請求Body內容
{
"QueryType":0,
"OCOD4S":["1909240024985MG"]
}
Response 回覆結果
Response範例
成功
{
"Status":"S",
"ErrorCode":"0000",
"ErrorMessage":"",
"Details":
[{
"OCOD1":"10809250009",
"ODATE":"108.09.25",
"ODAT2":"108.09.25",
"OCOD3":"10809250002",
"OCOD4":"1909240024985MG",
"OCCOD":"KEF094",
"OCNAM":"蝦皮-拍",
"OPNAM":"",
"OTOT1":313.0000,
"OTAXM":16.0000,
"OTOT2":329.0000,
"OBAK1":"蝦皮/訂單狀態:待出貨/折扣券:0.00/買家ID:laurensing/物流:7-11/配送單號:32193094/實際金額:329",
"OBAK2":"姓名:幸*倫 手機:886977***760 電話:886977***760 ",
"OBAK3":"地址:德賢門市935883 ",
"OADD1":"",
"OWAY":"7-11",
"OPAY":"信用卡",
"OTONO":"00",
"OTONA":"月結五天",
"OTax":"9",
"ReceiveName":"蝦皮-拍",
"ReceiveTEL":"",
"ReceiveMobile":"",
"ReceiveZIPCode":"",
"ReceiveAddr":"德賢門市935883",
"ReceiveCTCOD":"",
"ReceiveComName":"蝦皮拍賣",
"ReceiveEmail":"",
"CarrierType":"",
"CarrierId2":"",
"NPOBAN":"",
"RETOLL":0,
"RETOLL_PRICE":0.0000,
"Items":
[
{
"OSEQ":1,
"ICODE":"89025",
"INAME":"小米行動電源 保護套 小米套 20000 2C 5000 16000 10000",
"Unit":"PCS",
"Qty":1.0,
"Price":30.0,
"Total":30.0,
"DTaxType":"1",
"Stock":"A001",
"Remark":"黑,10000 2/3代共用 (雙孔USB)"
},
{
"OSEQ":2,
"ICODE":"89026",
"INAME":"小米行動電源 保護套 小米套 20000 2C 5000 16000 10000",
"Unit":"PCS",
"Qty":1.0,
"Price":30.0,
"Total":30.0,
"DTaxType":"1",
"Stock":"A001",
"Remark":"橘,10000 2/3代共用 (雙孔USB)"
},
{
...
}
]
}],
"ErrorDetail":[]
}
失敗
{
"Status": "E",
"ErrorCode": "9003",
"ErrorMessage": "Timestamp已過期",
"ErrorDetail": []
}
失敗
{
"Status": "E",
"ErrorCode": "2006",
"ErrorMessage": "查無客戶資料",
"ErrorDetail": []
}
失敗
{
"Status":"E",
"ErrorCode":"9999",
"ErrorMessage":"查無訂單資料",
"Details":[],
"ErrorDetail":[
{
"Status":"",
"OCOD1":"",
"OSEQ":0,
"OCOD4":"A",
"ErrorCode":"",
"ErrorMessage":"查無此訂單資料"
},
{
"Status":"",
"OCOD1":"",
"OSEQ":0,
"OCOD4":"T",
"ErrorCode":"",
"ErrorMessage":"查無此訂單資料"
}
]
}
失敗
{
"Status":"S",
"ErrorCode":"0001",
"ErrorMessage":"全部查詢完成,有部分查詢出現錯誤",
"Details":[
{
"OCOD1":"10809250009",
"ODATE":"108.09.25",
"ODAT2":"108.09.25",
"OCOD3":"10809250002",
"OCOD4":"1909240024985MG",
"OCCOD":"KEF094",
"OCNAM":"蝦皮-拍",
"OPNAM":"",
"OTOT1":313.0000,
"OTAXM":16.0000,
"OTOT2":329.0000,
"OBAK1":"蝦皮/訂單狀態:待出貨/折扣券:0.00/買家ID:laurensing/物流:7-11/配送單號:32193094/實際金額:329",
"OBAK2":"姓名:幸*倫 手機:886977***760 電話:886977***760 ",
"OBAK3":"地址:德賢門市935883 ",
"OADD1":"",
"OWAY":"7-11",
"OPAY":"信用卡",
"OTONO":"00",
"OTONA":"月結五天",
"OTax":"9",
"ReceiveName":"蝦皮-拍",
"ReceiveTEL":"",
"ReceiveMobile":"",
"ReceiveZIPCode":"",
"ReceiveAddr":"德賢門市935883",
"ReceiveCTCOD":"",
"ReceiveComName":"蝦皮拍賣",
"ReceiveEmail":"",
"CarrierType":"",
"CarrierId2":"",
"NPOBAN":"",
"RETOLL":0,
"RETOLL_PRICE":0.0000,
"Items":
[
{
"OSEQ":1,
"ICODE":"89025",
"INAME":"小米行動電源 保護套 小米套 20000 2C 5000 16000 10000",
"Unit":"PCS",
"Qty":1.000000000,
"Price":30.0,
"Total":30.0,
"DTaxType":"1",
"Stock":"A001",
"Remark":"黑,10000 2/3代共用 (雙孔USB)"
},
{
"OSEQ":2,
"ICODE":"89026",
"INAME":"小米行動電源 保護套 小米套 20000 2C 5000 16000 10000",
"Unit":"PCS",
"Qty":1.000000000,
"Price":30.0,
"Total":30.0,
"DTaxType":"1",
"Stock":"A001",
"Remark":"橘,10000 2/3代共用 (雙孔USB)"
},
{
...
}
]
}
],
"ErrorDetail":[
{
"Status":"",
"OCOD1":"",
"OSEQ":0,
"OCOD4":"T",
"ErrorCode":"",
"ErrorMessage":"查無此訂單資料"
}
]
}
失敗
{
"Status":"S",
"ErrorCode":"0001",
"ErrorMessage":"全部查詢完成,有部分查詢出現錯誤",
"Details":[],
"ErrorDetail":
[
{
"Status":"",
"OCOD1":"10809250009",
"OSEQ":0,
"OCOD4":"1909240024985MG",
"ErrorCode":"",
"ErrorMessage":"查無訂單明細資料"
},
{
"Status":"",
"OCOD1":"",
"OSEQ":0,
"OCOD4":"T",
"ErrorCode":"",
"ErrorMessage":"查無此訂單資料"
}
]
}