cUrl/restful API - Solarman API

Hi,

I hope you can help, I’m trying to get data from my Solar Inverter via the Solarman API. I can see the data when I run a curl command online but I’ve no idea how to get this into Home Assistant.
I have tried playing around with RESTful, command sensor etc but I think I’m doing it all wrong.

This is the curl request I send

curl --request POST \
  --url 'https://api.solarmanpv.com/device/v1.0/currentData?appId=<SECRETID>&language=en&=' \
  --header 'Authorization: bearer <SECRET AUTH>' \
  --header 'Content-Type: application/json' \
  --data '{
	"deviceSn": "<SECRET SN>"
}'

When running this I get a huge list of results that look like this;

{
    "code": null,
    "msg": null,
    "success": true,
    "requestId": "secret",
    "deviceSn": "secret",
    "deviceId": secret,
    "deviceType": "INVERTER",
    "deviceState": 1,
    "dataList": [{
        "key": "SN1",
        "value": "secret",
        "unit": null,
        "name": "SN"
    }, {
        "key": "SS_CY1",
        "value": "16",
        "unit": null,
        "name": "Production Compliance Country"
    }, {
        "key": "SWmai_v1",
        "value": "V260",
        "unit": null,
        "name": "Software Master Version"
    }

Can someone please assist me with getting this data into Home Assistant as sensors?

Thank you

Should definitely be one or multiple RESTfull sensors:

Please show what you have.
If you don’t have anything, please start by looking in the forum. Plenty of examples, here.

Thank you so much I’ve been looking at this and a few others and kept getting confused.

I’ve managed to get a response for the first set of JSON responses but not sure how to access the child stuff.

{
    "code": null,
    "msg": null,
    "success": true,
    "requestId": "bbc9d86ba525fa6e",
    "deviceSn": "SM1ES136LBJ163",
    "deviceId": 208812929,
    "deviceType": "INVERTER",
    "deviceState": 1,
    "dataList": [{
        "key": "SN1",
        "value": "SM1ES136LBJ163",
        "unit": null,
        "name": "SN"
    }, {
        "key": "SS_CY1",
        "value": "16",
        "unit": null,
        "name": "Production Compliance Country"
    }, {
        "key": "SWmai_v1",
        "value": "V260",
        "unit": null,
        "name": "Software Master Version"
    }

Each of the JSON entries look the same the only real difference is the data

 {
        "key": "DC2",
        "value": "0.00",
        "unit": "A",
        "name": "DC Current PV2"
    }, {
        "key": "DP1",
        "value": "970.00",
        "unit": "W",
        "name": "DC Power PV1"
    }, {
        "key": "DP2",
        "value": "0.00",
        "unit": "W",
        "name": "DC Power PV2"
    }

Is there a way to filter down to the child results?

Got it using this tool!

https://jsonpathfinder.com/

Amazing, thank you for the pointers really helpful