Linux ups function + cerbo gx

hi i have Arch linux and i want to communicate my system with the cerbo gx in order to safe poweroff my PC when battery charge goes below a certain percent. basically i want to know my battery charge via a terminal and pass this value into the upower service or NUT tools in order to give the shutdown command. is there a way to do that?
after a basic search the NUT tools maybe support the Victron products because there is a driver named victronups.

thanks for your time

It is possible with Node Red on your Cerbo GX (and a second Node Red)

Only I had problem to install an SSH client node-red-contrib-ssh-v3 (node) - Node-RED on the Cerbo

So I use a second Node Red on a Linux server

Get SOC value Node Red GX => send SOC value (MQTT) => Second Node Red => Run node SSH with command