Discussions
edit order after dispatched payload requires nesting in "order" object?
Hi RR support, I'm calling this endpoint: /edit-order-after-dispatched
If I give it this data object in a curl request:
--data '{ "billing_option": "prepaid", "dim_type": "ltl", "default_weight_unit_id" : "mt", "default_measurement_unit_id": "cm"}'
It fails with:
{"error_code":"5-999","error_message":"Field Validation Errors: \n1. Field \u003crequest_validator.orders_edit_after_dispatched_request.order.dim_type\u003e (Type: string) must be a valid dim type: [ltl, ftl, cube]. \n2. Field \u003crequest_validator.orders_edit_after_dispatched_request.order.default_measurement_unit_id\u003e (Type: string) must be a valid measurement unit: [inch, cm, km, mi]. ...
However, it works if I nest the data into an "order" object:
--data '{ "order":{"billing_option": "prepaid", "dim_type": "ltl", "default_weight_unit_id" : "mt", "default_measurement_unit_id": "cm"}}'
Is this intended? The create booked order endpoint: create-booked-order didn't require it IIRC.