How to add image found condition in visualassert?

Hi,

I want to test my website login page with captcha added so i wanted to click only when solved captcha image matched like this:
image

im using automated 2captcha extension to solve that so if the above image matched then click on login button otherwise wait

my code:

{
  "Name": "EE",
  "CreationDate": "2024-12-13",
  "Commands": [
    {
      "Command": "store",
      "Target": "user1@example.com",
      "Value": "username",
      "Description": ""
    },
    {
      "Command": "store",
      "Target": "password1",
      "Value": "password",
      "Description": ""
    },
    {
      "Command": "click",
      "Target": "id=username",
      "Value": "",
      "Description": ""
    },
    {
      "Command": "type",
      "Target": "id=username",
      "Value": "${username}",
      "Description": ""
    },
    {
      "Command": "click",
      "Target": "id=password",
      "Value": "",
      "Description": ""
    },
    {
      "Command": "type",
      "Target": "id=password",
      "Value": "${password}",
      "Description": ""
    },
    {
      "Command": "click",
      "Target": "id=sso-forms__submit",
      "Value": "",
      "Description": ""
    },
    {
      "Command": "visualAssert",
      "Target": "drjuqy_dpi_96.png",
      "Value": "",
      "Description": ""
    },
    {
      "Command": "executeScript_Sandbox",
      "Target": "return ${!statusOK};",
      "Value": "captchaFound",
      "Description": ""
    },
    {
      "Command": "if_v2",
      "Target": "${captchaFound} == true",
      "Value": "",
      "Description": ""
    },
    {
      "Command": "click",
      "Target": "id=sso-forms__submit",
      "Value": "",
      "Description": ""
    },
    {
      "Command": "pause",
      "Target": "3000",
      "Value": "",
      "Description": ""
    },
    {
      "Command": "end",
      "Target": "",
      "Value": "",
      "Description": ""
    }
  ]
}

Note: I added two click login button because google-recaptcha v2 triggers only when we click on login 1 time then it shows

i try with this but its not working:

"Command": "executeScript_Sandbox",
      "Target": "return ${!statusOK};",

Does this help?

If {picture} then {do this}