I am using it as below
add this to configuration.yaml
rest:
resource: https://api.solarmanpv.com/device/v1.0/currentData?appId=<YOU APP ID>&language=en&=
method: POST
scan_interval: 300 #Solarman only get data every 5 min.
headers:
Authorization: bearer <YOUR ACCESS TOKEN>
Content-Type: application/json
payload: '{ "deviceSn": "<YOUR DEVICE SERIAL NO>"}'
sensor:
- name : "Inverter Temprature"
value_template: >
{%- for dict_item in value_json.dataList -%}
{%- if dict_item.key == "INV_T0"-%}
{{dict_item.value}}
{%- endif -%}
{%- endfor -%}
unit_of_measurement: °C
- name : "Total AC Output Power (Active)"
value_template: >
{%- for dict_item in value_json.dataList -%}
{%- if dict_item.key == "APo_t1"-%}
{{dict_item.value}}
{%- endif -%}
{%- endfor -%}
unit_of_measurement: W
- name : "Cumulative Production kWh"
value_template: >
{%- for dict_item in value_json.dataList -%}
{%- if dict_item.key == "Et_ge0"-%}
{{dict_item.value}}
{%- endif -%}
{%- endfor -%}
unit_of_measurement: kWh
- name : "Daily Production kWh"
value_template: >
{%- for dict_item in value_json.dataList -%}
{%- if dict_item.key == "Etdy_ge1"-%}
{{dict_item.value}}
{%- endif -%}
{%- endfor -%}
unit_of_measurement: kWh
- name : "AC Voltage R/U/A"
value_template: >
{%- for dict_item in value_json.dataList -%}
{%- if dict_item.key == "AV1"-%}
{{dict_item.value}}
{%- endif -%}
{%- endfor -%}
unit_of_measurement: V
- name : "AC Current R/U/A"
value_template: >
{%- for dict_item in value_json.dataList -%}
{%- if dict_item.key == "AC1"-%}
{{dict_item.value}}
{%- endif -%}
{%- endfor -%}
unit_of_measurement: A
- name : "DC Power PV1"
value_template: >
{%- for dict_item in value_json.dataList -%}
{%- if dict_item.key == "DP1"-%}
{{dict_item.value}}
{%- endif -%}
{%- endfor -%}
unit_of_measurement: W
- name : "DC Current PV1"
value_template: >
{%- for dict_item in value_json.dataList -%}
{%- if dict_item.key == "DC1"-%}
{{dict_item.value}}
{%- endif -%}
{%- endfor -%}
unit_of_measurement: A
- name : "DC Voltage PV1"
value_template: >
{%- for dict_item in value_json.dataList -%}
{%- if dict_item.key == "DV1"-%}
{{dict_item.value}}
{%- endif -%}
{%- endfor -%}
unit_of_measurement: V