Create return shipment
curl --request POST \
--url https://api.returnshelper.com/uat/user/api/ReturnShipment/createReturnShipment \
--header 'Content-Type: application/json' \
--header 'x-rr-apikey: <api-key>' \
--header 'x-rr-apitoken: <api-key>' \
--data '
{
"serviceTypeCode": "fedex_ground",
"orderTitle": "Return Label Title",
"totalValue": 100,
"totalValueCurrency": "usd",
"shipment": {
"shipToWarehouseId": 2,
"boxType": "cus",
"shipFrom": {
"country": "usa",
"contactName": "Your name",
"street1": "Some address line 1",
"state": "tx",
"city": "Houston",
"postalCode": "77235",
"phone": "15622708183",
"email": "user@example.com",
"fax": "<string>",
"street2": "Some address line 2",
"street3": "<string>"
},
"parcel": {
"weight": 10.5,
"weightUnit": "g",
"length": 10,
"width": 10,
"height": 10,
"dimensionUnit": "cm",
"items": [
{
"description": "Test item",
"weight": 10.5,
"value": 100,
"weightUom": "g",
"valueCurrencyCode": "usd"
}
]
},
"sellerReferenceNumber": "<string>",
"customFieldMap": {}
},
"sellerReferenceNumber": "<string>",
"remarks": "<string>"
}
'import requests
url = "https://api.returnshelper.com/uat/user/api/ReturnShipment/createReturnShipment"
payload = {
"serviceTypeCode": "fedex_ground",
"orderTitle": "Return Label Title",
"totalValue": 100,
"totalValueCurrency": "usd",
"shipment": {
"shipToWarehouseId": 2,
"boxType": "cus",
"shipFrom": {
"country": "usa",
"contactName": "Your name",
"street1": "Some address line 1",
"state": "tx",
"city": "Houston",
"postalCode": "77235",
"phone": "15622708183",
"email": "user@example.com",
"fax": "<string>",
"street2": "Some address line 2",
"street3": "<string>"
},
"parcel": {
"weight": 10.5,
"weightUnit": "g",
"length": 10,
"width": 10,
"height": 10,
"dimensionUnit": "cm",
"items": [
{
"description": "Test item",
"weight": 10.5,
"value": 100,
"weightUom": "g",
"valueCurrencyCode": "usd"
}
]
},
"sellerReferenceNumber": "<string>",
"customFieldMap": {}
},
"sellerReferenceNumber": "<string>",
"remarks": "<string>"
}
headers = {
"x-rr-apikey": "<api-key>",
"x-rr-apitoken": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {
'x-rr-apikey': '<api-key>',
'x-rr-apitoken': '<api-key>',
'Content-Type': 'application/json'
},
body: JSON.stringify({
serviceTypeCode: 'fedex_ground',
orderTitle: 'Return Label Title',
totalValue: 100,
totalValueCurrency: 'usd',
shipment: {
shipToWarehouseId: 2,
boxType: 'cus',
shipFrom: {
country: 'usa',
contactName: 'Your name',
street1: 'Some address line 1',
state: 'tx',
city: 'Houston',
postalCode: '77235',
phone: '15622708183',
email: 'user@example.com',
fax: '<string>',
street2: 'Some address line 2',
street3: '<string>'
},
parcel: {
weight: 10.5,
weightUnit: 'g',
length: 10,
width: 10,
height: 10,
dimensionUnit: 'cm',
items: [
{
description: 'Test item',
weight: 10.5,
value: 100,
weightUom: 'g',
valueCurrencyCode: 'usd'
}
]
},
sellerReferenceNumber: '<string>',
customFieldMap: {}
},
sellerReferenceNumber: '<string>',
remarks: '<string>'
})
};
fetch('https://api.returnshelper.com/uat/user/api/ReturnShipment/createReturnShipment', 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.returnshelper.com/uat/user/api/ReturnShipment/createReturnShipment",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'serviceTypeCode' => 'fedex_ground',
'orderTitle' => 'Return Label Title',
'totalValue' => 100,
'totalValueCurrency' => 'usd',
'shipment' => [
'shipToWarehouseId' => 2,
'boxType' => 'cus',
'shipFrom' => [
'country' => 'usa',
'contactName' => 'Your name',
'street1' => 'Some address line 1',
'state' => 'tx',
'city' => 'Houston',
'postalCode' => '77235',
'phone' => '15622708183',
'email' => 'user@example.com',
'fax' => '<string>',
'street2' => 'Some address line 2',
'street3' => '<string>'
],
'parcel' => [
'weight' => 10.5,
'weightUnit' => 'g',
'length' => 10,
'width' => 10,
'height' => 10,
'dimensionUnit' => 'cm',
'items' => [
[
'description' => 'Test item',
'weight' => 10.5,
'value' => 100,
'weightUom' => 'g',
'valueCurrencyCode' => 'usd'
]
]
],
'sellerReferenceNumber' => '<string>',
'customFieldMap' => [
]
],
'sellerReferenceNumber' => '<string>',
'remarks' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"x-rr-apikey: <api-key>",
"x-rr-apitoken: <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"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.returnshelper.com/uat/user/api/ReturnShipment/createReturnShipment"
payload := strings.NewReader("{\n \"serviceTypeCode\": \"fedex_ground\",\n \"orderTitle\": \"Return Label Title\",\n \"totalValue\": 100,\n \"totalValueCurrency\": \"usd\",\n \"shipment\": {\n \"shipToWarehouseId\": 2,\n \"boxType\": \"cus\",\n \"shipFrom\": {\n \"country\": \"usa\",\n \"contactName\": \"Your name\",\n \"street1\": \"Some address line 1\",\n \"state\": \"tx\",\n \"city\": \"Houston\",\n \"postalCode\": \"77235\",\n \"phone\": \"15622708183\",\n \"email\": \"user@example.com\",\n \"fax\": \"<string>\",\n \"street2\": \"Some address line 2\",\n \"street3\": \"<string>\"\n },\n \"parcel\": {\n \"weight\": 10.5,\n \"weightUnit\": \"g\",\n \"length\": 10,\n \"width\": 10,\n \"height\": 10,\n \"dimensionUnit\": \"cm\",\n \"items\": [\n {\n \"description\": \"Test item\",\n \"weight\": 10.5,\n \"value\": 100,\n \"weightUom\": \"g\",\n \"valueCurrencyCode\": \"usd\"\n }\n ]\n },\n \"sellerReferenceNumber\": \"<string>\",\n \"customFieldMap\": {}\n },\n \"sellerReferenceNumber\": \"<string>\",\n \"remarks\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("x-rr-apikey", "<api-key>")
req.Header.Add("x-rr-apitoken", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.returnshelper.com/uat/user/api/ReturnShipment/createReturnShipment")
.header("x-rr-apikey", "<api-key>")
.header("x-rr-apitoken", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"serviceTypeCode\": \"fedex_ground\",\n \"orderTitle\": \"Return Label Title\",\n \"totalValue\": 100,\n \"totalValueCurrency\": \"usd\",\n \"shipment\": {\n \"shipToWarehouseId\": 2,\n \"boxType\": \"cus\",\n \"shipFrom\": {\n \"country\": \"usa\",\n \"contactName\": \"Your name\",\n \"street1\": \"Some address line 1\",\n \"state\": \"tx\",\n \"city\": \"Houston\",\n \"postalCode\": \"77235\",\n \"phone\": \"15622708183\",\n \"email\": \"user@example.com\",\n \"fax\": \"<string>\",\n \"street2\": \"Some address line 2\",\n \"street3\": \"<string>\"\n },\n \"parcel\": {\n \"weight\": 10.5,\n \"weightUnit\": \"g\",\n \"length\": 10,\n \"width\": 10,\n \"height\": 10,\n \"dimensionUnit\": \"cm\",\n \"items\": [\n {\n \"description\": \"Test item\",\n \"weight\": 10.5,\n \"value\": 100,\n \"weightUom\": \"g\",\n \"valueCurrencyCode\": \"usd\"\n }\n ]\n },\n \"sellerReferenceNumber\": \"<string>\",\n \"customFieldMap\": {}\n },\n \"sellerReferenceNumber\": \"<string>\",\n \"remarks\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.returnshelper.com/uat/user/api/ReturnShipment/createReturnShipment")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["x-rr-apikey"] = '<api-key>'
request["x-rr-apitoken"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"serviceTypeCode\": \"fedex_ground\",\n \"orderTitle\": \"Return Label Title\",\n \"totalValue\": 100,\n \"totalValueCurrency\": \"usd\",\n \"shipment\": {\n \"shipToWarehouseId\": 2,\n \"boxType\": \"cus\",\n \"shipFrom\": {\n \"country\": \"usa\",\n \"contactName\": \"Your name\",\n \"street1\": \"Some address line 1\",\n \"state\": \"tx\",\n \"city\": \"Houston\",\n \"postalCode\": \"77235\",\n \"phone\": \"15622708183\",\n \"email\": \"user@example.com\",\n \"fax\": \"<string>\",\n \"street2\": \"Some address line 2\",\n \"street3\": \"<string>\"\n },\n \"parcel\": {\n \"weight\": 10.5,\n \"weightUnit\": \"g\",\n \"length\": 10,\n \"width\": 10,\n \"height\": 10,\n \"dimensionUnit\": \"cm\",\n \"items\": [\n {\n \"description\": \"Test item\",\n \"weight\": 10.5,\n \"value\": 100,\n \"weightUom\": \"g\",\n \"valueCurrencyCode\": \"usd\"\n }\n ]\n },\n \"sellerReferenceNumber\": \"<string>\",\n \"customFieldMap\": {}\n },\n \"sellerReferenceNumber\": \"<string>\",\n \"remarks\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"data": {
"returnRequestId": 123,
"returnRequestNumber": "<string>",
"shipmentId": 123,
"referenceNumber": "<string>",
"labelId": 123,
"labelRequestStatusCode": "<string>",
"cost": 123,
"costCurrencyCode": "<string>"
}
}{
"correlationId": "<string>",
"meta": {
"status": 123,
"data": {},
"errorCode": "<string>",
"error": {}
}
}返品配送(作成)
Return Shipment を作成
POST
/
api
/
ReturnShipment
/
createReturnShipment
Create return shipment
curl --request POST \
--url https://api.returnshelper.com/uat/user/api/ReturnShipment/createReturnShipment \
--header 'Content-Type: application/json' \
--header 'x-rr-apikey: <api-key>' \
--header 'x-rr-apitoken: <api-key>' \
--data '
{
"serviceTypeCode": "fedex_ground",
"orderTitle": "Return Label Title",
"totalValue": 100,
"totalValueCurrency": "usd",
"shipment": {
"shipToWarehouseId": 2,
"boxType": "cus",
"shipFrom": {
"country": "usa",
"contactName": "Your name",
"street1": "Some address line 1",
"state": "tx",
"city": "Houston",
"postalCode": "77235",
"phone": "15622708183",
"email": "user@example.com",
"fax": "<string>",
"street2": "Some address line 2",
"street3": "<string>"
},
"parcel": {
"weight": 10.5,
"weightUnit": "g",
"length": 10,
"width": 10,
"height": 10,
"dimensionUnit": "cm",
"items": [
{
"description": "Test item",
"weight": 10.5,
"value": 100,
"weightUom": "g",
"valueCurrencyCode": "usd"
}
]
},
"sellerReferenceNumber": "<string>",
"customFieldMap": {}
},
"sellerReferenceNumber": "<string>",
"remarks": "<string>"
}
'import requests
url = "https://api.returnshelper.com/uat/user/api/ReturnShipment/createReturnShipment"
payload = {
"serviceTypeCode": "fedex_ground",
"orderTitle": "Return Label Title",
"totalValue": 100,
"totalValueCurrency": "usd",
"shipment": {
"shipToWarehouseId": 2,
"boxType": "cus",
"shipFrom": {
"country": "usa",
"contactName": "Your name",
"street1": "Some address line 1",
"state": "tx",
"city": "Houston",
"postalCode": "77235",
"phone": "15622708183",
"email": "user@example.com",
"fax": "<string>",
"street2": "Some address line 2",
"street3": "<string>"
},
"parcel": {
"weight": 10.5,
"weightUnit": "g",
"length": 10,
"width": 10,
"height": 10,
"dimensionUnit": "cm",
"items": [
{
"description": "Test item",
"weight": 10.5,
"value": 100,
"weightUom": "g",
"valueCurrencyCode": "usd"
}
]
},
"sellerReferenceNumber": "<string>",
"customFieldMap": {}
},
"sellerReferenceNumber": "<string>",
"remarks": "<string>"
}
headers = {
"x-rr-apikey": "<api-key>",
"x-rr-apitoken": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {
'x-rr-apikey': '<api-key>',
'x-rr-apitoken': '<api-key>',
'Content-Type': 'application/json'
},
body: JSON.stringify({
serviceTypeCode: 'fedex_ground',
orderTitle: 'Return Label Title',
totalValue: 100,
totalValueCurrency: 'usd',
shipment: {
shipToWarehouseId: 2,
boxType: 'cus',
shipFrom: {
country: 'usa',
contactName: 'Your name',
street1: 'Some address line 1',
state: 'tx',
city: 'Houston',
postalCode: '77235',
phone: '15622708183',
email: 'user@example.com',
fax: '<string>',
street2: 'Some address line 2',
street3: '<string>'
},
parcel: {
weight: 10.5,
weightUnit: 'g',
length: 10,
width: 10,
height: 10,
dimensionUnit: 'cm',
items: [
{
description: 'Test item',
weight: 10.5,
value: 100,
weightUom: 'g',
valueCurrencyCode: 'usd'
}
]
},
sellerReferenceNumber: '<string>',
customFieldMap: {}
},
sellerReferenceNumber: '<string>',
remarks: '<string>'
})
};
fetch('https://api.returnshelper.com/uat/user/api/ReturnShipment/createReturnShipment', 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.returnshelper.com/uat/user/api/ReturnShipment/createReturnShipment",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'serviceTypeCode' => 'fedex_ground',
'orderTitle' => 'Return Label Title',
'totalValue' => 100,
'totalValueCurrency' => 'usd',
'shipment' => [
'shipToWarehouseId' => 2,
'boxType' => 'cus',
'shipFrom' => [
'country' => 'usa',
'contactName' => 'Your name',
'street1' => 'Some address line 1',
'state' => 'tx',
'city' => 'Houston',
'postalCode' => '77235',
'phone' => '15622708183',
'email' => 'user@example.com',
'fax' => '<string>',
'street2' => 'Some address line 2',
'street3' => '<string>'
],
'parcel' => [
'weight' => 10.5,
'weightUnit' => 'g',
'length' => 10,
'width' => 10,
'height' => 10,
'dimensionUnit' => 'cm',
'items' => [
[
'description' => 'Test item',
'weight' => 10.5,
'value' => 100,
'weightUom' => 'g',
'valueCurrencyCode' => 'usd'
]
]
],
'sellerReferenceNumber' => '<string>',
'customFieldMap' => [
]
],
'sellerReferenceNumber' => '<string>',
'remarks' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"x-rr-apikey: <api-key>",
"x-rr-apitoken: <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"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.returnshelper.com/uat/user/api/ReturnShipment/createReturnShipment"
payload := strings.NewReader("{\n \"serviceTypeCode\": \"fedex_ground\",\n \"orderTitle\": \"Return Label Title\",\n \"totalValue\": 100,\n \"totalValueCurrency\": \"usd\",\n \"shipment\": {\n \"shipToWarehouseId\": 2,\n \"boxType\": \"cus\",\n \"shipFrom\": {\n \"country\": \"usa\",\n \"contactName\": \"Your name\",\n \"street1\": \"Some address line 1\",\n \"state\": \"tx\",\n \"city\": \"Houston\",\n \"postalCode\": \"77235\",\n \"phone\": \"15622708183\",\n \"email\": \"user@example.com\",\n \"fax\": \"<string>\",\n \"street2\": \"Some address line 2\",\n \"street3\": \"<string>\"\n },\n \"parcel\": {\n \"weight\": 10.5,\n \"weightUnit\": \"g\",\n \"length\": 10,\n \"width\": 10,\n \"height\": 10,\n \"dimensionUnit\": \"cm\",\n \"items\": [\n {\n \"description\": \"Test item\",\n \"weight\": 10.5,\n \"value\": 100,\n \"weightUom\": \"g\",\n \"valueCurrencyCode\": \"usd\"\n }\n ]\n },\n \"sellerReferenceNumber\": \"<string>\",\n \"customFieldMap\": {}\n },\n \"sellerReferenceNumber\": \"<string>\",\n \"remarks\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("x-rr-apikey", "<api-key>")
req.Header.Add("x-rr-apitoken", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.returnshelper.com/uat/user/api/ReturnShipment/createReturnShipment")
.header("x-rr-apikey", "<api-key>")
.header("x-rr-apitoken", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"serviceTypeCode\": \"fedex_ground\",\n \"orderTitle\": \"Return Label Title\",\n \"totalValue\": 100,\n \"totalValueCurrency\": \"usd\",\n \"shipment\": {\n \"shipToWarehouseId\": 2,\n \"boxType\": \"cus\",\n \"shipFrom\": {\n \"country\": \"usa\",\n \"contactName\": \"Your name\",\n \"street1\": \"Some address line 1\",\n \"state\": \"tx\",\n \"city\": \"Houston\",\n \"postalCode\": \"77235\",\n \"phone\": \"15622708183\",\n \"email\": \"user@example.com\",\n \"fax\": \"<string>\",\n \"street2\": \"Some address line 2\",\n \"street3\": \"<string>\"\n },\n \"parcel\": {\n \"weight\": 10.5,\n \"weightUnit\": \"g\",\n \"length\": 10,\n \"width\": 10,\n \"height\": 10,\n \"dimensionUnit\": \"cm\",\n \"items\": [\n {\n \"description\": \"Test item\",\n \"weight\": 10.5,\n \"value\": 100,\n \"weightUom\": \"g\",\n \"valueCurrencyCode\": \"usd\"\n }\n ]\n },\n \"sellerReferenceNumber\": \"<string>\",\n \"customFieldMap\": {}\n },\n \"sellerReferenceNumber\": \"<string>\",\n \"remarks\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.returnshelper.com/uat/user/api/ReturnShipment/createReturnShipment")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["x-rr-apikey"] = '<api-key>'
request["x-rr-apitoken"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"serviceTypeCode\": \"fedex_ground\",\n \"orderTitle\": \"Return Label Title\",\n \"totalValue\": 100,\n \"totalValueCurrency\": \"usd\",\n \"shipment\": {\n \"shipToWarehouseId\": 2,\n \"boxType\": \"cus\",\n \"shipFrom\": {\n \"country\": \"usa\",\n \"contactName\": \"Your name\",\n \"street1\": \"Some address line 1\",\n \"state\": \"tx\",\n \"city\": \"Houston\",\n \"postalCode\": \"77235\",\n \"phone\": \"15622708183\",\n \"email\": \"user@example.com\",\n \"fax\": \"<string>\",\n \"street2\": \"Some address line 2\",\n \"street3\": \"<string>\"\n },\n \"parcel\": {\n \"weight\": 10.5,\n \"weightUnit\": \"g\",\n \"length\": 10,\n \"width\": 10,\n \"height\": 10,\n \"dimensionUnit\": \"cm\",\n \"items\": [\n {\n \"description\": \"Test item\",\n \"weight\": 10.5,\n \"value\": 100,\n \"weightUom\": \"g\",\n \"valueCurrencyCode\": \"usd\"\n }\n ]\n },\n \"sellerReferenceNumber\": \"<string>\",\n \"customFieldMap\": {}\n },\n \"sellerReferenceNumber\": \"<string>\",\n \"remarks\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"data": {
"returnRequestId": 123,
"returnRequestNumber": "<string>",
"shipmentId": 123,
"referenceNumber": "<string>",
"labelId": 123,
"labelRequestStatusCode": "<string>",
"cost": 123,
"costCurrencyCode": "<string>"
}
}{
"correlationId": "<string>",
"meta": {
"status": 123,
"data": {},
"errorCode": "<string>",
"error": {}
}
}このページはAIによって自動翻訳されています。API技術仕様は英語が正式です。不明点がある場合は英語版を参照してください。
labelRequestStatusCode(通常は queued)が返り、実際のラベル URL は後ほど webhook で配信されます。
前提条件
呼び出し前に以下を準備してください:serviceTypeCode— 以下のいずれかから利用可能な返品サービスを取得してください:- 発地・宛先国コード — すべての発地国を取得 と すべての国を取得 で取得します。コードは ISO3(
usa、gbr、chn)です。 - パーセル寸法と重量 — 必須かつ
> 0であること。単位は すべての寸法単位を取得 および すべての重量単位を取得 で確認できます。 - 冪等キー — 強く推奨。
x-returnhelper-idempotency-keyに新しい UUID を送って、リトライによる重複シップメントを防いでください。詳細は 冪等性セクション を参照してください。
重要なフィールド
totalValueとtotalValueCurrency—totalValueはparcel.items[].valueの合計と厳密に等しい必要があります。通貨は ISO 4217(例:USD、GBP、EUR)。コードがサポートされているかは すべての取引タイプを取得 で確認してください。parcel.items— 複数明細のサポートはアカウント設定に依存します。単一明細のみ許可されているアカウントが複数明細を送ると、バリデーションのソフトエラーになります。設定変更が必要な場合はサポートにご連絡ください。- 寸法 —
dimension1が最長辺、dimension2が次に長い辺、dimension3が最短辺です。 sellerReferenceNumber— 出品者側の識別子で、3 つの独立したレイヤー(トップレベル、shipment、parcel.items[]内の各アイテム)で受け付けます。そのまま保存され、Webhook イベントで返却されるため自社の注文システムとの突合に利用できます。レイヤーの意味、省略時のフォールバック挙動、推奨される突合ワークフローについては Seller Reference Number を参照してください。
ラベル生成は非同期
即時レスポンスにはlabelRequestStatusCode: queued が含まれます。最終的なラベル URL と追跡番号は labelGenerated webhook イベント(失敗時は labelFailed)で配信されます。倉庫到着は markShipmentArrive イベント、その後 inventoryCreated イベントが続きます。Webhooks を購読してください——webhook はシップメントライフサイクルの真実のソースであり、ポーリングの代替手段ではありません。
関連
- 発地から配送料を取得 — コミット前に料金をプレビュー。
- Webhooks —
labelGenerated、labelFailed、markShipmentArriveを購読してシップメントライフサイクル全体を受信。 - Seller Reference Number —
sellerReferenceNumberの設定方法と、Webhook イベントを使った自社注文レコードとの突合方法。
承認
Your API key
Your API token — keep this private
ボディ
application/json
Return service type code
Order title / return title
Total declared value of the return
Currency code for totalValue (e.g. USD)
Shipment details including origin address and parcel info
Show child attributes
Show child attributes
Seller reference number
Additional remarks
レスポンス
Success
Created return shipment details
Show child attributes
Show child attributes
⌘I