Abstract Electric vehicles (EVs) have emerged as a promising solution to address environmental concerns, especially benefiting urban delivery and last-mile fleets due to their unique operational characteristics. Despite the potential advantages, the adoption of electric trucks (eTrucks) into delivery fleets has been slow, mainly due to the challenge posed by eTrucks' limited driving range. Consequently, a reliable method for predicting the eTrucks' energy consumption in fleet route planning is essential, and the accuracy of the velocity trajectory forecast forming the fundamental basis. This paper introduces a data-driven approach to predict the velocity and energy consumption of medium-duty (MD) eTrucks, considering various road features, payload, and traffic conditions. A gated recurrent unit (GRU) is trained using traffic-labeled characteristic features specific to each road segment within a delivery route. For every predefined route, the GRU generates the velocity profile by analyzing a sequence of traffic states predicted from the maximum entropy Markov model (MEMM). Corresponding eTruck energy consumption is estimated using an autonomie truck model. Real-world EV data are used to evaluate the proposed method, and the results demonstrate that the model effectively utilizes the information, achieving high accuracy in predicting both eTruck velocity and energy consumption.