Shipment Confirm By Ddt Num

Just as shipmentConfirm, this enpoint confirms the shipments without using its ID (a Gsped internal reference) but, instead, using the numeric reference given at the time of shipping.

IMPORTANTE - PLEASE NOTE : ****The numeric reference must be unique (there must not ne a shipment with the same reference)

Confirm the shipment using the numeric reference

POST https://api.gsped.it/[INSTANCE]/ShipmentConfirmByDdtdum

Headers

NameTypeDescription

Content-Type*

String

application/json

x-api-key*

String

Api Key fornita da Gsped - Apikey given by Gsped

ddt_num

Array Integet

Numeric references of the shipments to confirm

{
    "status": "1 spedizioni confermate, 0 errori",
    "errors": []
}

** Example Snippets:**

<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => 'https://api.gsped.it/sandbox/ShipmentConfirmByDdtnum',
  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 =>'{
  "ddt_num": [
      "123",
      "124"
  ]
}',
  CURLOPT_HTTPHEADER => array(
    'Content-Type: application/json',
    'x-api-key: YOUR-API-KEY'
  ),
));

$response = curl_exec($curl);

curl_close($curl);
echo $response;

Last updated