Houdini not able to pull schema. "ERROR: couldn't pull your schema: resp.text is not a function"
I have a SvelteKit project where i am trying to query a GraphQL endpoint and get end to end typesafety using Houdini.
I run npx houdini init in my repository and get the following error:
⚠️ Couldn't pull your schema: resp.text is not a function
I am able to query the graphql endpoint in my +page.ts files trivially with:
const response = await fetach(GRAPHQL_ENDPOINT, {
method: "POST",
headers: {
"Content-Type": "application/json",
}
body: JSON.stringify({ query }),
});
What could be the cause of this error and how can i fix it?