Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support overwriting endpoint GraphQL schema #436

Closed
Tracked by #76 ...
n1ru4l opened this issue Feb 12, 2024 · 1 comment · Fixed by #444
Closed
Tracked by #76 ...

Support overwriting endpoint GraphQL schema #436

n1ru4l opened this issue Feb 12, 2024 · 1 comment · Fixed by #444

Comments

@n1ru4l
Copy link
Member

n1ru4l commented Feb 12, 2024

Allow overwriting of the GraphQL schema used by conductor in front of a GraphQL API.
Introspection and Validation should be done against the schema SDL provided, while validated requests should be forwarded to the actual endpoint (requests that contain __schema introspection fields and "normal" query selections, must be properly split and re-attached by the conductor).

Example Config:

config:
  endpoint: "https://my-source.com/graphql"
  schema: "https://kashdlasdkasjdlkq.eg/schema.graphqls" # THIS IS THE GATEWAY SCHEMA
id: "my-source"
type: "graphql" 

Example Endpoint Schema (config.endpoint)

type Query {
  a: Int!
  b: Int!
  foo: String!
}

Example "Schema"/Gateway Schema (config.schema)

type Query {
  foo: String!
}

--> We only want to expose the Query.foo field on the Gateway.

The use case for this is to support schema contracts for single schemas in Hive, see graphql-hive/platform#3856

@n1ru4l n1ru4l changed the title Support serving different GraphQL schema for endpoint Support overwriting endpoint GraphQL schema Feb 12, 2024
@dotansimha
Copy link
Member

The main blocker for this one is: #437

Also related: #6

@theguild-bot theguild-bot mentioned this issue Feb 19, 2024
63 tasks
This was referenced May 7, 2024
@theguild-bot theguild-bot mentioned this issue May 23, 2024
63 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants