How to perform a search based on RuleID

I have this script and what I want to achieve is to perform the search for the RulesID within the currentalarm but I have not managed to find the variables that allow me this, someone who could support me

import java.sql.Timestamp
import java.text.SimpleDateFormat
import java.util.List;

Calendar c1 = GregorianCalendar.getInstance();
c1.add(Calendar.MINUTE, -1);
SimpleDateFormat sdf = new SimpleDateFormat("yyyy.MM.dd HH:mm:ss");
SimpleDateFormat sdf1 = new SimpleDateFormat("yyyy.MM.dd HH:mm:ss");
fechaactual = sdf.format(c1.getTime());

asvc = server.AlarmService

List<String> lstParameter = new ArrayList();

lstParameter.add("e26c9b5a-afab-4d4c-baa6-b582a1f45a87");
lstParameter.add("8efe3326-169d-454f-b5cb-3b16c08081f5");
lstParameter.add("030cf712-775f-47a3-9f62-818aabf110c5");
lstParameter.add("802fa22f-8bb7-4022-ab17-b76582577ee6");
lstParameter.add("d1a64a2b-b8db-4a25-ae90-bd03a0a1589e");
lstParameter.add("24b6e438-9320-4c3b-a6b0-463b90dd1890");
lstParameter.add("fa534ab5-da38-46ba-8839-87f33f2e8dba");
lstParameter.add("b9de46df-6fbb-4c23-8c15-81f86f538c9b");
lstParameter.add("adcfe881-8202-4b5e-80ef-fbb1730917e9");
lstParameter.add("77c5f695-a110-4875-8523-b07e68626032");

for (String valor : lstParameter){
    currentAlarms = asvc.getCurrentAlarms(valor);
    
    for(alarm in currentAlarms) {
  if(fechaactual <= sdf1.format(alarm.getCreatedTime())){
      def txt="Fecha: "+alarm.getCreatedTime() + " " + alarm.getMessage();
      enviarmensaje(txt);
  }
}
}



String enviarmensaje(String data){
    def TEXTO=data.replaceAll("\\'","");
    def numero=registry("SMS");
    def proc="";
    def cmd="";
    num=numero.tokenize(',');
    def count="";
    for(tel in num){
          cmd ='curl --ciphers ecdhe_ecdsa_aes_256_sha --data-urlencode  "key=wa524f36wav4ueue4bubv32eu4wf6a4d4fufu472we51yf" --data-urlencode  "phone='+tel+'" --data-urlencode "message='+TEXTO+'" --data-urlencode "tipo_sms=9"  -H "authorization: Basic NDQ1OmczbnQzcjQuZjBnbDFnaHQ0cDE="  -H "cache-control: no-cache"  
          proc  = ["bash", "-c", cmd].execute()
          proc.waitFor()
          proc.exitValue()   
    }
    
}
return 1