Is it just me, or does prisma generate for graphql...
# orm-help
a
Is it just me, or does prisma generate for graphql-schema omit mutation parameters? e.g. I have
Copy code
type Mutation {
  login(email: String!, password: String!): String!
}
in my datamodel, but in the generated file this appears as
Copy code
type Mutation {
  login: String!
}`
n
I don't understand that question. Where are the two code snippets coming from, and what do they represent?
a
the first one is my (hand-written) datamodel.graphql, the latter is from the result when I run
Copy code
prisma generate
n
the datamodel is not intended for you to add mutations
You use the datamodel to describe the data structure, and Prisma automatically generates a GraphQL API based on it.
If you want to define a
login
mutation in your application, the right place for that is your application's
schema.graphql
.
a
I'll look into that. Thanks a lot!
👌 1