const { getAuth } = require('./auth_manager'); async function main() { const td = await getAuth(); const res = await fetch('https://graphql.ghaymah.systems/v1/graphql', { method: 'POST', headers: { 'Authorization': 'Bearer ' + td.token, 'Content-Type': 'application/json' }, body: JSON.stringify({ query: `query { ghaymah_cloud_resources(where: { id: { _eq: "1a83e477-9e98-4dbb-8931-cc273db6e607" } }) { id chart_name chart_version status values message } }` }) }); console.log(JSON.stringify(await res.json(), null, 2)); } main().catch(console.error);