Return Methods
GetReturnShippingOptions (Merchant to Global-e)
The Return Shipping Options API provides essential return information, including a list of return shipping methods and costs.
Important
Global-e must enable and configure this API on the Global-e side.
Method/URL
POST https://{globale_api_domain}/Return/GetReturnShippingOptions
Parameters
Request
Name | Type | Description | Mandatory |
---|---|---|---|
| String | 10-character code. Default is EN Maximum: 10 characters. | No |
| String | The currency of the return prepaid shipping cost. This is a 3-char ISO currency code. The default should be the same as the origin order currency. If the submitted order currency is not the same as the (outbound) order, apply the currency exchange. | No |
| String | Email that identifies the source of the request | No |
| String | Unique Global-e Order ID or Merchant Order ID. Maximum: 100 characters. | Yes |
| String | Provider name that identifies the source of the request. | Yes |
| Array of<Products> | Each product object has the following fields:
| Yes |
| Long | Provides the ID of the return shipping method. | No |
Response
Name | Type | Description | Mandatory |
---|---|---|---|
| Double | The cost of the shipment | Yes |
| String | 3-letter currency ISO code | Yes |
| Boolean | Whether this is a label-free return (QR code only). Only applicable to the True for a label-free return Falsefor a return with label | No |
| Boolean | True for carriers that Global-e has Tracking events integrations with. False for carriers for which Global-e does not support Tracking capabilities. | Yes |
| String | The unique merchant Order ID. Maximum: 100 characters | Yes |
| String | The unique Global-e Order ID. Maximum: 100 characters | Yes |
| The Contains the following values:
| Yes | |
| Array of <ReturnShippingMethods> |
| Yes |
| String | Description of the shipping method. | Yes |
| Int | The shipping method identifier. Can be used when calling GetReturnDocuments to receive the return document for the selected shipping method. | Yes |
| String | Identifies the shipping method type. | Yes |
[ShippingMethodTypeId] | Int | Possible values:
Can be used when calling GetReturnDocuments to receive the return document for the selected shipping method. | Yes |
| String | The name of the shipping service of the return provider | Yes |
Objects for GetReturnShippingOptions API
Error Responses
General Error Response
{ "Code": "error code", "Error": "error message", "Description: "error description" }
Error Codes
Code | Message |
---|---|
E01 | Could not find an available shipping method (No shipping method was found for the submitted products and quantities) |
E02 | Return is not allowed due to order status %Order Status% (Relates to Allowed Return Statuses) |
E03 | Order ID not found (Returned if the provided OrderId cannot be found for the merchant) |
E04 | Currency is not valid |
E05 | There are multiple orders with this orderID %orderID% |
E06 | The ReturnShippingMethodId %ReturnShippingMethodId% is not valid |
ME01 | Input value for ProductCode is not valid |
ME02 | Input value for CartItemId is not valid |
ME03 | Input value for ReturnQuantity is not valid |
ME06 | Input value for OrderId is not valid |
ME07 | Input value for Email is not valid |
ME09 | Input value for ReturnedProducts is not valid |
ME10 | Input value for CultureCode is not valid |
ME12 | Input value for CurrencyCode is not valid |
ME13 | Input value for ProviderCode is not valid |
SME15 | Input value for ReturnShippingMethodId is not valid |
See also Product Errors.
Examples
Examples
Request
{ "ProviderCode": "ExampleProvider", "OrderId": "EUQA6215359", "Email": [email protected], "ReturnedProducts": [ { "ProductCode": "433117270672", "ReturnQuantity": 1 } ] }
Response
{ "IsSuccess": true, "Data": { "OrderId": "GE10470948238NL", "MerchantOrderId": "EUQA6215359", "ReturnShippingMethods": [ { "ShippingMethodId": 40044878, "ShippingMethodDescription": "DHL-GlobalE", "ShippingMethodType": "Express Courier (Air)", "ShippingMethodTypeID": 2, "ShipperName": "DHL", "IsQrLabel": false, "IsTrackable": true, "Cost": 0.0, "Currency": "EUR" } ], "ReturnShippingDestinationDetails": { "Country": "Netherlands", "City": "Amsterdam", "Address": "Ood 5", "Zip": "4751XK", "StateOrProvince": "", "Email": [email protected], "Phone": "310610887191" } }
GetReturnDocuments
GetReturnDocuments (Merchant to Global-e)
Use the GetReturnDocuments
API to integrate the return documents capability into your Returns Portal or through a 3rd party returns provider.
The API return documents and related information, including the label, the tracking number, the tracking URL, the shipper name, the commercial invoice (if relevant), the RMA number, and the return note. In addition, Global-e creates a Global-e RMA.
Note: Electronic invoices are not returned.
Important
Global‑e enables and configures this API on the Global‑e side.
Method/URL
POST https://{globale_api_domain}/Return/GetReturnDocuments
Parameters
Request
Field | Type | Description | Mandatory |
---|---|---|---|
| String | The language for the Return Note document. Currently, English is the only supported language. Maximum 10 characters | No |
| String | The currency of the returned prepaid shipping cost (*) Mandatory: Yes, if the Maximum 3 characters | Yes |
| String | The customer's email address Maximum 100 characters | Yes |
| String | The Merchant's internal RMA Number Maximum 200 characters | No |
| String | The order unique ID Maximum 100 characters | Yes |
| String | The Provider's name identifies the source of the request. | Yes |
| Array | An array of returned products' details. | Yes |
| Integer | Based on the end customer's selected shipping method, as returned in the Get Return Shipping Options response. If empty, Global‑e uses the cheapest method based on the return shipping type id. | No |
| Integer | Possible values:
| No |
| Decimal | The prepaid shipping cost associated with the return. If not provided, then the | No |
Response
If the API call is successful, the Data object returns the documents required for the return. If the call fails, it returns FailedTrackingNumbers.
Field | Type | Description |
---|---|---|
| Object Data | Provides information about the order. If the API call is successful, returns the documents required for the return. |
| String | If the API call fails, provides information about the failure. |
| Boolean | True: If the API call is successful. False: If the API call fails. |
Objects for GetReturnsDocuments API
Error Codes
Error Code | Error Message |
---|---|
E01 | Could not create the shipping label <Note: Not applicable to the self-postage option.> |
E02 | The return is not allowed due to the order status ({0}) <See also Allowed Return Statuses> |
E03 | The Order ID was not found |
E04 | There is already an RMA request for this order ({0}) |
E05 | There are multiple orders with these details ({0}) |
E06 | The return is not allowed due to the parcel status ({0}) <See also Allowed Return Statuses> |
E07 | Unable to find the shipping method for the provided return shipping method Id ({0}) <See also Return Shipping Service Types > |
E08 | The provided ReturnShippingTypeId is not valid ({0}) <See also Return Shipping Service Types> |
E09 | There are multiple orders with this Order ID ({0}) |
E10 | No shipping options were found for the order return ({0}) |
E11 | The return shipping address was not found for order ({0}) |
E12 | Invalid currency code for the provided shipping cost for order ({0}) |
E13 | The return shipping request failed for order ({0}) |
E14 | The return shipping cost cannot be a negative number |
E15 | The return shipping cost is greater than the return product price |
Examples
Request
curl --location 'https://[globale domain]/Return/GetReturnDocuments' \ --header 'MerchantGUID: D2ED2A7F-F6ED-4CCB-B611-B44AC8D02250' \ --header 'Content-Type: application/json' \ --data-raw '{ "ProviderCode": "Loop", "OrderId": "GE314856569TS", "Email": "[email protected]", "MerchantRMANumber": "RM132", "ShippingCost": 10.0, "CurrencyCode": "USD", "ReturnShippingTypeId": 2, "ReturnShippingMethodId": null, "ReturnedProducts": [ { "ProductCode": "DKB500680.M8", "ProductSecondaryCode": "", "CartItemId": null, "ReturnQuantity": 1, "MerchantReturnReasonCode": "", "MerchantReturnReasonDescription": "Return Reason from GRD request for product 1" }, { "ProductCode": "B7ECS.C8", "ProductSecondaryCode": "", "CartItemId": 1, "ReturnQuantity": 1, "MerchantReturnReasonCode": "TTT", "MerchantReturnReasonDescription": "Return Reason from GRD request for product 2" } ] }'
Response
Success
{ "IsSuccess": true, "Data": { "OrderId": "GE314856569TS", "MerchantOrderId": "314856569", "GlobaleRmaNumber": "371104", "ReturnTrackingDetails": { "TrackingNumber": "1ZXXXXXXXXXXXXXXXX", "TrackingURL": "https://wwwapps.ups.com/tracking/tracking.cgi?tracknum=1ZX&requester=ST/", "IsQrLabel": "false", "IsTrackable": true }, "ReturnDocuments": [ { "DocumentTypeCode": "ShippingLabel", "DocumentTypeName": "Shipping Label", "DocumentData": "AQCkosNhECNeAACYzH/NIA5NgtHU2QAAAABJRU5ErkJggg==", "URL": "https://[MerchantDomain]/url" } ] }, "Errors": null }
Failure
Example 1
{ "IsSuccess": false, "Data": null, "Errors": [ { "Code": "E500", "Error": "We encountered an unexpected error and are working to resolve the issue." } ] }
Example 2
{ "IsSuccess": false, "Data": null, "Errors": [ { "Code": "PE27", "Error": "Return products collection has duplication" }, { "Code": "PE07", "Error": "Return product (DKB500680.M8) was not found for order" }, { "Code": "PE07", "Error": "Return product (B7ECS.C8) was not found for order" } ] }
SendRMAToMerchant (Global-e to Merchant)
Use the SendRMAToMerchant API to send the Global‑e RMA number to the merchant. Sends MerchantReturn object to the merchant.
MerchantAppSetting
, SendRMAInfoToMerchantURI
must be set to turn on this feature.
Method/URL
POST https://www.merchant-site-domain.com/rma-info-to-merchant-url
Parameters
Request
Name | Type | Description | Mandatory |
---|---|---|---|
merchantOrder | Object merchantOrder | Provides order return details. | |
merchantReturn | Object merchantReturn | Provides merchant return information. Includes the following information:
|
Return
Name | Type | Description | Mandatory |
---|---|---|---|
merchant.ResponseInfo | Object Merchant.ResponseInfo | Provides API call response info. |
Objects for SendRMAToMerchant API
Examples
Request Example
{ "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": "7e3d5523-d86a-4c56-8f47-5a48b829e3b7", "CurrencyCode": "EUR", "ReturnShippingCost": 10.00 }
Response Example
{ "Success": "True", "Message": "success message", "Description": "success description" }
Tracking Events API
Prerequisites
The request can include a list of global-e order IDs, a list of tracking events, or both, but all the same type: Inbound or Outbound. Each request can report on either inbound orders or outbound, but not both. For requesting inbound and outbound tracking events, two different requests should be issued.
GetTrackingEvents (Merchant to Global-e)
The Get Tracking Events API lets you receive status events on the delivery status of an order. Reporting of tracking events allows both our customers and 3rd parties to stay informed about the exact location and status of returned items throughout the entire external return journey.
With that, having tracking events for return shipments allows to trigger refunds automatically upon confirmation of returned item receipt (or any other tracking event).
The API accepts one or more order ID numbers, up to 100, on a single call, a list of either orders moved to forward shipments, after checkout completion (outbound), or returns (inbound) and returns their status.
Method/URL:
POST https://{globale_api_domain}/Shipment/GetTrackingEvents
Regarding the API domain, for more details about relevant environments, see Global-e Environments.
Parameters
Request
Parameter | Type | Description | Mandatory |
---|---|---|---|
| DateTime | Date and time for the earliest time of the order shipment status, UTC, in RFC 2822 format (for example, Fri, 8 Aug 2014 17:13:07 +0000). | No |
| List of strings | List of Global‑e Order IDs. Up to 100 in each request. Note: each Max length:100 chars. | One of either |
| List of strings | List of Global‑e tracking numbers. Up to 100 in each request, with prefix | Conditional |
| String | The shipment direction. One of the following:
| Yes |
Response
Parameter | Type | Description | Mandatory |
---|---|---|---|
| List<FailedTrackingNumbers> | List of objects containing detailed error information. The object includes:
| |
| Object SuccessfulTrackingNumbers | The events for each
|
Objects for GetTrackingEvents API
Global-e Tracking Events
The following table lists all the tracking events reported by Global-e:
GlobaleEventCode | GlobaleEventDescription |
---|---|
1 | The parcel has been created but is waiting to be manifested (i.e. despatched) |
2 | The parcel has been manifested (i.e.. despatched) |
3 | The carrier has yet to receive the parcel into their network |
4 | The carrier has acknowledged receipt of the parcel into their network |
5 | The carrier has acknowledged receipt of the parcel into their network but did not receive the required electronic manifest (pre advice file) |
6 | A collection request has been acknowledged by the carrier |
7 | The carrier has successfully collected a parcel from a customer |
8 | The carrier has failed to collect a parcel from a customer |
9 | The parcel has been misrouted by the carrier due to incorrect routing on the label |
10 | The parcel has been misrouted by the carrier due to incorrect routing on the label |
11 | The parcel has been advised as lost within the carriers network |
12 | The parcel has been delayed due to factors beyond the carriers control (i.e. inclement weather) |
13 | The parcel is with Customs (NR: This does not necessarily mean that the parcel has been refused entry into the destination country) |
14 | The parcel has been damaged |
15 | The parcel is in transit (NB: This could either be en route to a country hubs delivery depot) |
16 | The parcel has been Left at the local post office for collection |
17 | The parcel is with a 3rd party sub-contractor and a tracking event has occurred (refer to "Confirmation' field for further information if provided |
18 | The parcel has left the delivery depot for the recipients address |
19 | The parcel has been received by a sub-contractor 3rd party |
20 | The carrier has a query concerning the recipients address (i.e. Unable to locate,. incorrect post code etc.) |
21 | The carrier has left a calling card for the customer as they were unable to deliver the parcel |
22 | The carrier has delivered part of the consignment advised (e.g. Parcel 1 parcel of a 2 parcel consignment has been delivered) |
23 | The parcel is available to collect from the carriers premises |
24 | The parcel is being held at the delivery depot |
25 | The recipient no longer resides at the delivery address |
26 | The recipient refused to take delivery of the parcel |
27 | The parcel is to be returned to the sender |
28 | The carrier was unable to deliver the parcel (No reason specified) |
29 | The parcel has been successfully delivered |
30 | The carrier has provided some information concerning the parcel |
31 | An event has occurred after the parcel has been delivered / lost or RTS (i.e._ acknowledgement of a claim) |
32 | Special delivery instructions to app.? |
33 | The delivery / collection has requested to be cancelled |
34 | The carrier has received an electronic pre advice (manifest) for this parcel |
35 | The parcel has been at a bstatus that does not set an actual or default end date and as such has been 'closed" after a certain period of time dependent on the environment it belongs to |
36 | The parcel was miss sorted by the carrier and sent to the incorrect -deliver? dept. |
37 | The recipient has arranged a delivery with the carrier |
38 | The carrier attempted to deliver the parcel but was unable to access the recipients address to deliver or leave a inning card (i.e. Closed office building, gate-d development etc) |
39 | The payment for cash on delivery could not be collected |
40 | The recipient's identification failed |
41 | The payment could not be processed due to an invalid method of payment by recipient. |
42 | The payment for cash on delivery of parcel has been collected by the carrier |
43 | The parcel has been cleared for delivery |
44 | The parcel has been re boxed / re packed |
45 | The parcel has been requested to be disposed |
46 | The declared weight of the parcel does not match the actual weight of the parcel. |
47 | The parcel has been held by destination Customs |
48 | The parcel has been held by origin Customs |
49 | The parcel has been delivered to a neighbour's address |
50 | The parcel has been delivered to a safe place suggested by the recipient |
51 | The customer has collected the parcel from the store |
52 | The parcel is received at store and is ready for collection by recipient_ |
53 | The parcel is ready for collection at the store and it has not been collected after a period of time |
54 | The parcel has been delivered to a locker or collection point and is ready to be collected by the recipient. |
55 | The parcel has been delivered to the recipient's preferred point instead of collecting from depot or re-delivery or return |
56 | The package has been held by the carrier whilst collecting recipient details for clearance |
57 | The parcel has been re-labelled |
58 | The parcel attributes lie outside of service capability i.e. weight/size/remote area issues |
59 | An SMS has been transmitted to the recipient to inform that the parcel is out for deliver). today |
60 | An email has been transmitted to the recipient to inform that the parcel is out for delivery today |
61 | The carrier attempted delivering the parcel but could not deliver |
62 | The package/s arrived to the destination country |
63 | A choice that the customer has made for delivery to a safe place (the delivery not happened yet) |
Examples
Request
Request for only Global-e orders:
curl --location 'https://[globale domain]/Shipment/GetTrackingEvents' \ --header 'MerchantGUID: D2ED2A7F-F6ED-4CCB-B611-B44AC8D02250' \ { "EventSinceInUTC": "2025-04-01T20:08:05Z", "Type": "outbound", "OrderIds": [ "GE381652418TS" ], "TrackingNumbers":[ ]}
Response
{ "Data": { "SuccessfulTrackingNumbers": [ { "GlobaleOrderID": "GE381652418US", "MerchantOrderID": "#22165241", "GlobaleParcelCode": "null", "GlobaleRMANumber": "2832849023948", "MerchantRMANumber": "832849932893", "IsTrackingNumberActive": true, "TrackingNumber": "GE381652418TS2864637A0", "Type": "outbound", "TrackingUrl": "https://mailingtechnology.com/tracking/?tn=GE381652418TS2864637A0", "ShipperName": "Spring XBS Packet Registered-GlobalE", "TrackingEvents": [ { "ShipperEventDescription": "The parcel has been created but is waiting to be manifested (i.e. despatched)", "TrackingEventDateTimeInUTC": "2024-03-24T09:19:08", "GlobaleEventCode": "1", "GlobaleEventDescription": "The parcel has been created but is waiting to be manifested (i.e. despatched)", "ShipperEventCode": "0", "TrackingEventStatus": [], "Location": { "FullAddress": "BALTIMORE AIRPORT,MD-USA" } } ] }, { "GlobaleOrderID": "GE8770052418US", "MerchantOrderID": "#23816524", "GlobaleParcelCode": "null", "GlobaleRMANumber": "0239283284948", "MerchantRMANumber": "8884994993293", "IsTrackingNumberActive": true, "TrackingNumber": "GE381652418TS2864637A0", "Type": "outbound", "TrackingUrl": "https://mailingtechnology.com/tracking/?tn=GE381652418TS2864637A0", "ShipperName": "Spring XBS Packet Registered-GlobalE", "TrackingEvents": [ { "ShipperEventDescription": "The parcel has been created but is waiting to be manifested (i.e. despatched)", "TrackingEventDateTimeInUTC": "2024-03-24T09:19:16", "GlobaleEventCode": "1", "GlobaleEventDescription": "The parcel has been created but is waiting to be manifested (i.e. despatched)", "ShipperEventCode": "0", "TrackingEventStatus": [], "Location": { "FullAddress": "BALTIMORE AIRPORT,MD-USA" } } ] } ], "FailedTrackingNumbers": [ { "OrderId": "ABC123", "TrackingNumber": "123", "ErrorInfo": { "Code": "E06", "Error": "The tracking number (123) is not associated with the merchant", "Description": null }, "Success": false } ] }, "Errors": null }
UpdateRMA
Call the UpdateRMA
API to set or update the MerchantRMANumber
and send an email to the customer.
Method/URL
https://{server_name}/Return/UpdateRMA?merchantGUID= F3BE2R-8546-FC38-90SJ-1C780SG8F90SBS
Parameters
Request
Name | Type | Description | Mandatory |
---|---|---|---|
updateRMANumber | Object MerchantRMANumber | Provides API call response info. |
Return
Name | Type | Description | Mandatory |
---|---|---|---|
merchant.ResponseInfo | Object Merchant.ResponseInfo | Provides API call response info. |
Objects for SendRMAToMerchant API
Examples
Request
{ “OrderId”: ”12345”, (optional) “MerchantOrderId”: ”09876”, (optional) ”RMANumber”: ”852147”, ”MerchantRMANumber”: ”265646925” }