-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathsimple-schema.apollo-workbench
1 lines (1 loc) · 5.11 KB
/
simple-schema.apollo-workbench
1
{"graphName":"simple-schema","operations":{"NearbyStoreProducts":"query NearbyStoreProducts ($zip:String) {\n\tnearbyStores(zip:$zip) {\n name\n instockProducts {\n quantity\n product {\n name\n price\n delivery (zip: $zip) {\n fastestDelivery\n }\n }\n }\n }\n}"},"queryPlans":{"NearbyStoreProducts":"QueryPlan {\n Sequence {\n Fetch(service: \"inventory\") {\n {\n nearbyStores(zip: $zip) {\n name\n instockProducts {\n quantity\n product {\n __typename\n id\n }\n }\n }\n }\n },\n Flatten(path: \"[email protected][email protected]\") {\n Fetch(service: \"products\") {\n {\n ... on Product {\n __typename\n id\n }\n } =>\n {\n ... on Product {\n name\n price\n __typename\n id\n dimensions {\n size\n weight\n }\n }\n }\n },\n },\n Flatten(path: \"[email protected][email protected]\") {\n Fetch(service: \"inventory\") {\n {\n ... on Product {\n __typename\n id\n dimensions {\n size\n weight\n }\n }\n } =>\n {\n ... on Product {\n delivery(zip: $zip) {\n fastestDelivery\n }\n }\n }\n },\n },\n },\n}"},"schemas":{"products":{"shouldMock":true,"sdl":"# BASIC SUPPORT\n# - @key\n# - Multiple @key defined on Entity\n# - Composite @key \n# - Basic @provides and @requires usage\n# ADVANCED SUPPORT\n# - Nested @key\n# - Nested @requires (@provides poentially on roadmap)\ntype Product @key(fields: \"id\") @key(fields: \"sku upc\") @key(fields: \"sku variation { id }\"){\n id: ID!\n sku: String\n variation: ProductVariation\n upc: String\n dimensions: ProductDimension \n\n createdBy: User @provides(fields: \"totalProductsCreated\")\n}\n\ntype ProductVariation {\n id: ID!\n color: String\n size: String\n}\n\ntype ProductDimension {\n size: String\n weight: Float\n}\n\nextend type Query {\n product(id: ID!): Product\n}\n\nextend type User @key(fields:\"email\") {\n email: ID! @external\n totalProductsCreated: Int @external\n}","autoUpdateSchemaFromUrl":false},"inventory":{"shouldMock":true,"sdl":"extend type Product @key(fields: \"id\") {\n id: ID! @external\n dimensions: ProductDimension @external\n delivery(zip: String): DeliveryEstimates @requires(fields: \"dimensions { size weight }\")\n}\n\ntype ProductDimension {\n size: String\n weight: Float\n}\n\ntype DeliveryEstimates {\n estimatedDelivery: String\n fastestDelivery: String\n}\n","autoUpdateSchemaFromUrl":false},"users":{"shouldMock":true,"sdl":"type User @key(fields:\"email\") {\n email:ID!\n name: String\n totalProductsCreated: Int\n}\n","autoUpdateSchemaFromUrl":false}},"supergraphSdl":"schema\n @core(feature: \"https://specs.apollo.dev/core/v0.1\"),\n @core(feature: \"https://specs.apollo.dev/join/v0.1\")\n{\n query: Query\n}\n\ndirective @core(feature: String!) repeatable on SCHEMA\n\ndirective @join__field(graph: join__Graph, requires: join__FieldSet, provides: join__FieldSet) on FIELD_DEFINITION\n\ndirective @join__type(graph: join__Graph!, key: join__FieldSet) repeatable on OBJECT | INTERFACE\n\ndirective @join__owner(graph: join__Graph!) on OBJECT | INTERFACE\n\ndirective @join__graph(name: String!, url: String!) on ENUM_VALUE\n\ntype DeliveryEstimates {\n estimatedDelivery: String\n fastestDelivery: String\n}\n\nscalar join__FieldSet\n\nenum join__Graph {\n PRODUCTS @join__graph(name: \"products\" url: \"\")\n INVENTORY @join__graph(name: \"inventory\" url: \"\")\n USERS @join__graph(name: \"users\" url: \"\")\n}\n\ntype Product\n @join__owner(graph: PRODUCTS)\n @join__type(graph: PRODUCTS, key: \"id\")\n @join__type(graph: PRODUCTS, key: \"sku upc\")\n @join__type(graph: PRODUCTS, key: \"sku variation { id }\")\n @join__type(graph: INVENTORY, key: \"id\")\n{\n id: ID! @join__field(graph: PRODUCTS)\n sku: String @join__field(graph: PRODUCTS)\n variation: ProductVariation @join__field(graph: PRODUCTS)\n upc: String @join__field(graph: PRODUCTS)\n dimensions: ProductDimension @join__field(graph: PRODUCTS)\n createdBy: User @join__field(graph: PRODUCTS, provides: \"totalProductsCreated\")\n delivery(zip: String): DeliveryEstimates @join__field(graph: INVENTORY, requires: \"dimensions { size weight }\")\n}\n\ntype ProductDimension {\n size: String\n weight: Float\n}\n\ntype ProductVariation {\n id: ID!\n color: String\n size: String\n}\n\ntype Query {\n product(id: ID!): Product @join__field(graph: PRODUCTS)\n}\n\ntype User\n @join__owner(graph: USERS)\n @join__type(graph: USERS, key: \"email\")\n @join__type(graph: PRODUCTS, key: \"email\")\n{\n email: ID! @join__field(graph: USERS)\n name: String @join__field(graph: USERS)\n totalProductsCreated: Int @join__field(graph: USERS)\n}\n"}