For the complete documentation index, see llms.txt. This page is also available as Markdown.

Duty-free returns - RGR

Duty-free returns, or Returned Goods Relief (RGR), is a service offered by DHL to exempt the contract owner from customs duties for products returned from abroad (ONLY for outbound and return flows).

Gsped provides the RGR endpoint to generate the SPED file for the outbound shipment only, or to generate the RGR file for the return shipment.

RGR endpoint

POST https://api.gsped.it/[INSTANCE]/dhl/rgr

Headers

Name
Value

Content-Type

application/json

x-api-key

YOUR API KEY

Body

Name
Type
Description

flag_reso*

number

Whether or not this is a return shipment. Possible values: 0 -> Outbound shipment 1 -> Return shipment

client_id*

number

Value provided by Gsped

num_spedizione*

string

Shipment number (tracking number)

colli*

number

Number of parcels

addebito_dogana*

number

Numeric value indicating who bears the customs duties. Possible values: 0 -> Recipient 1 -> Sender

valuta*

string

Three-character code indicating the reference currency (Example EUR)

rcpt_email*

string

Recipient's email address

rcpt_name*

string

Recipient's name

rcpt_addr*

string

Recipient's address

rcpt_city*

string

Recipient's city

rcpt_country_code*

string

Recipient's country as a 2-character ISO code

sender_eori*

string

Sender's EORI code

ordersData*

object

Contains the details of the order and/or of the shipped goods

ordersData.totale_lordo*

number

Total value of the shipped goods

ordersData.invoice_number*

string

Invoice number and/or order reference

ordersData.invoice_date*

string

Invoice date in YYYY-MM-DD format

ordersData.detailsData*

array

Array containing the details of the shipped products

ordersData.detailsData.*.sku*

string

Product SKU

ordersData.detailsData.*.description*

string

Product description

ordersData.detailsData.*.hs_code*

string

Product HS Code

ordersData.detailsData.*.country_of_origin*

string

Product country of origin

ordersData.detailsData.*.prezzo_singolo*

number

Unit price of the product

ordersData.detailsData.*.qty*

number

Number of items shipped

ordersData.detailsData.*.peso_riga*

number

Product weight

originalAwbData

object

Contains the data of the outbound shipment. Please note: Only if this is a return (flag_reso = 1)

originalAwbData.num_spedizione

string

Tracking number of the outbound shipment

originalAwbData.detailsData

array

Array containing the details of the products shipped in the outbound shipment

originalAwbData.detailsData.*.sku

string

Product SKU

Legend:

* -> Required data

* -> Data required ONLY for an outbound shipment

Response

Examples

Payload to generate the SPED file for outbound shipments:

Payload to generate the RGR file for return shipments:

Log

The files sent are saved in the gsped-etds bucket on S3.