Existing customer? Sign In
Below is the JSON used to create the shipping label above. All the attributes within the data parameter are non-mandatory. Supply only what you want to populate on the document.
    
        {
    "template": "shipping_label_4x6",
    "data": {
        "logo": "https://docamatic.s3.eu-west-1.amazonaws.com/assets/logo.png",
        "sender": {
            "name": "Acme",
            "address1": "787 Brunswick",
            "address2": "Los Angeles",
            "address3": "CA 50028",
            "telephone": "4444 555 555"
        },
        "recipient": {
            "name": "Casey Williams",
            "address1": "57 Parkway, 5th Floor",
            "address2": "New York",
            "address3": "NY 10013",
            "address4": "USA"
        },
        "order_number": "1893",
        "reference": "PO456461",
        "weight": "1.5KG",
        "instructions": "Please leave with reception",
        "barcode": "18935949030329293"
    }
}
    
        It's easy to change the look and feel of the shipping label. The template API allows you to easily insert your own logo and specify a custom font.
    
        {
    "template": "shipping_label_4x6",
    "font": "Open Sans",
    "font_size": 0.9,
    "font_color": "#32325d",
    "data" : {...}
}
    
        By default all templates are generated as a PDF document. If you would like to generate as a PNG or WEBP image, supply the file_type parameter in your API request:
    
        {
    "template": "shipping_label_4x6",
    "file_type": "png",
    "data" : {...}
}
    
        
        If you prefer to build your own templates or require more flexibility, be sure to try our HTML to PDF API . We are using the same HTML to PDF API to generate the shipping label above!
Back to templates