kamilkisiela / graphql-config

One configuration for all your GraphQL tools (supported by most tools, editors & IDEs)
https://the-guild.dev/graphql/config
MIT License
1.16k stars 93 forks source link

Support schema registry such as `apollo-engine` similar to graphql-codegen #1367

Open kdawgwilk opened 1 year ago

kdawgwilk commented 1 year ago

Describe the solution you'd like

I would like to describe a schema config that lives in a schema registry such as Hive or Apollo engine

const supergraphConfigSchemaRegistry = {
  'apollo-engine': {
    engine: {
      apiKey: process.env.APOLLO_KEY!,
    },
    graph: '<GraphId>',
    variant: '<GraphVariant>',
  },
}

Describe alternatives you've considered

If I could pass an async function to the schema config prop I could do this fetching myself to load the schema from some remote service

Additional context

https://the-guild.dev/graphql/codegen/docs/config-reference/schema-field#apollo-engine

kdawgwilk commented 1 year ago

Could I do this with an extension and loader?