Shipments
Upload a batch of shipments
POST to /v1/shipments/batchesSubmit a batch of shipments for emission reporting.Only rudimentary checks (e.g. payload structure and size) are performed at upload time. The request either succeeds as a whole or it does not; there are no per-row errors on upload. Detailed per-row validation happens asynchronously when the batch is processed.The counterparty on each resulting shipment is resolved from one of two sources:- If
contact_idis supplied on the request, the identified contact is the counterparty for every resulting shipment. Per-rowtarget_internal_idandtarget_internal_nameare ignored for counterparty resolution in this case. - Otherwise, each row's counterparty is resolved from its per-row
target_internal_id, scoped to the authenticated account.target_internal_nameis used when the system has to create a previously-unseen counterparty mapping.
contact_id on the request and target_internal_id on a row is not an error; contact_id wins. Rows without a usable counterparty when contact_id is absent will fail during asynchronous processing.The shipper_id and supplier_id on each resulting shipment are derived from the authenticated account and the resolved counterparty: a shipper account is assigned as shipper_id, otherwise it is assigned as supplier_id, and the counterparty takes the opposite role.Returns a batch identifier that can be used to refer to the batch later.Request body
shipmentsarrayrequired
object
shipment_idstring
Client-side shipment reference identifier.
target_internal_idstring
An identifier you've assigned to this row's counterparty,
scoped to the account making the request. A contact may have
multiple Internal IDs and this row matches against any of them;
these are managed via the Lune dashboard. Used to resolve the
counterparty when the batch does not provide a batch-level
contact_id; ignored otherwise. Should be supplied together
with target_internal_name.
target_internal_namestring
Display name for the counterparty associated with
target_internal_id. Used when no contact yet has the supplied
target_internal_id and one needs to be created. Ignored when
the batch provides a contact_id.
metadataobject
An arbitrary dictionary (key-value pairs) to store application-specific information.
Lune doesn't use this information for order processing. Its purpose is for the API clients to be able to attach arbitrary information (to an order for example) and then retrieve it.
service_levelstring
Service level for the shipment.
expresseconomypriorityincotermstring
International Commercial Term (Incoterms 2020) governing the shipment.
exwfcacptcipdapcontract_typestring
Type of freight contract.
spotcontracttenderhazardous_cargoboolean
Whether the shipment contains hazardous cargo.
booking_referencestring
Booking reference number.
house_waybillstring
House waybill number.
reference_id_postring
Purchase order reference identifier.
consignee_idstring
Client-side identifier for the consignee.
consignee_namestring
Name of the consignee.
consignor_idstring
Client-side identifier for the consignor.
consignor_namestring
Name of the consignor.
freight_paying_partystring
Name of the freight paying party.
legal_entitystring
Legal entity responsible for the shipment.
freight_costobject
valuestringrequired
Pattern: ^[0-9]+(\.[0-9]+)?$
Specify the monetary value in the currency defined by the currency_code property in the request. If no currency_code is provided, the currency will default to that of the associated account.
currencystringrequired
ISO 4217 3 character currency code.
Note: Lune supports most but not all currency codes.
AEDAFNALLAMDANGshipper_contract_emission_scopestring
Emission scope for the shipper contract.
emissionsobject
Client-provided emissions data for the whole shipment. All emission values are in kilograms. The emissions source is automatically set to "manual" when this object is provided.
total_emissionsstringrequired
Pattern: ^[0-9]+(\.[0-9]+)?$
Total emissions (kg CO2e).
wttstringnullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Well-to-tank emissions (kg CO2e).
ttwstringnullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Tank-to-wheel emissions (kg CO2e).
distance_kmstringrequired
Pattern: ^[0-9]+(\.[0-9]+)?$
Total distance in kilometres.
legsarrayrequired
object
A single leg of a shipment journey.
leg_idstring
Client-side identifier for this leg.
orderinteger
1-based ordering of this leg within the shipment. If omitted, the array order is used.
methodoneOfrequired
Transport method accepted when creating a shipment.
carriagestringrequired
Indicates the leg's role in the overall shipment journey.
pre— first-mile pickupmain— primary long-haulon— last-mile delivery
premainonoriginoneOf
A location specified as one of: an address, geographic coordinates, a UN/LOCODE, or an airport code.
destinationoneOf
A location specified as one of: an address, geographic coordinates, a UN/LOCODE, or an airport code.
distanceobject
amountstringrequired
Pattern: ^[0-9]+(\.[0-9]+)?$
unitstringrequired
The estimated distance. Unit, km for kilometers, mi for miles
kmminmcarrier_namestring
Name of the carrier for this leg.
scac_codestring
Standard Carrier Alpha Code.
master_waybillstring
Master waybill number.
transit_corridorstring
The transit corridor used for sea shipments. This is used to improve the accuracy of the estimate. If not provided, the shortest route is calculated.
Only applicable to sea shipments.
panamasuezcape_of_good_hopenorthwest_passagenortheast_passagerestricted_transit_corridorsarray
Transit corridors that should be avoided for sea legs. Only applicable to sea legs. Mutually exclusive with transit_corridor.
string
The transit corridor used for sea shipments. This is used to improve the accuracy of the estimate. If not provided, the shortest route is calculated.
Only applicable to sea shipments.
panamasuezcape_of_good_hopenorthwest_passagenortheast_passageloadobject
Cargo load details for a shipment leg.
massobject
amountstringrequired
Pattern: ^[0-9]+(\.[0-9]+)?$
unitstringrequired
Unit, t for tonne, kg for kilogram, g for gram, lbs for pound
gkgtlbsvolumeobject
A volume measurement.
amountstringrequired
Pattern: ^[0-9]+(\.[0-9]+)?$
unitstringrequired
Unit of volume measurement.
lm3piece_countinteger
Number of pieces in the load.
chargeable_massobject
amountstringrequired
Pattern: ^[0-9]+(\.[0-9]+)?$
unitstringrequired
Unit, t for tonne, kg for kilogram, g for gram, lbs for pound
gkgtlbscontainersobject
Details of a shipping container.
typestring
ISO container size/type code.
20gp40gp40hc45hc20rfteustring
Pattern: ^[0-9]+(\.[0-9]+)?$
TEU equivalent of the container.
load_typestring
Whether the container is a full container load or less than container load.
fcllclload_factorstringnullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Measure of how fully the vehicle is utilising its cargo capacity (0 to 1).
empty_run_factorstringnullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Proportion of the vehicle's travel that is done empty (0 to 1).
passenger_utilisationstringnullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Passenger utilisation factor for passenger transport modes (0 to 1).
datesobject
Departure and arrival dates for a shipment leg.
etdoneOf
A date (YYYY-MM-DD) or date-time (RFC 3339).
etaoneOf
A date (YYYY-MM-DD) or date-time (RFC 3339).
atdoneOf
A date (YYYY-MM-DD) or date-time (RFC 3339).
ataoneOf
A date (YYYY-MM-DD) or date-time (RFC 3339).
emissionsobject
Client-provided emissions data for a shipment leg. All emission values are in kilograms.
total_emissionsstringrequired
Pattern: ^[0-9]+(\.[0-9]+)?$
Total emissions (kg CO2e).
wttstring
Pattern: ^[0-9]+(\.[0-9]+)?$
Well-to-tank emissions (kg CO2e).
ttwstring
Pattern: ^[0-9]+(\.[0-9]+)?$
Tank-to-wheel emissions (kg CO2e).
intensitystringnullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Emission intensity.
particles_totalstringnullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Total particulate matter emissions (kg).
particles_wttstringnullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Well-to-tank particulate matter emissions (kg).
particles_ttwstringnullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Tank-to-wheel particulate matter emissions (kg).
carbon_dioxide_totalstringnullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Total carbon dioxide emissions (kg).
carbon_dioxide_wttstringnullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Well-to-tank carbon dioxide emissions (kg).
carbon_dioxide_ttwstringnullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Tank-to-wheel carbon dioxide emissions (kg).
nitrogen_oxides_totalstringnullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Total nitrogen oxides emissions (kg).
nitrogen_oxides_wttstringnullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Well-to-tank nitrogen oxides emissions (kg).
nitrogen_oxides_ttwstringnullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Tank-to-wheel nitrogen oxides emissions (kg).
sulfur_dioxides_totalstringnullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Total sulfur dioxides emissions (kg).
sulfur_dioxides_wttstringnullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Well-to-tank sulfur dioxides emissions (kg).
sulfur_dioxides_ttwstringnullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Tank-to-wheel sulfur dioxides emissions (kg).
non_methane_hydro_carbons_totalstringnullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Total non-methane hydrocarbons emissions (kg).
non_methane_hydro_carbons_wttstringnullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Well-to-tank non-methane hydrocarbons emissions (kg).
non_methane_hydro_carbons_ttwstringnullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Tank-to-wheel non-methane hydrocarbons emissions (kg).
primary_energy_mjstringnullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Primary energy consumption (MJ).
fuel_consumption_lstringnullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Fuel consumption (litres).
distance_kmstringrequired
Pattern: ^[0-9]+(\.[0-9]+)?$
Distance (km).
transport_activitystringnullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Transport activity (tonne-kilometres).
emission_factor_descriptionstring
Description of the emission factor used.
emission_factor_regionstring
Region of the emission factor.
emission_factor_sourcestring
Source of the emission factor.
emission_factor_intensitystringnullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Intensity value of the emission factor.
emission_factor_numeratorstring
Numerator unit of the emission factor.
emission_factor_denominatorstring
Denominator unit of the emission factor.
emission_factor_yearinteger
Year of the emission factor.
contact_idstring
Lune contact identifier for the counterparty in this batch.
When supplied, every row in the batch uses the identified contact
as the counterparty and per-row target_internal_id /
target_internal_name are ignored for counterparty resolution.
When omitted, each row's counterparty is resolved from its
per-row target_internal_id instead.
idempotency_keystring
Idempotency key for this batch upload, unique per authenticated
account. Returns HTTP 409 Conflict with error code
shipment_batch_idempotency_already_exists if a batch with the
same idempotency key has already been submitted by this account.
calculate_emissionsboolean
Whether to schedule emission calculations immediately after this batch has been processed. Defaults to false.
Response
idstringrequired
Batch identifier.
Errors
This API operation can return the following errors:400api_version_invalid400bundle_selection_ratios_invalid400bundle_selection_bundle_invalid400order_value_invalid400bundle_id_invalid400id_invalid400distance_invalid400test_account_name_update_disallowed400bundle_selection_ratios_invalid_format400address_not_foundCalculate shipments
POST to /v1/shipments/calculateCreates one or more calculation batches for the shipments matching the given filters. Accepts the same filters as GET /shipments.Emissions calculation happens asynchronously: this only enqueues it. Returns the identifiers of the calculation batches created.The request is rejected if more than 200000 shipments are selected.For an organisation billed by credit, the request is rejected if its credit balance is below the number of matched shipments.Query parameters
searchstring
Free-text search term used to match shipment IDs in the returned results.
shipment_date_fromstring (date)
Include only shipments with a shipment date on or after this date.
shipment_date_tostring (date)
Include only shipments with a shipment date on or before this date.
main_carriage_motstring
Filter shipments by the main carriage mode of transport.
pre_carriage_motstring
Filter shipments by the pre-carriage mode of transport.
post_carriage_motstring
Filter shipments by the post-carriage mode of transport.
supplier_idstring
Filter shipments by supplier account IDs.
shipper_idstring
Filter shipments by shipper account IDs.
shipment_batch_idstring
Filter shipments by the IDs of the shipment batches they were created from.
data_sheet_idstring
Filter shipments by the IDs of the data sheet uploads their shipment batches were created from. Values are OR'd: a shipment matches if its batch came from any of the given data sheets.
idstring
Filter shipments to only the given IDs. This is the same
Lune-generated unique identifier already returned on each
shipment's id field, so it can be matched. Values are OR'd: a
shipment matches if its ID is any of the given values.
flaggedstring
Filter shipments by whether they contain legs with flagged emission intensity.
emissionsstring
Filter shipments by emissions availability.
allwith_co2ewithout_co2eResponse
calculation_batch_idsarrayrequired
Identifiers of the calculation batches created.
string
Errors
This API operation can return the following errors:400api_version_invalid400bundle_selection_ratios_invalid400bundle_selection_bundle_invalid400order_value_invalid400bundle_id_invalid400id_invalid400distance_invalid400test_account_name_update_disallowed400bundle_selection_ratios_invalid_format400address_not_foundGet a shipment batch
GET to /v1/shipments/batches/{id}Fetch the current processing state of a shipment batch. Row results and counts are included when row processing has run to completion.Query parameters
idstringrequired
Shipment batch identifier.
Response
oneOf
Errors
This API operation can return the following errors:401404429List shipment batches
GET to /v1/shipments/batchesReturns the account's paginated shipment batches in reverse order (most recent first).Each item uses the same summary shape. Counts and batch_error are null until processing finishes (or when a batch-level error prevents row-level processing). Per-row results are not included; use get shipment batch to fetch them for a single batch.Query parameters
limitstring
Pattern: ^\d+$
Maximum number of resources to return, between 1 and 100.
afterstring
A cursor for use in pagination.
The cursor that points to the starting item of the next page of results. If not provided, the first page of results is returned.
sourcestring
Filter batches by how they were created.
Response
has_morebooleanrequired
Whether or not there are more elements available after this set.
If false, this set comprises the end of the array.
Part of a paginated response.
next_cursorstringrequirednullable
The cursor value to be used as the after parameter for fetching the next page of results.
null if has_more is false.
dataarrayrequired
An array of shipment batch summaries ordered by creation date descending.
Part of a paginated response.
object
idstringrequired
Batch identifier.
statusstringrequired
Batch processing status.
pendingprocessingprocessedsourcestringrequired
Describes through which channel the batch was created.
api— submitted directly through the shipments APIdata_sheet— submitted as a data sheet through the Lune uploader
apidata_sheetaccount_namestringrequired
Name of the account that uploaded the batch.
user_namestringrequirednullable
Full name of the user that uploaded the linked data sheet, when available. Null for API uploads without a data sheet or when the uploader has no name.
filenamestringrequirednullable
Filename of the linked data sheet, when the batch was created from a sheet upload. Null for API uploads without a data sheet.
created_atstring (date-time)required
Timestamp when the batch was created.
success_countnumberrequirednullable
Number of rows that were processed successfully. Null while the batch is not finished, or when a batch-level error prevented row-level processing.
failed_countnumberrequirednullable
Number of rows that failed processing. Null while the batch is not finished, or when a batch-level error prevented row-level processing.
batch_errorstringrequirednullable
Batch-level processing error when row processing did not run. Null otherwise.
Errors
This API operation can return the following errors:401429List shipments
GET to /v1/shipmentsReturns the account's paginated shipments in reverse order (most recent first).Query parameters
limitstring
Pattern: ^\d+$
Maximum number of resources to return, between 1 and 100.
afterstring
A cursor for use in pagination.
The cursor that points to the starting item of the next page of results. If not provided, the first page of results is returned.
searchstring
Free-text search term used to match shipment IDs in the returned results.
shipment_date_fromstring (date)
Include only shipments with a shipment date on or after this date.
shipment_date_tostring (date)
Include only shipments with a shipment date on or before this date.
main_carriage_motstring
Filter shipments by the main carriage mode of transport.
pre_carriage_motstring
Filter shipments by the pre-carriage mode of transport.
post_carriage_motstring
Filter shipments by the post-carriage mode of transport.
supplier_idstring
Filter shipments by supplier account IDs.
shipper_idstring
Filter shipments by shipper account IDs.
shipment_batch_idstring
Filter shipments by the IDs of the shipment batches they were created from.
data_sheet_idstring
Filter shipments by the IDs of the data sheet uploads their shipment batches were created from. Values are OR'd: a shipment matches if its batch came from any of the given data sheets.
idstring
Filter shipments to only the given IDs. This is the same
Lune-generated unique identifier already returned on each
shipment's id field, so it can be matched. Values are OR'd: a
shipment matches if its ID is any of the given values.
flaggedstring
Filter shipments by whether they contain legs with flagged emission intensity.
emissionsstring
Filter shipments by emissions availability.
allwith_co2ewithout_co2einclude_totalsstring
Whether to include approximate shipment totals in the response.
Response
has_morebooleanrequired
Whether or not there are more elements available after this set.
If false, this set comprises the end of the array.
Part of a paginated response.
next_cursorstringrequirednullable
The cursor value to be used as the after parameter for fetching the next page of results.
null if has_more is false.
dataarrayrequired
An array of Shipment objects ordered by creation date descending.
Part of a paginated response.
object
A shipment with its legs, with or without emissions.
estimate_idstringrequirednullable
Unique identifier of the emission estimate associated with this shipment.
origin_street_line1stringrequirednullable
Origin street address line 1.
origin_street_line2stringrequirednullable
Origin street address line 2.
origin_postcodestringrequirednullable
Origin postcode.
origin_citystringrequirednullable
Origin city.
origin_country_codestringrequirednullable
Origin country code (ISO 3166-1 alpha-3).
origin_locodestringrequirednullable
Origin UN/LOCODE.
origin_codestringrequirednullable
Origin airport code.
origin_latitudestringrequirednullable
Pattern: ^-?[0-9]+(\.[0-9]+)?$
Origin latitude.
origin_longitudestringrequirednullable
Pattern: ^-?[0-9]+(\.[0-9]+)?$
Origin longitude.
destination_street_line1stringrequirednullable
Destination street address line 1.
destination_street_line2stringrequirednullable
Destination street address line 2.
destination_postcodestringrequirednullable
Destination postcode.
destination_citystringrequirednullable
Destination city.
destination_country_codestringrequirednullable
Destination country code (ISO 3166-1 alpha-3).
destination_locodestringrequirednullable
Destination UN/LOCODE.
destination_codestringrequirednullable
Destination airport code.
destination_latitudestringrequirednullable
Pattern: ^-?[0-9]+(\.[0-9]+)?$
Destination latitude.
destination_longitudestringrequirednullable
Pattern: ^-?[0-9]+(\.[0-9]+)?$
Destination longitude.
distance_kmstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Total distance in kilometres.
total_emissionsstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Total emissions (kg CO2e).
wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Well-to-tank emissions (kg CO2e).
ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Tank-to-wheel emissions (kg CO2e).
pre_carriage_totalstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
pre_carriage_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
pre_carriage_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
main_carriage_totalstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
main_carriage_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
main_carriage_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
on_carriage_totalstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
on_carriage_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
on_carriage_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
intensitystringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
pre_carriage_intensitystringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
main_carriage_intensitystringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
on_carriage_intensitystringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
intensity_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
intensity_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
intensity_pre_carriage_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
intensity_pre_carriage_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
intensity_main_carriage_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
intensity_main_carriage_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
intensity_on_carriage_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
intensity_on_carriage_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
particles_totalstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
particles_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
particles_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
particles_pre_carriage_totalstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
particles_pre_carriage_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
particles_pre_carriage_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
particles_main_carriage_totalstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
particles_main_carriage_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
particles_main_carriage_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
particles_on_carriage_totalstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
particles_on_carriage_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
particles_on_carriage_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
carbon_dioxide_totalstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
carbon_dioxide_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
carbon_dioxide_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
carbon_dioxide_pre_carriage_totalstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
carbon_dioxide_pre_carriage_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
carbon_dioxide_pre_carriage_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
carbon_dioxide_main_carriage_totalstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
carbon_dioxide_main_carriage_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
carbon_dioxide_main_carriage_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
carbon_dioxide_on_carriage_totalstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
carbon_dioxide_on_carriage_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
carbon_dioxide_on_carriage_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
nitrogen_oxides_totalstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
nitrogen_oxides_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
nitrogen_oxides_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
nitrogen_oxides_pre_carriage_totalstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
nitrogen_oxides_pre_carriage_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
nitrogen_oxides_pre_carriage_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
nitrogen_oxides_main_carriage_totalstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
nitrogen_oxides_main_carriage_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
nitrogen_oxides_main_carriage_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
nitrogen_oxides_on_carriage_totalstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
nitrogen_oxides_on_carriage_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
nitrogen_oxides_on_carriage_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
sulfur_dioxides_totalstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
sulfur_dioxides_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
sulfur_dioxides_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
sulfur_dioxides_pre_carriage_totalstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
sulfur_dioxides_pre_carriage_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
sulfur_dioxides_pre_carriage_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
sulfur_dioxides_main_carriage_totalstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
sulfur_dioxides_main_carriage_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
sulfur_dioxides_main_carriage_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
sulfur_dioxides_on_carriage_totalstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
sulfur_dioxides_on_carriage_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
sulfur_dioxides_on_carriage_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
non_methane_hydro_carbons_totalstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
non_methane_hydro_carbons_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
non_methane_hydro_carbons_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
non_methane_hydro_carbons_pre_carriage_totalstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
non_methane_hydro_carbons_pre_carriage_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
non_methane_hydro_carbons_pre_carriage_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
non_methane_hydro_carbons_main_carriage_totalstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
non_methane_hydro_carbons_main_carriage_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
non_methane_hydro_carbons_main_carriage_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
non_methane_hydro_carbons_on_carriage_totalstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
non_methane_hydro_carbons_on_carriage_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
non_methane_hydro_carbons_on_carriage_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
idstringrequired
Lune-generated unique identifier.
shipment_idstringrequired
Client-side shipment reference identifier.
supplier_idstringrequired
Identifier of the supplier.
supplier_namestringrequired
Name of the supplier.
shipper_idstringrequirednullable
Identifier of the shipper.
shipper_namestringrequirednullable
Name of the shipper.
metadataobjectrequirednullable
tagsarrayrequirednullable
Tags for categorising or filtering shipments.
string
service_levelstringrequirednullable
expresseconomypriorityincotermstringrequirednullable
exwfcacptcipdapcontract_typestringrequirednullable
spotcontracttenderhazardous_cargobooleanrequirednullable
Whether the shipment contains hazardous cargo.
booking_referencestringrequirednullable
Booking reference number.
house_waybillstringrequirednullable
House waybill number.
reference_id_postringrequirednullable
Purchase order reference identifier.
consignee_idstringrequirednullable
Client-side identifier for the consignee.
consignee_namestringrequirednullable
Name of the consignee.
consignor_idstringrequirednullable
Client-side identifier for the consignor.
consignor_namestringrequirednullable
Name of the consignor.
freight_paying_partystringrequirednullable
Name of the freight paying party.
legal_entitystringrequirednullable
Legal entity responsible for the shipment.
freight_costobjectrequirednullable
valuestringrequired
Pattern: ^[0-9]+(\.[0-9]+)?$
Specify the monetary value in the currency defined by the currency_code property in the request. If no currency_code is provided, the currency will default to that of the associated account.
currencystringrequired
ISO 4217 3 character currency code.
Note: Lune supports most but not all currency codes.
AEDAFNALLAMDANGshipper_contract_emission_scopestringrequirednullable
Emission scope for the shipper contract.
emissions_sourcestringrequirednullable
Source of the emissions data.
ecotransitlunemanuallegsarrayrequired
object
A shipment leg with its calculated emissions.
leg_idstringrequirednullable
Client-side identifier for this leg.
orderintegerrequirednullable
1-based ordering of this leg within the shipment.
methodoneOfrequired
carriagestringrequirednullable
premainonoriginoneOfrequired
destinationoneOfrequired
distanceobjectrequirednullable
amountstringrequired
Pattern: ^[0-9]+(\.[0-9]+)?$
unitstringrequired
The estimated distance. Unit, km for kilometers, mi for miles
kmminmcarrier_namestringrequirednullable
Name of the carrier for this leg.
scac_codestringrequirednullable
Standard Carrier Alpha Code.
master_waybillstringrequirednullable
Master waybill number.
transit_corridorstringrequirednullable
Transit corridor to force the route through for sea legs. Only applicable to sea legs.
panamasuezcape_of_good_hopenorthwest_passagenortheast_passagerestricted_transit_corridorsarrayrequirednullable
Transit corridors that should be avoided for sea legs. Only applicable to sea legs.
string
The transit corridor used for sea shipments. This is used to improve the accuracy of the estimate. If not provided, the shortest route is calculated.
Only applicable to sea shipments.
panamasuezcape_of_good_hopenorthwest_passagenortheast_passageloadobjectrequirednullable
massobjectrequirednullable
amountstringrequired
Pattern: ^[0-9]+(\.[0-9]+)?$
unitstringrequired
Unit, t for tonne, kg for kilogram, g for gram, lbs for pound
gkgtlbsvolumeobjectrequirednullable
amountstringrequired
Pattern: ^[0-9]+(\.[0-9]+)?$
unitstringrequired
Unit of volume measurement.
lm3piece_countintegerrequirednullable
Number of pieces in the load.
chargeable_massobjectrequirednullable
amountstringrequired
Pattern: ^[0-9]+(\.[0-9]+)?$
unitstringrequired
Unit, t for tonne, kg for kilogram, g for gram, lbs for pound
gkgtlbscontainersarrayrequirednullable
object
Details of a shipping container.
numberstringrequirednullable
Container number.
typestringrequirednullable
20gp40gp40hc45hc20rfteustringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
TEU equivalent of the container.
load_typestringrequirednullable
fcllclcargo_typestringrequirednullable
lightweightaverageheavyweightcontainer_onlyload_factorstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Measure of how fully the vehicle is utilising its cargo capacity (0 to 1).
empty_run_factorstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Proportion of the vehicle's travel that is done empty (0 to 1).
passenger_utilisationstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Passenger utilisation factor for passenger transport modes (0 to 1).
datesobjectrequirednullable
etdoneOfrequired
Estimated departure date or date-time.
etaoneOfrequired
Estimated arrival date or date-time.
atdoneOfrequired
Actual departure date or date-time.
ataoneOfrequired
Actual arrival date or date-time.
emissionsobjectrequirednullable
total_emissionsstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Total emissions (kg CO2e).
wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Well-to-tank emissions (kg CO2e).
ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Tank-to-wheel emissions (kg CO2e).
intensitystringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Emission intensity.
particles_totalstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Total particulate matter emissions (kg).
particles_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Well-to-tank particulate matter emissions (kg).
particles_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Tank-to-wheel particulate matter emissions (kg).
carbon_dioxide_totalstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Total carbon dioxide emissions (kg).
carbon_dioxide_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Well-to-tank carbon dioxide emissions (kg).
carbon_dioxide_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Tank-to-wheel carbon dioxide emissions (kg).
nitrogen_oxides_totalstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Total nitrogen oxides emissions (kg).
nitrogen_oxides_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Well-to-tank nitrogen oxides emissions (kg).
nitrogen_oxides_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Tank-to-wheel nitrogen oxides emissions (kg).
sulfur_dioxides_totalstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Total sulfur dioxides emissions (kg).
sulfur_dioxides_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Well-to-tank sulfur dioxides emissions (kg).
sulfur_dioxides_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Tank-to-wheel sulfur dioxides emissions (kg).
non_methane_hydro_carbons_totalstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Total non-methane hydrocarbons emissions (kg).
non_methane_hydro_carbons_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Well-to-tank non-methane hydrocarbons emissions (kg).
non_methane_hydro_carbons_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Tank-to-wheel non-methane hydrocarbons emissions (kg).
primary_energy_mjstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Primary energy consumption (MJ).
fuel_consumption_lstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Fuel consumption (litres).
distance_kmstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Distance (km).
transport_activitystringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Transport activity (tonne-kilometres).
emission_factor_descriptionstringrequirednullable
Description of the emission factor used.
emission_factor_regionstringrequirednullable
Region of the emission factor.
emission_factor_sourcestringrequirednullable
Source of the emission factor.
emission_factor_intensitystringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Intensity value of the emission factor.
emission_factor_numeratorstringrequirednullable
Numerator unit of the emission factor.
emission_factor_denominatorstringrequirednullable
Denominator unit of the emission factor.
emission_factor_yearintegerrequirednullable
Year of the emission factor.
created_atstring (date-time)required
An <a href="https://pretty-rfc.herokuapp.com/RFC3339">RFC 3339</a>-formatted timestamp.
totalobjectrequirednullable
Approximate total number of shipments matching the active filters.
These totals may lag behind the current shipment data.
allintegerrequired
with_co2eintegerrequired
without_co2eintegerrequired
Errors
This API operation can return the following errors:400api_version_invalid400bundle_selection_ratios_invalid400bundle_selection_bundle_invalid400order_value_invalid400bundle_id_invalid400id_invalid400distance_invalid400test_account_name_update_disallowed400bundle_selection_ratios_invalid_format400address_not_foundGet a shipment
GET to /v1/shipments/{id}Retrieve a shipment by its identifier, including calculated emissions when available.Query parameters
idstringrequired
The shipment's unique identifier.
Response
A shipment with its legs, with or without emissions.
estimate_idstringrequirednullable
Unique identifier of the emission estimate associated with this shipment.
origin_street_line1stringrequirednullable
Origin street address line 1.
origin_street_line2stringrequirednullable
Origin street address line 2.
origin_postcodestringrequirednullable
Origin postcode.
origin_citystringrequirednullable
Origin city.
origin_country_codestringrequirednullable
Origin country code (ISO 3166-1 alpha-3).
origin_locodestringrequirednullable
Origin UN/LOCODE.
origin_codestringrequirednullable
Origin airport code.
origin_latitudestringrequirednullable
Pattern: ^-?[0-9]+(\.[0-9]+)?$
Origin latitude.
origin_longitudestringrequirednullable
Pattern: ^-?[0-9]+(\.[0-9]+)?$
Origin longitude.
destination_street_line1stringrequirednullable
Destination street address line 1.
destination_street_line2stringrequirednullable
Destination street address line 2.
destination_postcodestringrequirednullable
Destination postcode.
destination_citystringrequirednullable
Destination city.
destination_country_codestringrequirednullable
Destination country code (ISO 3166-1 alpha-3).
destination_locodestringrequirednullable
Destination UN/LOCODE.
destination_codestringrequirednullable
Destination airport code.
destination_latitudestringrequirednullable
Pattern: ^-?[0-9]+(\.[0-9]+)?$
Destination latitude.
destination_longitudestringrequirednullable
Pattern: ^-?[0-9]+(\.[0-9]+)?$
Destination longitude.
distance_kmstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Total distance in kilometres.
total_emissionsstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Total emissions (kg CO2e).
wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Well-to-tank emissions (kg CO2e).
ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Tank-to-wheel emissions (kg CO2e).
pre_carriage_totalstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
pre_carriage_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
pre_carriage_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
main_carriage_totalstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
main_carriage_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
main_carriage_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
on_carriage_totalstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
on_carriage_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
on_carriage_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
intensitystringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
pre_carriage_intensitystringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
main_carriage_intensitystringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
on_carriage_intensitystringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
intensity_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
intensity_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
intensity_pre_carriage_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
intensity_pre_carriage_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
intensity_main_carriage_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
intensity_main_carriage_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
intensity_on_carriage_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
intensity_on_carriage_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
particles_totalstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
particles_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
particles_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
particles_pre_carriage_totalstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
particles_pre_carriage_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
particles_pre_carriage_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
particles_main_carriage_totalstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
particles_main_carriage_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
particles_main_carriage_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
particles_on_carriage_totalstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
particles_on_carriage_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
particles_on_carriage_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
carbon_dioxide_totalstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
carbon_dioxide_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
carbon_dioxide_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
carbon_dioxide_pre_carriage_totalstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
carbon_dioxide_pre_carriage_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
carbon_dioxide_pre_carriage_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
carbon_dioxide_main_carriage_totalstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
carbon_dioxide_main_carriage_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
carbon_dioxide_main_carriage_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
carbon_dioxide_on_carriage_totalstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
carbon_dioxide_on_carriage_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
carbon_dioxide_on_carriage_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
nitrogen_oxides_totalstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
nitrogen_oxides_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
nitrogen_oxides_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
nitrogen_oxides_pre_carriage_totalstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
nitrogen_oxides_pre_carriage_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
nitrogen_oxides_pre_carriage_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
nitrogen_oxides_main_carriage_totalstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
nitrogen_oxides_main_carriage_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
nitrogen_oxides_main_carriage_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
nitrogen_oxides_on_carriage_totalstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
nitrogen_oxides_on_carriage_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
nitrogen_oxides_on_carriage_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
sulfur_dioxides_totalstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
sulfur_dioxides_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
sulfur_dioxides_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
sulfur_dioxides_pre_carriage_totalstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
sulfur_dioxides_pre_carriage_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
sulfur_dioxides_pre_carriage_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
sulfur_dioxides_main_carriage_totalstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
sulfur_dioxides_main_carriage_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
sulfur_dioxides_main_carriage_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
sulfur_dioxides_on_carriage_totalstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
sulfur_dioxides_on_carriage_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
sulfur_dioxides_on_carriage_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
non_methane_hydro_carbons_totalstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
non_methane_hydro_carbons_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
non_methane_hydro_carbons_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
non_methane_hydro_carbons_pre_carriage_totalstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
non_methane_hydro_carbons_pre_carriage_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
non_methane_hydro_carbons_pre_carriage_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
non_methane_hydro_carbons_main_carriage_totalstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
non_methane_hydro_carbons_main_carriage_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
non_methane_hydro_carbons_main_carriage_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
non_methane_hydro_carbons_on_carriage_totalstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
non_methane_hydro_carbons_on_carriage_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
non_methane_hydro_carbons_on_carriage_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
idstringrequired
Lune-generated unique identifier.
shipment_idstringrequired
Client-side shipment reference identifier.
supplier_idstringrequired
Identifier of the supplier.
supplier_namestringrequired
Name of the supplier.
shipper_idstringrequirednullable
Identifier of the shipper.
shipper_namestringrequirednullable
Name of the shipper.
metadataobjectrequirednullable
tagsarrayrequirednullable
Tags for categorising or filtering shipments.
string
service_levelstringrequirednullable
expresseconomypriorityincotermstringrequirednullable
exwfcacptcipdapcontract_typestringrequirednullable
spotcontracttenderhazardous_cargobooleanrequirednullable
Whether the shipment contains hazardous cargo.
booking_referencestringrequirednullable
Booking reference number.
house_waybillstringrequirednullable
House waybill number.
reference_id_postringrequirednullable
Purchase order reference identifier.
consignee_idstringrequirednullable
Client-side identifier for the consignee.
consignee_namestringrequirednullable
Name of the consignee.
consignor_idstringrequirednullable
Client-side identifier for the consignor.
consignor_namestringrequirednullable
Name of the consignor.
freight_paying_partystringrequirednullable
Name of the freight paying party.
legal_entitystringrequirednullable
Legal entity responsible for the shipment.
freight_costobjectrequirednullable
valuestringrequired
Pattern: ^[0-9]+(\.[0-9]+)?$
Specify the monetary value in the currency defined by the currency_code property in the request. If no currency_code is provided, the currency will default to that of the associated account.
currencystringrequired
ISO 4217 3 character currency code.
Note: Lune supports most but not all currency codes.
AEDAFNALLAMDANGshipper_contract_emission_scopestringrequirednullable
Emission scope for the shipper contract.
emissions_sourcestringrequirednullable
Source of the emissions data.
ecotransitlunemanuallegsarrayrequired
object
A shipment leg with its calculated emissions.
leg_idstringrequirednullable
Client-side identifier for this leg.
orderintegerrequirednullable
1-based ordering of this leg within the shipment.
methodoneOfrequired
carriagestringrequirednullable
premainonoriginoneOfrequired
destinationoneOfrequired
distanceobjectrequirednullable
amountstringrequired
Pattern: ^[0-9]+(\.[0-9]+)?$
unitstringrequired
The estimated distance. Unit, km for kilometers, mi for miles
kmminmcarrier_namestringrequirednullable
Name of the carrier for this leg.
scac_codestringrequirednullable
Standard Carrier Alpha Code.
master_waybillstringrequirednullable
Master waybill number.
transit_corridorstringrequirednullable
Transit corridor to force the route through for sea legs. Only applicable to sea legs.
panamasuezcape_of_good_hopenorthwest_passagenortheast_passagerestricted_transit_corridorsarrayrequirednullable
Transit corridors that should be avoided for sea legs. Only applicable to sea legs.
string
The transit corridor used for sea shipments. This is used to improve the accuracy of the estimate. If not provided, the shortest route is calculated.
Only applicable to sea shipments.
panamasuezcape_of_good_hopenorthwest_passagenortheast_passageloadobjectrequirednullable
massobjectrequirednullable
amountstringrequired
Pattern: ^[0-9]+(\.[0-9]+)?$
unitstringrequired
Unit, t for tonne, kg for kilogram, g for gram, lbs for pound
gkgtlbsvolumeobjectrequirednullable
amountstringrequired
Pattern: ^[0-9]+(\.[0-9]+)?$
unitstringrequired
Unit of volume measurement.
lm3piece_countintegerrequirednullable
Number of pieces in the load.
chargeable_massobjectrequirednullable
amountstringrequired
Pattern: ^[0-9]+(\.[0-9]+)?$
unitstringrequired
Unit, t for tonne, kg for kilogram, g for gram, lbs for pound
gkgtlbscontainersarrayrequirednullable
object
Details of a shipping container.
numberstringrequirednullable
Container number.
typestringrequirednullable
20gp40gp40hc45hc20rfteustringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
TEU equivalent of the container.
load_typestringrequirednullable
fcllclcargo_typestringrequirednullable
lightweightaverageheavyweightcontainer_onlyload_factorstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Measure of how fully the vehicle is utilising its cargo capacity (0 to 1).
empty_run_factorstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Proportion of the vehicle's travel that is done empty (0 to 1).
passenger_utilisationstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Passenger utilisation factor for passenger transport modes (0 to 1).
datesobjectrequirednullable
etdoneOfrequired
Estimated departure date or date-time.
etaoneOfrequired
Estimated arrival date or date-time.
atdoneOfrequired
Actual departure date or date-time.
ataoneOfrequired
Actual arrival date or date-time.
emissionsobjectrequirednullable
total_emissionsstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Total emissions (kg CO2e).
wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Well-to-tank emissions (kg CO2e).
ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Tank-to-wheel emissions (kg CO2e).
intensitystringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Emission intensity.
particles_totalstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Total particulate matter emissions (kg).
particles_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Well-to-tank particulate matter emissions (kg).
particles_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Tank-to-wheel particulate matter emissions (kg).
carbon_dioxide_totalstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Total carbon dioxide emissions (kg).
carbon_dioxide_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Well-to-tank carbon dioxide emissions (kg).
carbon_dioxide_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Tank-to-wheel carbon dioxide emissions (kg).
nitrogen_oxides_totalstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Total nitrogen oxides emissions (kg).
nitrogen_oxides_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Well-to-tank nitrogen oxides emissions (kg).
nitrogen_oxides_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Tank-to-wheel nitrogen oxides emissions (kg).
sulfur_dioxides_totalstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Total sulfur dioxides emissions (kg).
sulfur_dioxides_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Well-to-tank sulfur dioxides emissions (kg).
sulfur_dioxides_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Tank-to-wheel sulfur dioxides emissions (kg).
non_methane_hydro_carbons_totalstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Total non-methane hydrocarbons emissions (kg).
non_methane_hydro_carbons_wttstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Well-to-tank non-methane hydrocarbons emissions (kg).
non_methane_hydro_carbons_ttwstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Tank-to-wheel non-methane hydrocarbons emissions (kg).
primary_energy_mjstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Primary energy consumption (MJ).
fuel_consumption_lstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Fuel consumption (litres).
distance_kmstringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Distance (km).
transport_activitystringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Transport activity (tonne-kilometres).
emission_factor_descriptionstringrequirednullable
Description of the emission factor used.
emission_factor_regionstringrequirednullable
Region of the emission factor.
emission_factor_sourcestringrequirednullable
Source of the emission factor.
emission_factor_intensitystringrequirednullable
Pattern: ^[0-9]+(\.[0-9]+)?$
Intensity value of the emission factor.
emission_factor_numeratorstringrequirednullable
Numerator unit of the emission factor.
emission_factor_denominatorstringrequirednullable
Denominator unit of the emission factor.
emission_factor_yearintegerrequirednullable
Year of the emission factor.
created_atstring (date-time)required
An <a href="https://pretty-rfc.herokuapp.com/RFC3339">RFC 3339</a>-formatted timestamp.
Errors
This API operation can return the following errors:401404429