A type should implement the UserError interface if and only if its name ends with Error.
Examples of correct code for this rule:
type BaseUserError implements UserError {
message: String!
code: ErrorCode!
}type PasswordTooWeakError implements UserError {
message: String!
code: ErrorCode!
passwordRules: [String!]!
}Examples of incorrect code for this rule:
type NotAnErrorType implements UserError {
message: String!
code: ErrorCode!
otherStuff: String!
}type PasswordTooWeakError {
passwordRules: [String!]!
}Do not use this for developer errors. Then again, you should probably revisit the GraphQL style guide if you're adding developer error graphql types.