POST /api/updateOrder/520718/ShippingMethod?recipeid=00000000-0000-0000-0000-000000000000&partnerBillingKey=oeO2j1ZbfU0TaDPRrhStEyp68ZRbXK8UfWfq7BKICGY%3D HTTP/1.1
Content-Type: application/json
Host: api.print.io
Content-Length: 113

{
  "ShipmentMethod": [
    {
      "OrderItemIds": [1044686],
      "NewShippingMethod": "Expedited"
    }
  ]
}
var settings = {
  "async": true,
  "crossDomain": true,
  "url": "https://api.print.io/api/updateOrder/520718/ShippingMethod?recipeid=00000000-0000-0000-0000-000000000000&partnerBillingKey=oeO2j1ZbfU0TaDPRrhStEyp68ZRbXK8UfWfq7BKICGY%3D",
  "method": "POST",
  "headers": {
    "content-type": "application/json"
  },
  "processData": false,
  "data": "{\n  \"ShipmentMethod\": [\n    {\n      \"OrderItemIds\": [1044686],\n      \"NewShippingMethod\": \"Expedited\"\n    }\n  ]\n}"
}

$.ajax(settings).done(function (response) {
  console.log(response);
});
fetch("https://api.print.io/api/updateOrder/520718/ShippingMethod?recipeid=00000000-0000-0000-0000-000000000000&partnerBillingKey=oeO2j1ZbfU0TaDPRrhStEyp68ZRbXK8UfWfq7BKICGY%3D", {
  "method": "POST",
  "headers": {
    "content-type": "application/json"
  },
  "body": {
    "ShipmentMethod": [
      {
        "OrderItemIds": [
          1044686
        ],
        "NewShippingMethod": "Expedited"
      }
    ]
  }
})
.then(response => {
  console.log(response);
})
.catch(err => {
  console.log(err);
});
var data = JSON.stringify({
  "ShipmentMethod": [
    {
      "OrderItemIds": [
        1044686
      ],
      "NewShippingMethod": "Expedited"
    }
  ]
});

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("POST", "https://api.print.io/api/updateOrder/520718/ShippingMethod?recipeid=00000000-0000-0000-0000-000000000000&partnerBillingKey=oeO2j1ZbfU0TaDPRrhStEyp68ZRbXK8UfWfq7BKICGY%3D");
xhr.setRequestHeader("content-type", "application/json");

xhr.send(data);
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.print.io/api/updateOrder/520718/ShippingMethod?recipeid=00000000-0000-0000-0000-000000000000&partnerBillingKey=oeO2j1ZbfU0TaDPRrhStEyp68ZRbXK8UfWfq7BKICGY%3D",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "POST",
  CURLOPT_POSTFIELDS => "{\n  \"ShipmentMethod\": [\n    {\n      \"OrderItemIds\": [1044686],\n      \"NewShippingMethod\": \"Expedited\"\n    }\n  ]\n}",
  CURLOPT_HTTPHEADER => array(
    "content-type: application/json"
  ),
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
<?php

$request = new HttpRequest();
$request->setUrl('https://api.print.io/api/updateOrder/520718/ShippingMethod');
$request->setMethod(HTTP_METH_POST);

$request->setQueryData(array(
  'recipeid' => '00000000-0000-0000-0000-000000000000',
  'partnerBillingKey' => 'oeO2j1ZbfU0TaDPRrhStEyp68ZRbXK8UfWfq7BKICGY='
));

$request->setHeaders(array(
  'content-type' => 'application/json'
));

$request->setBody('{
  "ShipmentMethod": [
    {
      "OrderItemIds": [1044686],
      "NewShippingMethod": "Expedited"
    }
  ]
}');

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
<?php

$client = new http\Client;
$request = new http\Client\Request;

$body = new http\Message\Body;
$body->append('{
  "ShipmentMethod": [
    {
      "OrderItemIds": [1044686],
      "NewShippingMethod": "Expedited"
    }
  ]
}');

$request->setRequestUrl('https://api.print.io/api/updateOrder/520718/ShippingMethod');
$request->setRequestMethod('POST');
$request->setBody($body);

$request->setQuery(new http\QueryString(array(
  'recipeid' => '00000000-0000-0000-0000-000000000000',
  'partnerBillingKey' => 'oeO2j1ZbfU0TaDPRrhStEyp68ZRbXK8UfWfq7BKICGY='
)));

$request->setHeaders(array(
  'content-type' => 'application/json'
));

$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
import http.client

conn = http.client.HTTPSConnection("api.print.io")

payload = "{\n  \"ShipmentMethod\": [\n    {\n      \"OrderItemIds\": [1044686],\n      \"NewShippingMethod\": \"Expedited\"\n    }\n  ]\n}"

headers = { 'content-type': "application/json" }

conn.request("POST", "/api/updateOrder/520718/ShippingMethod?recipeid=00000000-0000-0000-0000-000000000000&partnerBillingKey=oeO2j1ZbfU0TaDPRrhStEyp68ZRbXK8UfWfq7BKICGY%3D", payload, headers)

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
import requests

url = "https://api.print.io/api/updateOrder/520718/ShippingMethod"

querystring = {"recipeid":"00000000-0000-0000-0000-000000000000","partnerBillingKey":"oeO2j1ZbfU0TaDPRrhStEyp68ZRbXK8UfWfq7BKICGY="}

payload = "{\n  \"ShipmentMethod\": [\n    {\n      \"OrderItemIds\": [1044686],\n      \"NewShippingMethod\": \"Expedited\"\n    }\n  ]\n}"
headers = {'content-type': 'application/json'}

response = requests.request("POST", url, data=payload, headers=headers, params=querystring)

print(response.text)
curl --request POST \
  --url 'https://api.print.io/api/updateOrder/520718/ShippingMethod?recipeid=00000000-0000-0000-0000-000000000000&partnerBillingKey=oeO2j1ZbfU0TaDPRrhStEyp68ZRbXK8UfWfq7BKICGY%3D' \
  --header 'content-type: application/json' \
  --data '{
  "ShipmentMethod": [
    {
      "OrderItemIds": [1044686],
      "NewShippingMethod": "Expedited"
    }
  ]
}'
echo '{
  "ShipmentMethod": [
    {
      "OrderItemIds": [1044686],
      "NewShippingMethod": "Expedited"
    }
  ]
}' |  \
  http POST 'https://api.print.io/api/updateOrder/520718/ShippingMethod?recipeid=00000000-0000-0000-0000-000000000000&partnerBillingKey=oeO2j1ZbfU0TaDPRrhStEyp68ZRbXK8UfWfq7BKICGY%3D' \
  content-type:application/json
wget --quiet \
  --method POST \
  --header 'content-type: application/json' \
  --body-data '{\n  "ShipmentMethod": [\n    {\n      "OrderItemIds": [1044686],\n      "NewShippingMethod": "Expedited"\n    }\n  ]\n}' \
  --output-document \
  - 'https://api.print.io/api/updateOrder/520718/ShippingMethod?recipeid=00000000-0000-0000-0000-000000000000&partnerBillingKey=oeO2j1ZbfU0TaDPRrhStEyp68ZRbXK8UfWfq7BKICGY%3D'