Send RMA Info to Merchant (from Global-e)
curl --request POST \
--url https://{merchant_site_domain}/rma-info-to-merchant-url \
--header 'Content-Type: application/json' \
--data '
{
"OrderId": "GE24192321GB",
"MerchantOrderId": "71144",
"RMANumber": "223878",
"ShipperName": "DHL",
"ReturnTrackingNumber": "857854854778",
"TrackingURL": "www.dhl.com/Tracking?TrackingNumber=857854854778",
"CreatedBy": "Customer",
"ReturnedProducts": [
{
"SKU": "ProductD",
"Name": "Blue jacket",
"CartItemId": "2",
"ReturnQuantity": 1,
"ReturnReasonName": "Arrived too late",
"MerchantReturnReasonCode": null,
"MerchantReturnReasonName": null
}
],
"MerchantGUID": "<MERCHANT_GUID>",
"CurrencyCode": "EUR",
"ReturnShippingCost": 2020.9483,
"WebStoreCode": "Merchant01",
"WebStoreInstanceCode": "01.webstore.com"
}
'import requests
url = "https://{merchant_site_domain}/rma-info-to-merchant-url"
payload = {
"OrderId": "GE24192321GB",
"MerchantOrderId": "71144",
"RMANumber": "223878",
"ShipperName": "DHL",
"ReturnTrackingNumber": "857854854778",
"TrackingURL": "www.dhl.com/Tracking?TrackingNumber=857854854778",
"CreatedBy": "Customer",
"ReturnedProducts": [
{
"SKU": "ProductD",
"Name": "Blue jacket",
"CartItemId": "2",
"ReturnQuantity": 1,
"ReturnReasonName": "Arrived too late",
"MerchantReturnReasonCode": None,
"MerchantReturnReasonName": None
}
],
"MerchantGUID": "<MERCHANT_GUID>",
"CurrencyCode": "EUR",
"ReturnShippingCost": 2020.9483,
"WebStoreCode": "Merchant01",
"WebStoreInstanceCode": "01.webstore.com"
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
OrderId: 'GE24192321GB',
MerchantOrderId: '71144',
RMANumber: '223878',
ShipperName: 'DHL',
ReturnTrackingNumber: '857854854778',
TrackingURL: 'www.dhl.com/Tracking?TrackingNumber=857854854778',
CreatedBy: 'Customer',
ReturnedProducts: [
{
SKU: 'ProductD',
Name: 'Blue jacket',
CartItemId: '2',
ReturnQuantity: 1,
ReturnReasonName: 'Arrived too late',
MerchantReturnReasonCode: null,
MerchantReturnReasonName: null
}
],
MerchantGUID: '<MERCHANT_GUID>',
CurrencyCode: 'EUR',
ReturnShippingCost: 2020.9483,
WebStoreCode: 'Merchant01',
WebStoreInstanceCode: '01.webstore.com'
})
};
fetch('https://{merchant_site_domain}/rma-info-to-merchant-url', 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://{merchant_site_domain}/rma-info-to-merchant-url",
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([
'OrderId' => 'GE24192321GB',
'MerchantOrderId' => '71144',
'RMANumber' => '223878',
'ShipperName' => 'DHL',
'ReturnTrackingNumber' => '857854854778',
'TrackingURL' => 'www.dhl.com/Tracking?TrackingNumber=857854854778',
'CreatedBy' => 'Customer',
'ReturnedProducts' => [
[
'SKU' => 'ProductD',
'Name' => 'Blue jacket',
'CartItemId' => '2',
'ReturnQuantity' => 1,
'ReturnReasonName' => 'Arrived too late',
'MerchantReturnReasonCode' => null,
'MerchantReturnReasonName' => null
]
],
'MerchantGUID' => '<MERCHANT_GUID>',
'CurrencyCode' => 'EUR',
'ReturnShippingCost' => 2020.9483,
'WebStoreCode' => 'Merchant01',
'WebStoreInstanceCode' => '01.webstore.com'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$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://{merchant_site_domain}/rma-info-to-merchant-url"
payload := strings.NewReader("{\n \"OrderId\": \"GE24192321GB\",\n \"MerchantOrderId\": \"71144\",\n \"RMANumber\": \"223878\",\n \"ShipperName\": \"DHL\",\n \"ReturnTrackingNumber\": \"857854854778\",\n \"TrackingURL\": \"www.dhl.com/Tracking?TrackingNumber=857854854778\",\n \"CreatedBy\": \"Customer\",\n \"ReturnedProducts\": [\n {\n \"SKU\": \"ProductD\",\n \"Name\": \"Blue jacket\",\n \"CartItemId\": \"2\",\n \"ReturnQuantity\": 1,\n \"ReturnReasonName\": \"Arrived too late\",\n \"MerchantReturnReasonCode\": null,\n \"MerchantReturnReasonName\": null\n }\n ],\n \"MerchantGUID\": \"<MERCHANT_GUID>\",\n \"CurrencyCode\": \"EUR\",\n \"ReturnShippingCost\": 2020.9483,\n \"WebStoreCode\": \"Merchant01\",\n \"WebStoreInstanceCode\": \"01.webstore.com\"\n}")
req, _ := http.NewRequest("POST", url, payload)
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://{merchant_site_domain}/rma-info-to-merchant-url")
.header("Content-Type", "application/json")
.body("{\n \"OrderId\": \"GE24192321GB\",\n \"MerchantOrderId\": \"71144\",\n \"RMANumber\": \"223878\",\n \"ShipperName\": \"DHL\",\n \"ReturnTrackingNumber\": \"857854854778\",\n \"TrackingURL\": \"www.dhl.com/Tracking?TrackingNumber=857854854778\",\n \"CreatedBy\": \"Customer\",\n \"ReturnedProducts\": [\n {\n \"SKU\": \"ProductD\",\n \"Name\": \"Blue jacket\",\n \"CartItemId\": \"2\",\n \"ReturnQuantity\": 1,\n \"ReturnReasonName\": \"Arrived too late\",\n \"MerchantReturnReasonCode\": null,\n \"MerchantReturnReasonName\": null\n }\n ],\n \"MerchantGUID\": \"<MERCHANT_GUID>\",\n \"CurrencyCode\": \"EUR\",\n \"ReturnShippingCost\": 2020.9483,\n \"WebStoreCode\": \"Merchant01\",\n \"WebStoreInstanceCode\": \"01.webstore.com\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://{merchant_site_domain}/rma-info-to-merchant-url")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"OrderId\": \"GE24192321GB\",\n \"MerchantOrderId\": \"71144\",\n \"RMANumber\": \"223878\",\n \"ShipperName\": \"DHL\",\n \"ReturnTrackingNumber\": \"857854854778\",\n \"TrackingURL\": \"www.dhl.com/Tracking?TrackingNumber=857854854778\",\n \"CreatedBy\": \"Customer\",\n \"ReturnedProducts\": [\n {\n \"SKU\": \"ProductD\",\n \"Name\": \"Blue jacket\",\n \"CartItemId\": \"2\",\n \"ReturnQuantity\": 1,\n \"ReturnReasonName\": \"Arrived too late\",\n \"MerchantReturnReasonCode\": null,\n \"MerchantReturnReasonName\": null\n }\n ],\n \"MerchantGUID\": \"<MERCHANT_GUID>\",\n \"CurrencyCode\": \"EUR\",\n \"ReturnShippingCost\": 2020.9483,\n \"WebStoreCode\": \"Merchant01\",\n \"WebStoreInstanceCode\": \"01.webstore.com\"\n}"
response = http.request(request)
puts response.read_body{
"Success": "True",
"Message": "success message",
"Description": "success description"
}Send RMA Info to Merchant (Global-e to Merchant)
Global-e posts a MerchantReturn object (including the RMA number) to a merchant-hosted endpoint via the SendRMAInfoMerchant API.
POST
/
rma-info-to-merchant-url
Send RMA Info to Merchant (from Global-e)
curl --request POST \
--url https://{merchant_site_domain}/rma-info-to-merchant-url \
--header 'Content-Type: application/json' \
--data '
{
"OrderId": "GE24192321GB",
"MerchantOrderId": "71144",
"RMANumber": "223878",
"ShipperName": "DHL",
"ReturnTrackingNumber": "857854854778",
"TrackingURL": "www.dhl.com/Tracking?TrackingNumber=857854854778",
"CreatedBy": "Customer",
"ReturnedProducts": [
{
"SKU": "ProductD",
"Name": "Blue jacket",
"CartItemId": "2",
"ReturnQuantity": 1,
"ReturnReasonName": "Arrived too late",
"MerchantReturnReasonCode": null,
"MerchantReturnReasonName": null
}
],
"MerchantGUID": "<MERCHANT_GUID>",
"CurrencyCode": "EUR",
"ReturnShippingCost": 2020.9483,
"WebStoreCode": "Merchant01",
"WebStoreInstanceCode": "01.webstore.com"
}
'import requests
url = "https://{merchant_site_domain}/rma-info-to-merchant-url"
payload = {
"OrderId": "GE24192321GB",
"MerchantOrderId": "71144",
"RMANumber": "223878",
"ShipperName": "DHL",
"ReturnTrackingNumber": "857854854778",
"TrackingURL": "www.dhl.com/Tracking?TrackingNumber=857854854778",
"CreatedBy": "Customer",
"ReturnedProducts": [
{
"SKU": "ProductD",
"Name": "Blue jacket",
"CartItemId": "2",
"ReturnQuantity": 1,
"ReturnReasonName": "Arrived too late",
"MerchantReturnReasonCode": None,
"MerchantReturnReasonName": None
}
],
"MerchantGUID": "<MERCHANT_GUID>",
"CurrencyCode": "EUR",
"ReturnShippingCost": 2020.9483,
"WebStoreCode": "Merchant01",
"WebStoreInstanceCode": "01.webstore.com"
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
OrderId: 'GE24192321GB',
MerchantOrderId: '71144',
RMANumber: '223878',
ShipperName: 'DHL',
ReturnTrackingNumber: '857854854778',
TrackingURL: 'www.dhl.com/Tracking?TrackingNumber=857854854778',
CreatedBy: 'Customer',
ReturnedProducts: [
{
SKU: 'ProductD',
Name: 'Blue jacket',
CartItemId: '2',
ReturnQuantity: 1,
ReturnReasonName: 'Arrived too late',
MerchantReturnReasonCode: null,
MerchantReturnReasonName: null
}
],
MerchantGUID: '<MERCHANT_GUID>',
CurrencyCode: 'EUR',
ReturnShippingCost: 2020.9483,
WebStoreCode: 'Merchant01',
WebStoreInstanceCode: '01.webstore.com'
})
};
fetch('https://{merchant_site_domain}/rma-info-to-merchant-url', 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://{merchant_site_domain}/rma-info-to-merchant-url",
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([
'OrderId' => 'GE24192321GB',
'MerchantOrderId' => '71144',
'RMANumber' => '223878',
'ShipperName' => 'DHL',
'ReturnTrackingNumber' => '857854854778',
'TrackingURL' => 'www.dhl.com/Tracking?TrackingNumber=857854854778',
'CreatedBy' => 'Customer',
'ReturnedProducts' => [
[
'SKU' => 'ProductD',
'Name' => 'Blue jacket',
'CartItemId' => '2',
'ReturnQuantity' => 1,
'ReturnReasonName' => 'Arrived too late',
'MerchantReturnReasonCode' => null,
'MerchantReturnReasonName' => null
]
],
'MerchantGUID' => '<MERCHANT_GUID>',
'CurrencyCode' => 'EUR',
'ReturnShippingCost' => 2020.9483,
'WebStoreCode' => 'Merchant01',
'WebStoreInstanceCode' => '01.webstore.com'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$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://{merchant_site_domain}/rma-info-to-merchant-url"
payload := strings.NewReader("{\n \"OrderId\": \"GE24192321GB\",\n \"MerchantOrderId\": \"71144\",\n \"RMANumber\": \"223878\",\n \"ShipperName\": \"DHL\",\n \"ReturnTrackingNumber\": \"857854854778\",\n \"TrackingURL\": \"www.dhl.com/Tracking?TrackingNumber=857854854778\",\n \"CreatedBy\": \"Customer\",\n \"ReturnedProducts\": [\n {\n \"SKU\": \"ProductD\",\n \"Name\": \"Blue jacket\",\n \"CartItemId\": \"2\",\n \"ReturnQuantity\": 1,\n \"ReturnReasonName\": \"Arrived too late\",\n \"MerchantReturnReasonCode\": null,\n \"MerchantReturnReasonName\": null\n }\n ],\n \"MerchantGUID\": \"<MERCHANT_GUID>\",\n \"CurrencyCode\": \"EUR\",\n \"ReturnShippingCost\": 2020.9483,\n \"WebStoreCode\": \"Merchant01\",\n \"WebStoreInstanceCode\": \"01.webstore.com\"\n}")
req, _ := http.NewRequest("POST", url, payload)
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://{merchant_site_domain}/rma-info-to-merchant-url")
.header("Content-Type", "application/json")
.body("{\n \"OrderId\": \"GE24192321GB\",\n \"MerchantOrderId\": \"71144\",\n \"RMANumber\": \"223878\",\n \"ShipperName\": \"DHL\",\n \"ReturnTrackingNumber\": \"857854854778\",\n \"TrackingURL\": \"www.dhl.com/Tracking?TrackingNumber=857854854778\",\n \"CreatedBy\": \"Customer\",\n \"ReturnedProducts\": [\n {\n \"SKU\": \"ProductD\",\n \"Name\": \"Blue jacket\",\n \"CartItemId\": \"2\",\n \"ReturnQuantity\": 1,\n \"ReturnReasonName\": \"Arrived too late\",\n \"MerchantReturnReasonCode\": null,\n \"MerchantReturnReasonName\": null\n }\n ],\n \"MerchantGUID\": \"<MERCHANT_GUID>\",\n \"CurrencyCode\": \"EUR\",\n \"ReturnShippingCost\": 2020.9483,\n \"WebStoreCode\": \"Merchant01\",\n \"WebStoreInstanceCode\": \"01.webstore.com\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://{merchant_site_domain}/rma-info-to-merchant-url")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"OrderId\": \"GE24192321GB\",\n \"MerchantOrderId\": \"71144\",\n \"RMANumber\": \"223878\",\n \"ShipperName\": \"DHL\",\n \"ReturnTrackingNumber\": \"857854854778\",\n \"TrackingURL\": \"www.dhl.com/Tracking?TrackingNumber=857854854778\",\n \"CreatedBy\": \"Customer\",\n \"ReturnedProducts\": [\n {\n \"SKU\": \"ProductD\",\n \"Name\": \"Blue jacket\",\n \"CartItemId\": \"2\",\n \"ReturnQuantity\": 1,\n \"ReturnReasonName\": \"Arrived too late\",\n \"MerchantReturnReasonCode\": null,\n \"MerchantReturnReasonName\": null\n }\n ],\n \"MerchantGUID\": \"<MERCHANT_GUID>\",\n \"CurrencyCode\": \"EUR\",\n \"ReturnShippingCost\": 2020.9483,\n \"WebStoreCode\": \"Merchant01\",\n \"WebStoreInstanceCode\": \"01.webstore.com\"\n}"
response = http.request(request)
puts response.read_body{
"Success": "True",
"Message": "success message",
"Description": "success description"
}Part of the RMA Notifications (Global-e to Merchant) integration guide — see it for when and how to use this endpoint.
Body
application/json
Provides merchant return information.
Response
200 - application/json
API call response info. Check the Success field to distinguish success from failure; on failure, Message and Description carry the error text.
Indicates if the call has succeeded. Contains the Success, Message, and Description attributes.

