Access to API without authentification

Hi,

I need to load with AJAX all the children of a specific page.

It works for me but only when i am authenticated with panel acces. I need to allow anyone to have access to that data, without any authentication.

I understand that for security purposes, the API is reserved to authenticated user with panel access. In my case it would be fine to allow anyone to get this data.

What should i do ?

Here is my code

const content = document.getElementById("content");
const csrf = content.getAttribute("data-csrf");


  fetch("/api/pages/home/children?select=content", {
      method: "GET",
      headers: {
        "X-CSRF" : csrf,
      }
    })
    .then(response => response.json())
    .then(response => {
      const page = response.data;
      for(let post of page) {
        console.log(post);
      }

    })
    .catch(error => {
      // something went wrong
    });