Headless Live Preview with Gatsby
they updated the sourceNodes cycle since this config, you will need to update the schema first doing something like this:

An example using the body hook if you need it:

createSchemaCustomization({ refresh: true }).then(() =&gt; {
    sourceNodes({ webhookBody });
});