โ09-15-2021 02:28 PM
I'm having an issue with the mark as shipped in the API. It sends the tracking properly to Etsy, but Etsy shows the carrier as Other. I need it to show "UPS". When I confirm through the ShipStation site with UPS in the drop-down, it works ok. Here is the code I'm using:
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => "https://ssapi.shipstation.com/orders/markasshipped",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 0,
CURLOPT_FOLLOWLOCATION => true,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS =>"{\n \"orderId\": $orderID,\n \"carrierCode\": \"UPS\",\n \"trackingNumber\": \"$tracking\",\n \"notifyCustomer\": false,\n \"notifySalesChannel\": true\n}",
CURLOPT_HTTPHEADER => array(
"Host: ssapi.shipstation.com",
"Authorization: $auth",
"Content-Type: application/json"
),
));
$response = curl_exec($curl);
curl_close($curl);
Solved! Go to Solution.
โ09-20-2021 07:08 PM
Turns out you have to put \"ups\" instead of \"UPS\".
โ09-20-2021 07:08 PM
Turns out you have to put \"ups\" instead of \"UPS\".