How do I add my UPS sensors to energy tab?

I am running the NUT addon with the following config:

users:
  - username: homeassistant
    password: REDACTED
    instcmds:
      - all
    actions: []
devices:
  - name: apcups
    driver: snmp-ups
    port: 10.40.0.6
    community: public
    mibs: auto
    config: []
mode: netserver
shutdown_host: false

And these are the available sensors for me:

And I want to add the UPS to the following:

  1. Home battery storage - UPS Battery
  2. Individual devices - Power Consumption from the wall

Note: This is what I see if I navigate the UPS IP address:


I need very simple and stupid step-by-step instructions on how to get my UPS into the two energy fields I specified (Home battery storage & Individual devices)

I have added my UPS as an individual device with the help of ChatGPT.

You need to know your UPS rated watt capacity - mine is 900W, and add two entries to your configuration.yaml:

template:
  - sensor:
      - name: "UPS Load Power"
        unit_of_measurement: "W"
        device_class: power
        state_class: measurement
        state: >
          {{ (states('sensor.upsload') | float * 900 / 100) | round(1) }}

to convert the NUT Load (%) into estimated real power and

sensor:
  - platform: integration
    source: sensor.ups_load_power
    name: ups_energy
    unit_prefix: k
    round: 3
    method: left

to create the energy sensor.

Save and reload, then you should be able to add to the energy page.