In heartbeat ver. 7.17 browser type is not working

Trying using using the following code still not working.

type: browser
id: elastic-website
name: Elastic website
schedule: "@every 1m"
source:
inline:
script: |-
step("load homepage", async () => {
await page.goto('https://www.elastic.co');
});
step("hover over products menu", async () => {
await page.hover('css=[data-nav-item=products]');
});

Hi Heet, welcome to the community.

Can you confirm if your yaml has the correct formatting (indentation), e.g. the above should look like

- type: browser
  id: synthetic-inline-suites
  name: Elastic website
  schedule: '@every 1m'
  source:
    inline:
      script: |-
        step("load homepage", async () => {
          await page.goto('https://www.elastic.co');
        });
        step("hover over products menu", async () => {
          await page.hover('css=[data-nav-item=products]');
        });

in your yaml.

If that's correct, can you provide more details about your setup and what errors do you get in logs?

Are you using either the heartbeat docker image or the elastic-agent-complete docker image? Per the docs this monitor type requires either docker container since browsers require a complex set of dependencies.