0 I am building a social app with nextjs for frontend and SSR, graphql-yoga server, and pothos for typesafe graphql and prisma for my db. I have followed all the example given in all their documentation for integration. However, I am getting a confusing error. ERR Error: Type Post must define one or more fields. […]
0 How can I use social_django with strawberry graphql? With graphene, I inherited my strawberry.type from SocialAuthJWT I used in grapgene like this. class SocialAuth(graphql_social_auth.SocialAuthJWT): user = graphene.Field(UserType) @classmethod def resolve(cls, root, info, social, **kwargs): social.user.is_verified = True social.user.save() token = get_token(social.user) return cls(user=social.user, token=token) I’d like to log in with google. python python-3.x django […]
11 I recently discovered Java records, and it was amazing to learn about their existence and purpose. However, I began to wonder if they are essentially just classes behind the scenes. Does this mean that during compilation, they get converted into an explicit class with final private fields, a public constructor, and the necessary getters? […]
0 I’m looking for a method to dynamically generate Python functions that correspond to the queries and mutations defined in a GraphQL schema. After obtaining the schema, I want a system that can automatically create these functions, so I can simply import the generated code into my Python project and call the functions with the […]
0 I am trying to pass header in @apollo/client useQueryQuery but it is not getting passed. Click on login button will call loginRequest. Its a REST call which is using Graphql. IMPORTANT -> in loginRequest is getting called at many places, some places need to pass the header and some place not. Below I added […]
0 type oPlayer @key(fields: "id") @key(fields: "name"){ id:ID name: String } extend type oPlayer @key(fields: "name") @key(fields: "PlayerId") { name: String @external PlayerId: ID @external } I am tring to resolve that field using PlayerId field with id but I am not able get data in referance resolver How to provide alias to "PlayerId:id" so […]
0 I’m using React Admin with GraphQL and ra-data-hasura. My problem is that the Introspection Query is made only when the app starts (user has role guest before login) and after login, the Introspection Query does not refetch, so I get errors for the resources that the logged in user should have access to. After […]
3 Either via using GraphQL or the Rest API, I create a cart for a customer (Either by sending customer_id in REST, or x-bc-customer-id in GraphQL). GraphQL: Create customer Impersonation Token and Create Cart Note: There’s also an Assign Cart to Customer mutation, but it only took a cart and didn’t do anything. REST: Create […]
22 I’m trying to combine multiple GraphQL queries into one query using JavaScript. I am looking for something like this: let query3 = mergeQueries(query1, query2); We won’t know beforehand which queries will be combined. Suppose I have queries like this: input query1: { post(id: 1234) { title description } } input query2: { post(id: 1234) […]
0 I am trying to get a test file (ian wheeler ms.png) from a SharePoint online document library in the sub folder General to download to a local folder of C:Temp using this question and answer microsoft-graph-download-file-via-rest-api I am able to make a call in postman to return my file contents to postman. The call […]