- Data Factory
- RMA Event
Data Factory
RMA Event
Simulate RMA receiving and processing events (Sandbox only)
POST
/data_factory/rmaEvent
curl --request POST \
--url https://sandbox.masonhub.co/dragonfly-cosmetics-demo/api/v1/data_factory/rmaEvent \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
"customer_identifier": "<string>",
"event": "<string>",
"randomize_inventory_statuses": "false"
}'
curl --request POST \
--url https://sandbox.masonhub.co/dragonfly-cosmetics-demo/api/v1/data_factory/rmaEvent \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
"customer_identifier": "<string>",
"event": "<string>",
"randomize_inventory_statuses": "false"
}'Simulate RMA (Return Merchandise Authorization) receiving and processing events to test return workflows.
DataFactory is only available in the sandbox environment.
​Request Body
customer_identifier
required
string
RMA customer identifier.
event
required
string
RMA event type. Options: receiveFull, receivePartial, tendered, inTransit, delivered.
randomize_inventory_statuses
default:false
boolean
Randomize return inventory statuses for testing quality scenarios.
curl -X POST "https://app.masonhub.co/{account}/api/v1/data_factory/rmaEvent" \
-H "Authorization: Bearer your_jwt_token" \
-H "Content-Type: application/json" \
-d '[{
"customer_identifier": "rma123",
"event": "receiveFull",
"randomize_inventory_statuses": true
}]'
{
"success": true,
"data": [{
"customer_identifier": "rma123",
"event": "receiveFull",
"status": "received"
}]
}
​Available Events
​Randomization
When randomize_inventory_statuses is true, returned items are received into random statuses:
- available (resaleable)
- damaged
- quality-control
- refurbishing
- under-investigation
​Use Cases
curl -X POST "https://app.masonhub.co/{account}/api/v1/data_factory/rmaEvent" \
-H "Authorization: Bearer your_jwt_token" \
-H "Content-Type: application/json" \
-d '[{
"customer_identifier": "rma123",
"event": "receiveFull",
"randomize_inventory_statuses": true
}]'
curl --request POST \
--url https://sandbox.masonhub.co/dragonfly-cosmetics-demo/api/v1/data_factory/rmaEvent \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
"customer_identifier": "<string>",
"event": "<string>",
"randomize_inventory_statuses": "false"
}'
curl --request POST \
--url https://sandbox.masonhub.co/dragonfly-cosmetics-demo/api/v1/data_factory/rmaEvent \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
"customer_identifier": "<string>",
"event": "<string>",
"randomize_inventory_statuses": "false"
}'{
"success": true,
"data": [{
"customer_identifier": "rma123",
"event": "receiveFull",
"status": "received"
}]
}