How to create input sensor for energy meter? Data from REST API

Hi, I have a REST endpoint that can give me cumulative data on how much the energy consumption is hour by hour.
How do I go about creating a manual input energy sensor?
I am new and a bit confused on how to create manual input sensors, and never tried with any energy settings either.

I have an enpoint returning a json with the data, hour by hour.
Thanks in advance!

If you have the values in a rest sensor, why do you want to use that into a input sensor? Why not use the rest sensor directly on whatever you need those values?

What are you trying to achieve in the end?

I custom made a local REST api that pulls the data from my energy provider cloud (instead of using their dashboard).
The problem is that it shows the values in a 1h interval and especially, rom the day before.
I do not have the real time data but the data of yesterday, hour by hour.

I created a rest sensor in the config now, but I do not know how to instruct it so the value is for a timerange of 1h (the time range also is returned in the JSON).

the rest return this

{"canFilter": false, "dayLightSavingsTime": false, "end": "2023-02-24T19:59:59+01:00", "high": 0.0, "low": 0.0, "maxPower": {"date": "2023-02-24T19:00:00+01:00", "status": "OK", "timeString": "19:00  - 20:00", "value": 0.477}, "normal": 0.477, "reactive": 0.0, "start": "2023-02-24T19:00:00+01:00", "status": "OK", "tooltipText": null, "total": 0.477}

If I could put the data time range for which the data is valid into home assistant would be great.
Any solution would be great actually, I home I made my issue clear

At the end I would like to have either a bar chart hour by hour or a simple line chart with the daily consumption (delayed 1 day).

Now the sensor has this config:

- platform: rest
    name: "Home Energy Consumption (yesterday last hour)"
    unique_id: "home_energy_cons_lasthour"
    resource: http://..IP../lasthour
    method: GET
    device_class: energy
    state_class: total_increasing
    force_update: true
    value_template: "{{ value_json.normal }}"
    unit_of_measurement: "Wh"