Tag: graphql
-
Can’t import the named export XXXX from non EcmaScript module (only default export is available)
30 I have a client-server setup, in which the client(create-react-app) runs on localhost:3000 and the server is an express server which is built on node and I’m attempting to build graphql schema-resolvers setup. I’m able to import .graphql files on the server, however, on the client side, I’m using this setup by graphql-tools. When I’m…
-
Why is AWS asking for a Cognito Identity Pool when My schema is and based on API
0 I don’t understand AWS Authorization yet. I’m getting this error. GraphQLAPI – ensure credentials error No Cognito Identity pool provided for unauthenticated access I thought by providing an API key this would just work like when you request from any other API. This is my schema: type art @model @auth( rules: [ { allow:…
-
Nest Js Graphql Resolve Field with Circular Dependency
0 I have a problem with a circular dependency in a GraphQL model. I’m using Nestjs Graphql MongoDb Mongoose ad I have 3 entities. @ObjectType() @Schema({ timestamps: true }) export class User { @Field(() => ID) _id: string; @Field({ nullable: true }) @Prop({ nullable: true, unique: true }) pseudoDiscord?: string; } @ObjectType() @Schema({ timestamps: true…
-
Is it possible to query multiple aggregates with different where conditions for each (hasura)?
0 Say I have two tables, clubs and posts. Each club can have many posts and my app stores a timestamp for when the user last viewed a post for each club (‘last_viewed’). What I want to do, is query for the number of all new posts (since that club was looked at) and display…
-
Unknown Custom Scalars during Apollo Client GraphQL 3.0 migration
0 I have been following this link to do an apollo client version upgrade: https://www.apollographql.com/docs/kotlin/migration/3.0/ After completing the section to replace customTypeMapping I am now seeing the following error: Apollo: unknown custom scalar(s) in customScalarsMapping: Date,Currency,Year,Month,Percentage,MediaType,Base64 My build.gradle.kts file has been updated to contain the updated custom scalar mapping methods: mapScalar("Date", "java.time.LocalDate") mapScalar("Currency", "java.util.Currency") mapScalar("Year",…
-
Is there a way to filter a nested value in GraphQL with a higher up value?
0 I’m wondering if there’s a way to filter a nested section with a higher up value – see below: query readSeasons($seasonID: ID) { readSeasons(filter: { id: { eq: $seasonID } }) { nodes { id minimumGamesToRank <—– THIS playerSeasons( filter: { matchesPlayed: { gte: minimumGamesToRank } }, <—– THIS sort: { currentPosition: ASC }…
-
Currently trying to create a graphql resolver mutation for reset Password
0 I’m facing a unusual error while accessing the reset password button. the error: Uncaught (in promise) ApolloError: error:0200009F:rsa routines::pkcs decoding error can anyone help me with this I’m trying to set the new password when i click the reset password button I’m using typegraphql, typeorm, react reactjs typescript graphql typeorm typegraphql Share Follow asked…
-
Mongoose not able to create a schema
0 Everything loaded fine before I had added a new schema. This is the resolver: import { Arg, Mutation, Query, Resolver } from "type-graphql"; import { Order } from "./order.schema"; import OrderService from "./order.service"; @Resolver() export default class OrderResolver { constructor(private orderService: OrderService) { this.orderService = new OrderService(); } @Mutation(() => Order) createOrder(@Arg("input") input: any)…
-
GraphQL Best Practise API Communication
0 I have an .Net Application which uses a graphQL API for some business logic. The schema is really big and so are the queries. I auto generated the graphql schema into c# classes which worked really well. But my Queries are equally big and I dont know how to store or build them besides…
-
GraphQL not showing schema and documentation NestJS
0 I’m working on GraphQL using NestJS and I’ve not created models separately so, in short, I combine them but my GraphQL playground is not showing schemas and documentation of my queries and mutations. GraphQL Config { driver: ApolloDriver, autoSchemaFile: true, path: SERVER_PREFIX_URL, debug: true, playground: true, introspection: true, plugins: [ ApolloServerPluginQueryComplexity({ estimators: [directiveEstimator(), simpleEstimator()],…