E-commerce API
POST /services/webshop/v1/customer/orders/reorder Auth

Reorder a past order

Appends every line item from a past order onto the authenticated customer's active shopping cart at current prices. Stock is NOT checked here — the cart's existing checkout flow validates availability when the customer proceeds to pay. Only products that have been deleted or disabled in the catalog are skipped (their rows can't be inserted). Shipping methods and discount codes are NOT carried over — the customer re-selects shipping at checkout, and automatic discounts (customer-tier, sale, campaign) re-evaluate against the cart's current state.

Request Body Required

FieldTypeRequiredDescriptionExample
order_id integer Yes 2502

Responses

200
404
422
401
429
Reorder applied to the customer's cart
Headers
HeaderTypeDescriptionExample
X-RateLimit-Limit integer Maximum number of requests allowed per minute 60
X-RateLimit-Remaining integer Number of requests remaining in the current window 57
FieldTypeDescription
error boolean
message string
data object
data.shoppingcart_session string|null
data.added_count integer Counts up front so the storefront can render the toast without iterating the lists itself: "Added 4 items" / "1 unavailable".
data.skipped_count integer
data.added string[]
data.skipped string[]
Order not found or not owned by the authenticated customer
Headers
HeaderTypeDescriptionExample
X-RateLimit-Limit integer Maximum number of requests allowed per minute 60
X-RateLimit-Remaining integer Number of requests remaining in the current window 57
FieldTypeDescription
error boolean
message string
data mixed[]
Validation error
FieldTypeDescription
message string Errors overview.
errors object A detailed description of each field that failed validation.
Unauthenticated — missing or invalid Bearer token
Headers
HeaderTypeDescriptionExample
X-RateLimit-Limit integer Maximum number of requests allowed per minute 60
X-RateLimit-Remaining integer Number of requests remaining in the current window 57
FieldTypeDescription
error boolean
message string
Too Many Requests — rate limit exceeded
Headers
HeaderTypeDescriptionExample
X-RateLimit-Limit integer Maximum number of requests allowed per minute 60
X-RateLimit-Remaining integer Number of requests remaining in the current window 57
Retry-After integer Seconds until the rate limit resets 60
FieldTypeDescription
error boolean
message string
Base URL
https://api.wemasy.nl/api
Authentication

Request Sample
cURL
JS
PHP
Python
curl -X POST "https://api.wemasy.nl/api/services/webshop/v1/customer/orders/reorder" \
  -H "Authorization: Bearer YOUR_API_TOKEN" \
  -H "Accept: application/json" \
  -H "Content-Type: application/json" \
  -d '{
    "order_id": 2502
}'
fetch('https://api.wemasy.nl/api/services/webshop/v1/customer/orders/reorder', {
  method: 'POST',
  headers: {
    'Authorization': 'Bearer YOUR_API_TOKEN',
    'Accept': 'application/json',
    'Content-Type': 'application/json'
  },
  body: JSON.stringify({
    "order_id": 2502
})})
.then(r => r.json())
.then(data => console.log(data));
$response = Http::withToken('YOUR_API_TOKEN')
    ->accept('application/json')
    ->post('https://api.wemasy.nl/api/services/webshop/v1/customer/orders/reorder', {
    "order_id": 2502
});
$data = $response->json();
import requests

headers = {
    "Authorization": "Bearer YOUR_API_TOKEN",
    "Accept": "application/json"
}
data = {
    "order_id": 2502
}
r = requests.post("https://api.wemasy.nl/api/services/webshop/v1/customer/orders/reorder", headers=headers, json=data)
print(r.json())
Response Example
{
    "shoppingcart_session": "abc123def456ghi789",
    "added_count": 2,
    "skipped_count": 1,
    "added": [
        {
            "product_id": 42,
            "quantity": 2,
            "title": "Blue T-Shirt"
        },
        {
            "product_id": 13,
            "quantity": 1,
            "title": "Cotton Mug"
        }
    ],
    "skipped": [
        {
            "product_id": 7,
            "reason": "unavailable",
            "title": "Discontinued Mug"
        }
    ]
}

Try It
Request Body Required

Export