handle_vehicle_message validates a flat V2ICPVehicleRequest.
Every request must contain h2_stat and bat_stat; invalid input returns
422 Unprocessable Entity.
Every vehicle message requires HTTP Basic credentials whose username matches
the message VIN and whose password and EVCC ID match the same configured
vehicle credential binding.
The facade obtains and refreshes a Manage Core OAuth client-credentials token,
then requests the current neutral preconditioning directive.
A successful seq = 0 request receives the incoming seq and vin plus all
backend fields. Unavailable values use SNA; an active or stop directive
supplies the corresponding preconditioning values.
A later successful request receives the incoming seq and vin plus the
applicable preconditioning directive delta.
Manage Core transport, authentication, and invalid-response failures return
502 Bad Gateway. Missing or invalid integration configuration returns
503 Service Unavailable.
Unknown vehicle and backend fields are accepted and ignored.
record_diagnostic accepts a BetterFleet DiagnosticEvent at
/vdv261/v2icp/diagnostics and replies with 202 Accepted; it does not
persist the event.
/vdv261/schemas and /vdv261/schemas/{schema_name} expose model-derived JSON
schemas as BetterFleet extensions.
IPv6, port 443, TLS profile, certificate validation, User-Agent and US-ASCII
enforcement around the application.
Retry cadence, idle timeout, reconnect behaviour, and charging-session state.
Approved runtime provisioning and rotation for the Manage Core OAuth client
and typed per-vehicle VDV credential bindings (vin, evccId, and
password).
Business logic for ambienttemp, target_dist, and target_soc; these remain
SNA while the current preconditioning path supplies driveoff, prec_dsrd,
and prec_hvac.
Vehicle connectivity through a native vehicle API or VDV 261 V2ICP.
Response-size enforcement, persistence and monitoring.
Protocol conformance tests against representative vehicle and SECC products.
Comparison with licensed VDV 261 issue 07/2024 before a current-edition
conformance claim.