import { request } from '../esm/index.js' ;(async function () { const endpoint = 'https://api.graph.cool/simple/v1/cixos23120m0n0173veiiwrjr' const query = /* GraphQL */ ` { Movie(title: "Inception") { releaseDate actors { fullname # "Cannot query field 'fullname' on type 'Actor'. Did you mean 'name'?" } } } ` try { const data = await request(endpoint, query) console.log(JSON.stringify(data, undefined, 2)) } catch (error) { console.error(JSON.stringify(error, undefined, 2)) process.exit(1) } })().catch((error) => console.error(error))