Shipments

Attributes

Name Type Required Description
id string generated Unique reference
carrier_service string optional Linked to resource Carrier service
sender_id string optional Linked to resource Senders
order_reference string optional Reference of the order
recipient.company_name string optional Company name of recipient
recipient.first_name string required First name of recipient
recipient.last_name string required Last name of recipient
recipient.street string required Street name of recipient
recipient.house_number string required House number of recipient
recipient.house_number_extension string optional House number extension of recipient
recipient.address_line_2 string optional Optional second address line of recipient
recipient.zipcode string required Zipcode of recipient
recipient.city string required City of recipient
recipient.state string optional State of recipient
recipient.country string required Country of recipient (needs to be ISO 3166 2-char code)
recipient.email string optional E-mail address  of recipient
recipient.phone string optional Phone number  of recipient
print boolean optional If true Pakketpartner will print the generated label

Get all shipments

GEThttps://dashboard.pakketpartner.nl/api/v1/shipments
response

HTTP/1.1 200 OK
{
    "count": 1,
    "data": [
        {
            "id": "ship_cFjQjbjb454bAF",
            "carrier_service": cs_cfdgFdin54bAF,
            "tracking_code": "JVGL123456789",
            "tracking_url": "https://dhlparcel.nl/nl/particulier/ontvangen/volg-uw-zending?tt=JVGL123456789&pc=6941AH",
            "order_reference": null,
            "recipient": {
                "company_name": "eConcepts",
                "first_name": "Jan",
                "last_name": "Jansen",
                "street": "Kerkstraat",
                "house_number": "42",
                "house_number_extension": null,
                "address_line_2": null,
                "zipcode": "6941AH",
                "city": "Didam",
                "state": null,
                "country": "NL",
                "email": null,
                "phone": "0123456789"
            },
            "label_url_pdf": "https://dashboard.pakketpartner.nl/storage/labels/dhl/cFjQjbjb454bAFcFjQjbjb454bAF.pdf",
            "label_url_png": "https://dashboard.pakketpartner.nl/storage/labels/dhl/cFjQjbjb454bAFcFjQjbjb454bAF.png",
            "label_url_zpl": "https://dashboard.pakketpartner.nl/storage/labels/dhl/cFjQjbjb454bAFcFjQjbjb454bAF.zpl",
            "created_at": "2018-02-16 09:28:13"
        }
    ]
}

Get single shipment

GEThttps://dashboard.pakketpartner.nl/api/v1/shipments/{shipment_id}
response

HTTP/1.1 200 OK
{
    "data": {
        "id": "ship_cFjQjbjb454bAF",
        "carrier_service": cs_cfdgFdin54bAF,
        "tracking_code": "JVGL123456789",
        "tracking_url": "https://dhlparcel.nl/nl/particulier/ontvangen/volg-uw-zending?tt=JVGL123456789&pc=1000AB",
        "order_reference": null,
        "recipient": {
            "company_name": "eConcepts",
            "first_name": "Jan",
            "last_name": "Jansen",
            "street": "Kerkstraat",
            "house_number": "42",
            "house_number_extension": null,
            "address_line_2": null,
            "zipcode": "6941AH",
            "city": "Didam",
            "state": null,
            "country": "NL",
            "email": null,
            "phone": "0123456789"
        },
        "label_url_pdf": "https://dashboard.pakketpartner.nl/storage/labels/dhl/cFjQjbjb454bAFcFjQjbjb454bAF.pdf",
        "label_url_png": "https://dashboard.pakketpartner.nl/storage/labels/dhl/cFjQjbjb454bAFcFjQjbjb454bAF.png",
        "label_url_zpl": "https://dashboard.pakketpartner.nl/storage/labels/dhl/cFjQjbjb454bAFcFjQjbjb454bAF.zpl",
        "created_at": "2018-02-16 09:28:13"
    }
}

Create new shipment

POSThttps://dashboard.pakketpartner.nl/api/v1/shipments
request

HTTP/1.1 200 OK
{
    "order_reference": null,
    "packages": [
    	{
    		"weight" : 2500
    	},
    	{
    		"weight" : 2200
    	}
    ],
    "recipient": {
        "name": "Jan Jansen",
        "company_name": null,
        "address_line_1": "Kerkstraat 42",
        "address_line_2": null,
        "zipcode": "6941AH",
        "city": "Didam",
        "country": "NL",
        "phone": null,
        "email": "info@pakketpartner.nl"
    },
    "sender_hash" : "s_gdFN39Cnns3",
    "carrier_service" : "acsr_lprnwdSxzT4V6dps",
    "print": true
}
response

HTTP/1.1 200 OK
{
    "data": {
        "id": "ship_cFjQjbjb454bAF",
        "carrier_service": 37,
        "carrier": {
            "key": "dhl",
            "name": "DHL",
            "service": "DHL For you",
            "profile": null
        },
        "order_reference": "8ptF0m8U",
        "recipient": {
            "company_name": "",
            "first_name": "Jan",
            "last_name": "Jansen",
            "street": "Kerkstraat",
            "house_number": "42",
            "house_number_extension": "",
            "address_line_2": null,
            "zipcode": "6941AH",
            "city": "Didam",
            "state": null,
            "country": "NL",
            "email": "info@pakketpartner.nl",
            "phone": "0123456789"
        },
        "labels": [
            {
                "tracking_code": "JVGL123456788",
                "tracking_url": "https://dhlparcel.nl/nl/particulier/ontvangen/volg-uw-zending?tt=JVGL123456788&pc=6941AH",
                "label_url_pdf": "https://dashboard.pakketpartner.nl/storage/labels/dhl/cFjQjbjb454bAFcFjQjbjb454bAF.pdf",
                "label_url_png": "https://dashboard.pakketpartner.nl/storage/labels/dhl/cFjQjbjb454bAFcFjQjbjb454bAF.png",
                "label_url_zpl": "https://dashboard.pakketpartner.nl/storage/labels/dhl/cFjQjbjb454bAFcFjQjbjb454bAF.zpl"
            },
            {
                "tracking_code": "JVGL123456789",
                "tracking_url": "https://dhlparcel.nl/nl/particulier/ontvangen/volg-uw-zending?tt=JVGL123456789&pc=6941AH",
                "label_url_pdf": "https://dashboard.pakketpartner.nl/storage/labels/dhl/fvsm7uWweb25EAFRyd48e8AEgka.pdf",
                "label_url_png": "https://dashboard.pakketpartner.nl/storage/labels/dhl/fvsm7uWweb25EAFRyd48e8AEgka.png",
                "label_url_zpl": "https://dashboard.pakketpartner.nl/storage/labels/dhl/fvsm7uWweb25EAFRyd48e8AEgka.zpl"
            }
        ],
        "created_at": "2018-05-09 10:50:12"
    }
}

Get shipment labels on A4

PDF of shipment label(s) on A4. Maximum of four labels per page. The PDF document will be send directly with an Content-Type: application/pdf header as response.

GEThttps://dashboard.pakketpartner.nl/api/v1/shipments/labels?shipments[]={shipment_id}&shipments[]={shipment_id}