pub struct PartialCdr {Show 14 fields
pub country_code: Option<Code>,
pub party_id: Option<String>,
pub start_date_time: DateTime<Utc>,
pub end_date_time: DateTime<Utc>,
pub currency: Code,
pub total_energy: Option<Kwh>,
pub total_time: Option<TimeDelta>,
pub total_parking_time: Option<TimeDelta>,
pub total_cost: Option<Price>,
pub total_energy_cost: Option<Price>,
pub total_fixed_cost: Option<Price>,
pub total_parking_cost: Option<Price>,
pub total_time_cost: Option<Price>,
pub charging_periods: Vec<ChargingPeriod>,
}Expand description
A partial CDR generated by the cdr_from_tariff function.
The CDR is partial as not all required fields are set as the cdr_from_tariff function
does not know anything about the EVSE location or the token used to authenticate the chargesession.
- See: OCPI spec 2.2.1: CDR
- See: OCPI spec 2.1.1: Tariff
Fields§
§country_code: Option<Code>ISO-3166 alpha-2 country code of the CPO that ‘owns’ this CDR.
party_id: Option<String>ID of the CPO that ‘owns’ this CDR (following the ISO-15118 standard).
start_date_time: DateTime<Utc>Start timestamp of the charging session.
end_date_time: DateTime<Utc>End timestamp of the charging session.
currency: CodeISO-3166 alpha-2 country code of the CPO that ‘owns’ this CDR.
total_energy: Option<Kwh>Total energy charged, in kWh.
total_time: Option<TimeDelta>Total time charging.
total_parking_time: Option<TimeDelta>Total time not charging.
total_cost: Option<Price>Total cost of this transaction.
total_energy_cost: Option<Price>Total cost related to the energy dimension.
total_fixed_cost: Option<Price>Total cost of the flat dimension.
total_parking_cost: Option<Price>Total cost related to the parking time dimension.
total_time_cost: Option<Price>Total cost related to the charging time dimension.
charging_periods: Vec<ChargingPeriod>List of charging periods that make up this charging session. A session should consist of 1 or more periods, where each period has a different relevant Tariff.