@php $baseUrl = url('/api/v1'); @endphp
curl -X GET "{{ $baseUrl }}/pages" \
-H "Accept: application/json" \
-H "X-API-KEY: your-api-key-here"
fetch("{{ $baseUrl }}/pages", {
method: "GET",
headers: {
"Accept": "application/json",
"X-API-KEY": "your-api-key-here"
}
})
.then(response => response.json())
.then(data => console.log(data));