Tag: graphql
-
Amplify API GraphQL – Unable to query from aws console
0 I have deployed a new GraphQL private API to my aws console. While I am trying to run the query from aws console, I am getting below error Cannot read properties of undefined (reading ‘data’) Here is my query: query MyQuery { listData(limit: 10) { nextToken } } amazon-web-services graphql Share Improve this question…
-
Invariant Violation: Encountered an error trying to infer a GraphQL type for: `tags___NODE`
0 I am new to Gatsby. I’m creating a blog site using Gatsby and Contentful as CMS. On creating a field ‘timeToRead’ I’m getting an error as ERROR #11321 API.NODE.EXECUTION "gatsby-source-contentful" threw an error while running the sourceNodes lifecycle: _node$fields.includes is not a function However whenever I clear cache and rebuild the appliction it works…
-
Import specific GraphQL fragments?
0 I have a fragment in a file that contains a lot of other fragments. file.gql #import "./fragment.gql" query Query { …Fragment } fragment.gql fragment Fragment { … } …other fragments here Doing this causes an error because of the unused fragments. Is it possible to import just that one fragment? Or do I seriously…
-
How to represent a map or object with key-value pairs in GraphQL?
2 How can I query for the following object? { result: { ‘1’: { ^^^ these are dynamic keys, never constant id: ‘id1′, }, ’20’: { id: ‘id2’, }, ‘300’: { id: ‘id3′, }, } } I know that I can define the result object fairly simply, if it wasn’t a key-value pair object. const…
-
Using api-platform to query with GraphQL, how can I create a filter from a virtual field?
0 Im using symfony 6 and api-platform/core: v3.1.3. Said that, I have an entity that has a method calculable/virtual that I would like to query using graphQL That is the entity <?php #[ ApiResource( operations: [ new Get(), new Put( denormalizationContext: [‘groups’ => [‘update’]], ), new Delete(), new GetCollection(), new Post(), ], normalizationContext: [‘groups’ =>…
-
CORS blocks mutation in GraphQL Yoga
6 I am working here with a graphql prisma backend and a graphql yoga express server on top of that. In the frontend, I am trying to call a signout mutation but its blocked by the CORS policy. Though I have added cors settings in my graphql yoga server, I keep getting this error. GraphQL…
-
An error occurred while executing the command definition. See the inner exception for details.(11)
-1 I added one table inside db and generated model with entity framework in asp.net web api(not core) when i try to access that particular end point I am getting this error fast if someone knows this how to solve post your answer I tried this today and expecting an answer asp.net entity-framework graphql Share…
-
Can’t use extensions with GraphQLError
3 From the Apollo Graphql document, this way can define extension error: https://www.apollographql.com/docs/apollo-server/data/errors/ import { GraphQLError } from ‘graphql’; throw new GraphQLError(‘the error message’, extensions: { code: ‘SOMETHING_BAD_HAPPENED’, https: { status: 404, headers: new Map([ [‘some-header’, ‘it was bad’], [‘another-header’, ‘seriously’], ]), }, }, ); But in my case it got this error: Argument of…
-
How to close the websocket in graphql config flutter?
1 class GraphqlConfig { final serverLink = Link.split( (request) => request.isSubscription, WebSocketLink( "mylink" ), HttpLink("mylink", defaultHeaders: <String, String>{ })); initClient() { ValueNotifier<GraphQLClient> client = ValueNotifier( GraphQLClient( link: serverLink, cache: GraphQLCache(), ), ); return client; } GraphQLClient clientToQuery() { return GraphQLClient( cache: GraphQLCache(), link: serverLink, ); } } I got the following exception DOMException: Failed to…