Download OpenAPI specification:
API for creating, updating, and performing LCA calculations on products.
Creates the product if no product exists with this id (201), and updates it otherwise (200). An unknown id therefore never returns 404. While a calculation for the latest version is queued or running, a PUT gets a 409; send it again once the job has finished.
| id required | string^(?!\.{1,2}$)[A-Za-z0-9._~-]{1,128}$ Unique product identifier provided by the API user: 1 to 128 characters, each a letter, a digit, or one of |
Preferred values for certain fields
Fields tagged with ✳️ have preferred values that are optional but will help improve the speed and accuracy of the LCA calculation.
If not provided, the API will attempt to normalize values to a preferred value during LCA calculation.
Lists are full replacements
Every list in this payload replaces the product's existing list in full; items are never merged or matched between calls. For that reason packaging and manufacturing are always required, together with exactly one of ingredients or trade_names. Send an empty list ([]) to state that the product has none of an item. A missing list, or a list sent as null, is rejected.
Transport
The product, every trade name, every ingredient listed directly on the product, and every packaging element carry transport information. Ingredients and packaging use supply transport: from the supplier's location to your manufacturing facility. The product uses distribution transport: from your manufacturing facility to the market where the product is sold. Each must give at least one distance, or enough geography to calculate one. When any distance is given, only the distances given are used.
| product_name required | string Name of the product. |
| product_brand | string Brand of the product. |
| product_line | string Product line or series. |
| volume_ml required | number Size of the product in millilitres. Send either this or |
| weight_g | number Size of the product in grams; this is its mass. Send either this or |
| net_weight_g | number Net weight as printed on the pack, in grams: the product's mass. Only with |
| product_category required | string Main category of the product. For now it must match a Fairglow category exactly; a category that does not match gets a |
| product_subcategory | string Subcategory of the product. ✳️ |
object Your own reference fields for this product, as key-value pairs of strings (e.g., an internal SKU or formula code). Stored with the product and shown in Fairglow. | |
required | object or object or object or object or object (DistributionTransport) Transport of the finished product from your manufacturing facility to the market where it is sold. Give at least one distance, or both geographies. When any distance is given, only the distances given are used, and geographies are not used to fill in the rest. |
| packaging_reuse_count | number If the product is reusable, the number of times the packaging can be reused. |
Array of objects or objects (Ingredient) List of ingredient objects, for products whose ingredients are not grouped into trade names. Provide exactly one of | |
Array of objects or objects (TradeName) List of trade name objects. Provide exactly one of | |
required | Array of objects (PackagingElement) List of packaging element objects. Required; replaces the product's full packaging list on every call. Send |
required | Array of objects or objects (ManufacturingActivity) List of manufacturing activity objects. Required; replaces the product's full manufacturing list on every call. An empty list ( |
{- "product_name": "Nourishing Shampoo 250 ml",
- "product_brand": "Maison Verdure",
- "product_line": "Botanical Care",
- "volume_ml": 250,
- "net_weight_g": 259,
- "product_category": "Hair",
- "product_subcategory": "Shampoo",
- "custom_fields": {
- "sap_material_number": "100245",
- "formula_code": "F-2291"
}, - "transport_info": {
- "origin_geography": "France",
- "destination_geography": "Germany"
}, - "ingredients": [
- {
- "inci_name": "Aqua",
- "cas_number": "7732-18-5",
- "concentration": 0.78,
- "transport_info": {
- "origin_geography": "France"
}
}, - {
- "inci_name": "Sodium Laureth Sulfate",
- "cas_number": "68585-34-2",
- "concentration": 0.12,
- "supplier_id": "SUP-0031",
- "supplier_name": "Surfactants Europe SA",
- "transport_info": {
- "origin_geography": "Germany",
- "transport_truck_km": 820
}
}, - {
- "inci_name": "Cocamidopropyl Betaine",
- "cas_number": "61789-40-0",
- "concentration": 0.06,
- "supplier_id": "SUP-0031",
- "supplier_name": "Surfactants Europe SA",
- "transport_info": {
- "origin_geography": "Germany",
- "transport_truck_km": 820
}
}, - {
- "inci_name": "Glycerin",
- "cas_number": "56-81-5",
- "concentration": 0.03,
- "supplier_id": "SUP-0107",
- "supplier_name": "Oleo Ingredients BV",
- "transport_info": {
- "transport_boat_km": 11600,
- "transport_truck_km": 450
}
}, - {
- "inci_name": "Sodium Chloride",
- "cas_number": "7647-14-5",
- "concentration": 0.01,
- "transport_info": {
- "origin_geography": "France"
}
}
], - "packaging": [
- {
- "packaging_tier": "PRIMARY",
- "packaging_element_category": "CONTAINER",
- "packaging_element_type": "Bottle",
- "packaging_element_name": "250 ml round bottle",
- "supplier_article_code": "BTL-250-R",
- "packaging_material": "HDPE",
- "packaging_processes": [
- {
- "process_name": "Extrusion blow moulding",
- "activity_rate": 1
}
], - "scrap_rate": 0.03,
- "recycle_rate": 0.3,
- "mass_g": 22.5,
- "supplier_name": "Plastipak France",
- "transport_info": {
- "origin_geography": "France",
- "transport_truck_km": 310
}
}, - {
- "packaging_tier": "PRIMARY",
- "packaging_element_category": "CLOSURE",
- "packaging_element_type": "Flip-top cap",
- "packaging_material": "PP",
- "packaging_processes": [
- {
- "process_name": "Injection moulding",
- "activity_rate": 1
}
], - "mass_g": 4.1,
- "transport_info": {
- "origin_geography": "Italy"
}
}, - {
- "packaging_tier": "SECONDARY",
- "packaging_element_category": "BOX",
- "packaging_element_type": "Shipping case (12 units)",
- "packaging_material": "Corrugated board",
- "packaging_processes": [ ],
- "mass_g": 15,
- "transport_info": {
- "origin_geography": "France",
- "transport_truck_km": 120
}
}
], - "manufacturing": [
- {
- "activity_category": "ELECTRICITY",
- "activity_name": "Electricity, medium voltage",
- "activity_rate": 0.12,
- "geography": "France"
}, - {
- "activity_category": "WATER",
- "activity_name": "Tap water",
- "activity_rate": 1.5,
- "geography": "France",
- "loss_rate": 0.02
}, - {
- "activity_category": "HEAT",
- "activity_name": "Heat, natural gas",
- "activity_rate": 0.35,
- "geography": "France"
}
]
}{- "message": "Product updated successfully.",
- "product_id": "SKU-10245"
}| id required | string^(?!\.{1,2}$)[A-Za-z0-9._~-]{1,128}$ Unique product identifier provided by the API user: 1 to 128 characters, each a letter, a digit, or one of |
{- "job_id": "7f3c2a9e-4b1d-4e8a-9c6f-2d5b8e1a0c34",
}| job_id required | string <uuid> Unique identifier for the job, a UUID. Any other identifier gets a |
{- "job_id": "7f3c2a9e-4b1d-4e8a-9c6f-2d5b8e1a0c34",
- "status": "COMPLETED",
- "results": {
- "total_impact": {
- "climate_change": 0.412,
- "climate_change__fossil": 0.371,
- "climate_change__biogenic": 0.012,
- "climate_change__land_use": 0.029,
- "land_use": 18.6,
- "water_use": 0.184,
- "ozone_depletion": 3.1e-8,
- "acidification": 0.0017,
- "eutrophication_marine": 0.00041,
- "eutrophication_freshwater": 0.000052,
- "eutrophication_terrestrial": 0.0049,
- "ecotoxicity_freshwater": 2.87,
- "human_toxicity_carcinogenic": 1.9e-10,
- "human_toxicity_non_carcinogenic": 4.4e-9,
- "particulate_matter": 2.6e-8,
- "ionising_radiation": 0.041,
- "photochemical_oxidant_formation": 0.0012,
- "energy_resources_non_renewable": 6.1,
- "material_resources": 0.0000023,
- "single_score": 0.0000512
}
}
}