A food product label with the brand and origin, the product name and net weight, an organic badge, the ingredients, the allergen warning, a nutrition table, a barcode, the batch and best before date, and the producer details. The badge and the allergen line switch on and off with your data. Download the Word file to adapt it to your brand, then generate a label for every product.
Upload the label template, then send the structured data to get the finished document. Make sure to replace YOUR_API_KEY with your unique key and YOUR_TEMPLATE_ID with the ID of your template.
Send an array of JSON objects and get one document for each object, returned in a ZIP archive. Use the output_name parameter to customize each filename with the merge tags from your template.
curl -X 'POST' \
'https://api.docugenerate.com/v1/document' \
-H 'Accept: application/json' \
-H 'Authorization: YOUR_API_KEY' \
-H 'Content-Type: application/json' \
-d '{
"template_id": "YOUR_TEMPLATE_ID",
"output_format": ".pdf",
"data": {
"brand_name": "Hearth & Honey",
"origin": "Baked in Bristol, UK",
"product_name": "Oat and Almond Granola",
"product_subtitle": "Slow-baked with maple syrup",
"net_weight": "400 g",
"is_organic": true,
"ingredients": "Rolled oats (52%), almonds (14%), maple syrup (9%), sunflower seeds, coconut oil, pumpkin seeds, sea salt, cinnamon.",
"allergens": "tree nuts (almonds) and oats (gluten)",
"facts": [
{
"name": "Energy",
"value": "1,980 kJ / 473 kcal"
},
{
"name": "Fat",
"value": "21 g"
},
{
"name": "of which saturates",
"value": "3.1 g"
},
{
"name": "Carbohydrate",
"value": "56 g"
},
{
"name": "of which sugars",
"value": "12 g"
},
{
"name": "Fibre",
"value": "7 g"
},
{
"name": "Protein",
"value": "11 g"
},
{
"name": "Salt",
"value": "0.1 g"
}
],
"barcode_value": "5012345678900",
"batch": "L2610-B",
"best_before": "30 Apr 2027",
"producer_info": "Hearth & Honey Foods Ltd, Unit 4, Mill Lane, Bristol BS1 4XY 路 hello@hearthandhoney.example",
"has_allergens": true
}
}' curl -X 'POST' \
'https://api.docugenerate.com/v1/document' \
-H 'Accept: application/json' \
-H 'Authorization: YOUR_API_KEY' \
-H 'Content-Type: application/json' \
-d '{
"template_id": "YOUR_TEMPLATE_ID",
"output_format": ".pdf",
"single_file": false,
"output_name": "Product Label [product_name]",
"data": [
{ "brand_name": "Hearth & Honey", "origin": "Baked in Bristol, UK", "product_name": "Oat and Almond Granola", "product_subtitle": "Slow-baked with maple syrup", "net_weight": "400 g", "is_organic": true, "ingredients": "Rolled oats (52%), almonds (14%), maple syrup (9%), sunflower seeds, coconut oil, pumpkin seeds, sea salt, cinnamon.", "allergens": "tree nuts (almonds) and oats (gluten)", "facts": [{"name":"Energy","value":"1,980 kJ / 473 kcal"},{"name":"Fat","value":"21 g"},{"name":"of which saturates","value":"3.1 g"},{"name":"Carbohydrate","value":"56 g"},{"name":"of which sugars","value":"12 g"},{"name":"Fibre","value":"7 g"},{"name":"Protein","value":"11 g"},{"name":"Salt","value":"0.1 g"}], "barcode_value": "5012345678900", "batch": "L2610-B", "best_before": "30 Apr 2027", "producer_info": "Hearth & Honey Foods Ltd, Unit 4, Mill Lane, Bristol BS1 4XY 路 hello@hearthandhoney.example", "has_allergens": true },
{ "brand_name": "Hearth & Honey", "origin": "Baked in Bristol, UK", "product_name": "Honey and Hazelnut Muesli", "product_subtitle": "Stirred with wildflower honey", "net_weight": "500 g", "is_organic": true, "ingredients": "Rolled oats (48%), hazelnuts (15%), honey (8%), raisins, dried apple, sunflower seeds, flaked wheat, cinnamon.", "allergens": "tree nuts (hazelnuts), oats and wheat (gluten)", "facts": [{"name":"Energy","value":"1,640 kJ / 392 kcal"},{"name":"Fat","value":"14 g"},{"name":"of which saturates","value":"1.9 g"},{"name":"Carbohydrate","value":"54 g"},{"name":"of which sugars","value":"17 g"},{"name":"Fibre","value":"8 g"},{"name":"Protein","value":"10 g"},{"name":"Salt","value":"0.05 g"}], "barcode_value": "5012345678115", "batch": "L2610-C", "best_before": "31 May 2027", "producer_info": "Hearth & Honey Foods Ltd, Unit 4, Mill Lane, Bristol BS1 4XY 路 hello@hearthandhoney.example", "has_allergens": true },
{ "brand_name": "Hearth & Honey", "origin": "Baked in Bristol, UK", "product_name": "Dark Chocolate Granola", "product_subtitle": "Rich cocoa and dark chocolate chips", "net_weight": "375 g", "is_organic": false, "ingredients": "Rolled oats (44%), dark chocolate chips (16%), cocoa, almonds, coconut oil, maple syrup, sunflower seeds, vanilla, sea salt.", "allergens": "milk, soya, tree nuts (almonds) and oats (gluten)", "facts": [{"name":"Energy","value":"2,060 kJ / 493 kcal"},{"name":"Fat","value":"25 g"},{"name":"of which saturates","value":"8.4 g"},{"name":"Carbohydrate","value":"55 g"},{"name":"of which sugars","value":"19 g"},{"name":"Fibre","value":"8 g"},{"name":"Protein","value":"9 g"},{"name":"Salt","value":"0.2 g"}], "barcode_value": "5012345678122", "batch": "L2610-D", "best_before": "15 May 2027", "producer_info": "Hearth & Honey Foods Ltd, Unit 4, Mill Lane, Bristol BS1 4XY 路 hello@hearthandhoney.example", "has_allergens": true },
{ "brand_name": "Hearth & Honey", "origin": "Baked in Bristol, UK", "product_name": "Seeded Oat Crackers", "product_subtitle": "Crisp and savory, baked with seeds", "net_weight": "180 g", "is_organic": true, "ingredients": "Oat flour (58%), sunflower seeds, sesame seeds, linseed, rapeseed oil, sea salt, rosemary.", "allergens": "oats (gluten) and sesame", "facts": [{"name":"Energy","value":"1,890 kJ / 450 kcal"},{"name":"Fat","value":"21 g"},{"name":"of which saturates","value":"2.4 g"},{"name":"Carbohydrate","value":"50 g"},{"name":"of which sugars","value":"1.8 g"},{"name":"Fibre","value":"9 g"},{"name":"Protein","value":"13 g"},{"name":"Salt","value":"1.1 g"}], "barcode_value": "5012345678139", "batch": "L2611-A", "best_before": "30 Jun 2027", "producer_info": "Hearth & Honey Foods Ltd, Unit 4, Mill Lane, Bristol BS1 4XY 路 hello@hearthandhoney.example", "has_allergens": true },
{ "brand_name": "Hearth & Honey", "origin": "Baked in Bristol, UK", "product_name": "Apple and Cinnamon Porridge", "product_subtitle": "Just add hot water or milk", "net_weight": "320 g", "is_organic": true, "ingredients": "Rolled oats (72%), dried apple (14%), cinnamon, ground flaxseed, sea salt.", "allergens": "oats (gluten)", "facts": [{"name":"Energy","value":"1,520 kJ / 360 kcal"},{"name":"Fat","value":"6.5 g"},{"name":"of which saturates","value":"1.1 g"},{"name":"Carbohydrate","value":"62 g"},{"name":"of which sugars","value":"11 g"},{"name":"Fibre","value":"9 g"},{"name":"Protein","value":"10 g"},{"name":"Salt","value":"0.1 g"}], "barcode_value": "5012345678146", "batch": "L2611-B", "best_before": "28 Feb 2027", "producer_info": "Hearth & Honey Foods Ltd, Unit 4, Mill Lane, Bristol BS1 4XY 路 hello@hearthandhoney.example", "has_allergens": true },
{ "brand_name": "Hearth & Honey", "origin": "Baked in Bristol, UK", "product_name": "Super Seed Mix", "product_subtitle": "Sunflower, pumpkin and chia", "net_weight": "250 g", "is_organic": true, "ingredients": "Sunflower seeds (40%), pumpkin seeds (35%), golden linseed (15%), chia seeds (10%).", "allergens": "", "facts": [{"name":"Energy","value":"2,420 kJ / 584 kcal"},{"name":"Fat","value":"46 g"},{"name":"of which saturates","value":"5.9 g"},{"name":"Carbohydrate","value":"8 g"},{"name":"of which sugars","value":"1.6 g"},{"name":"Fibre","value":"14 g"},{"name":"Protein","value":"25 g"},{"name":"Salt","value":"0.02 g"}], "barcode_value": "5012345678153", "batch": "L2611-C", "best_before": "31 Aug 2027", "producer_info": "Hearth & Honey Foods Ltd, Unit 4, Mill Lane, Bristol BS1 4XY 路 hello@hearthandhoney.example", "has_allergens": false },
{ "brand_name": "Hearth & Honey", "origin": "Baked in Bristol, UK", "product_name": "Maple Pecan Clusters", "product_subtitle": "Crunchy clusters with toasted pecans", "net_weight": "350 g", "is_organic": false, "ingredients": "Rolled oats (46%), pecans (16%), maple syrup (11%), brown rice syrup, coconut oil, flaxseed, vanilla, sea salt.", "allergens": "tree nuts (pecans) and oats (gluten)", "facts": [{"name":"Energy","value":"2,010 kJ / 481 kcal"},{"name":"Fat","value":"23 g"},{"name":"of which saturates","value":"4.6 g"},{"name":"Carbohydrate","value":"55 g"},{"name":"of which sugars","value":"15 g"},{"name":"Fibre","value":"7 g"},{"name":"Protein","value":"9 g"},{"name":"Salt","value":"0.1 g"}], "barcode_value": "5012345678160", "batch": "L2611-D", "best_before": "30 Apr 2027", "producer_info": "Hearth & Honey Foods Ltd, Unit 4, Mill Lane, Bristol BS1 4XY 路 hello@hearthandhoney.example", "has_allergens": true },
{ "brand_name": "Hearth & Honey", "origin": "Baked in Bristol, UK", "product_name": "Coconut and Cashew Bars", "product_subtitle": "Chewy snack bars, 6 pack", "net_weight": "6 x 40 g", "is_organic": false, "ingredients": "Dates (34%), cashews (22%), desiccated coconut (16%), oats, rice syrup, sunflower oil, sea salt.", "allergens": "tree nuts (cashews) and oats (gluten)", "facts": [{"name":"Energy","value":"1,790 kJ / 428 kcal"},{"name":"Fat","value":"20 g"},{"name":"of which saturates","value":"8.9 g"},{"name":"Carbohydrate","value":"50 g"},{"name":"of which sugars","value":"28 g"},{"name":"Fibre","value":"6 g"},{"name":"Protein","value":"8 g"},{"name":"Salt","value":"0.15 g"}], "barcode_value": "5012345678177", "batch": "L2612-A", "best_before": "31 May 2027", "producer_info": "Hearth & Honey Foods Ltd, Unit 4, Mill Lane, Bristol BS1 4XY 路 hello@hearthandhoney.example", "has_allergens": true },
{ "brand_name": "Hearth & Honey", "origin": "Baked in Bristol, UK", "product_name": "Berry Breakfast Crunch", "product_subtitle": "Crunchy oats with freeze-dried berries", "net_weight": "400 g", "is_organic": true, "ingredients": "Rolled oats (55%), freeze-dried strawberries and raspberries (6%), honey, sunflower oil, coconut chips, vanilla.", "allergens": "oats (gluten)", "facts": [{"name":"Energy","value":"1,820 kJ / 433 kcal"},{"name":"Fat","value":"15 g"},{"name":"of which saturates","value":"4.2 g"},{"name":"Carbohydrate","value":"62 g"},{"name":"of which sugars","value":"16 g"},{"name":"Fibre","value":"7 g"},{"name":"Protein","value":"9 g"},{"name":"Salt","value":"0.08 g"}], "barcode_value": "5012345678184", "batch": "L2612-B", "best_before": "31 Jul 2027", "producer_info": "Hearth & Honey Foods Ltd, Unit 4, Mill Lane, Bristol BS1 4XY 路 hello@hearthandhoney.example", "has_allergens": true },
{ "brand_name": "Hearth & Honey", "origin": "Baked in Bristol, UK", "product_name": "Plain Porridge Oats", "product_subtitle": "Wholegrain, nothing added", "net_weight": "1 kg", "is_organic": true, "ingredients": "Wholegrain rolled oats (100%).", "allergens": "oats (gluten)", "facts": [{"name":"Energy","value":"1,550 kJ / 370 kcal"},{"name":"Fat","value":"7.5 g"},{"name":"of which saturates","value":"1.3 g"},{"name":"Carbohydrate","value":"60 g"},{"name":"of which sugars","value":"1.1 g"},{"name":"Fibre","value":"10 g"},{"name":"Protein","value":"12 g"},{"name":"Salt","value":"<0.01 g"}], "barcode_value": "5012345678191", "batch": "L2612-C", "best_before": "30 Sep 2027", "producer_info": "Hearth & Honey Foods Ltd, Unit 4, Mill Lane, Bristol BS1 4XY 路 hello@hearthandhoney.example", "has_allergens": true }
]
}' Questions frequently asked about our label templates
Get started with 20 free documents per month and our ready-to-use label templates.