Thx for reply.
I looked at github. I understand the json code.
But when I want to switch more then one relay at the same time
with while or for loop, only one relay change status.
my $client = new JSON::RPC::Client;
my $url = "http://<ip address and port from unipi>/rpc";
for (my $i=1; $i<=4; $i++)
$client->relay_set_for_time($i, 1, 3600);
thx for help