---
title: "Returns | Docs | WMS by R&D Copilot"
description: "Receive goods a customer sends back: announce a return, count it, put the good units away and flag the rest."
canonical: "https://warehouse.rdcopilot.com/docs/guides/returns/"
language: en
updated: 2026-11-22
---

# Returns

Receive goods a customer sends back: announce a return, count it, put the good units away and flag the rest.

A return is an inbound delivery with `kind` `return`. It is received, put away and closed the way a delivery from a supplier is: see [Receive a delivery](https://warehouse.rdcopilot.com/docs/guides/receive-a-delivery/). Two things differ. `supplier` names the customer, and `reference` names the sales order the goods came from. The receipt is recorded as coming from the `customer`, not from a `supplier`.

1.  Announce the return
    
    Send `kind` `return`, the customer, the number of the sales order and the units the customer says are coming back.
    
2.  Count it
    
    Count each line when the goods arrive. Units that cannot be sold go in `damaged`; they never enter the stock. An item with a date comes back with its lot and expiry, and a lot that has passed its date is refused like any other.
    
3.  Put away what can be sold
    
    Put the good units away to a shelf of the right kind, and flag the damaged units and any gap.
    

curl

```bash
curl -X POST "$RDC_BASE_URL/warehouse/v1/inbound-deliveries" \
  -H "Authorization: Bearer $RDC_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
  "operationId": "18de47ed-5dfd-4951-82ea-b5b33ddb6e61",
  "kind": "return",
  "supplier": "Hanul Ozana SRL",
  "reference": "CV-1031",
  "expectedAt": "2026-11-25T08:00:00Z",
  "lines": [
    {
      "sku": "LA-0307",
      "expected": "4"
    }
  ]
}'
```

JavaScript

```javascript
const response = await fetch(`${process.env.RDC_BASE_URL}/warehouse/v1/inbound-deliveries`, {
  method: 'POST',
  headers: {
    Authorization: `Bearer ${process.env.RDC_TOKEN}`,
    'Content-Type': 'application/json',
  },
  body: JSON.stringify({
    "operationId": "18de47ed-5dfd-4951-82ea-b5b33ddb6e61",
    "kind": "return",
    "supplier": "Hanul Ozana SRL",
    "reference": "CV-1031",
    "expectedAt": "2026-11-25T08:00:00Z",
    "lines": [
      {
        "sku": "LA-0307",
        "expected": "4"
      }
    ]
  }),
});
const result = await response.json();
```

Python

```python
import os
import requests

response = requests.request(
    'POST',
    f'{os.environ["RDC_BASE_URL"]}/warehouse/v1/inbound-deliveries',
    headers={
        'Authorization': f'Bearer {os.environ["RDC_TOKEN"]}',
    },
    json={
        'operationId': '18de47ed-5dfd-4951-82ea-b5b33ddb6e61',
        'kind': 'return',
        'supplier': 'Hanul Ozana SRL',
        'reference': 'CV-1031',
        'expectedAt': '2026-11-25T08:00:00Z',
        'lines': [
            {
                'sku': 'LA-0307',
                'expected': '4',
            },
        ],
    },
)
result = response.json()
```

PHP

```php
<?php

$body = <<<'JSON'
{
  "operationId": "18de47ed-5dfd-4951-82ea-b5b33ddb6e61",
  "kind": "return",
  "supplier": "Hanul Ozana SRL",
  "reference": "CV-1031",
  "expectedAt": "2026-11-25T08:00:00Z",
  "lines": [
    {
      "sku": "LA-0307",
      "expected": "4"
    }
  ]
}
JSON;

$curl = curl_init(getenv('RDC_BASE_URL') . '/warehouse/v1/inbound-deliveries');
curl_setopt_array($curl, [
    CURLOPT_CUSTOMREQUEST => 'POST',
    CURLOPT_RETURNTRANSFER => true,
    CURLOPT_HTTPHEADER => [
        'Authorization: Bearer ' . getenv('RDC_TOKEN'),
        'Content-Type: application/json',
    ],
    CURLOPT_POSTFIELDS => $body,
]);
$result = json_decode(curl_exec($curl), true);
curl_close($curl);
```

C#

```csharp
using System.Net.Http.Headers;

var client = new HttpClient();
var request = new HttpRequestMessage(HttpMethod.Post, $"{Environment.GetEnvironmentVariable("RDC_BASE_URL")}/warehouse/v1/inbound-deliveries");
request.Headers.Authorization = new AuthenticationHeaderValue("Bearer", Environment.GetEnvironmentVariable("RDC_TOKEN"));
request.Content = new StringContent("""
{
  "operationId": "18de47ed-5dfd-4951-82ea-b5b33ddb6e61",
  "kind": "return",
  "supplier": "Hanul Ozana SRL",
  "reference": "CV-1031",
  "expectedAt": "2026-11-25T08:00:00Z",
  "lines": [
    {
      "sku": "LA-0307",
      "expected": "4"
    }
  ]
}
""", System.Text.Encoding.UTF8, "application/json");
var response = await client.SendAsync(request);
var result = await response.Content.ReadAsStringAsync();
```

Response 202

```json
{
  "operationId": "18de47ed-5dfd-4951-82ea-b5b33ddb6e61",
  "status": "accepted",
  "aggregateRevision": 1
}
```
