Nullability mismatch on variable $value and argument value (String / String!)

Hello!
my code return one error when execute query.
Using o monday playground that is query:

mutation {
  change_simple_column_value (board_id: 1320360890, item_id: 1537903846
, column_id: "lider3", value: "{\"email\"=>\"gabriellaselbach@gmail.com\", \"text\"=>\"gabriellaselbach@gmail.com\"}") {
     id
   }
}

Here is code in Nodejs using graphql

query -->
mutation ($board_id: Int!, $item_id: Int!, $column_id: String, $value: String) {
  change_simple_column_value (board_id: $board_id, item_id: $item_id, column_id: $column_id, value: $value) {
    id
  }
} 
variables {
  board_id: 1320360890,
  item_id: 1537903846,
  column_id: 'lider3',
  value: 'gabriella.staniecki@nodo.cc'
}

  errors: [
    {
      message: 'Nullability mismatch on variable $column_id and argument column_id (String / String!)',
      locations: [Array],
      fields: [Array]
    },
    {
      message: 'Nullability mismatch on variable $value and argument value (String / String!)',
      locations: [Array],
      fields: [Array]
    }
  ],

I believe the error message is trying to tell you that, the type of $column_id and $value is not correct. They should be nullable types just like for $board_id and $item_id.
Try changing this

mutation ($board_id: Int!, $item_id: Int!, $column_id: String, $value: String)

to this

mutation ($board_id: Int!, $item_id: Int!, $column_id: String!, $value: String!)

Hi @GabriellaSelbach!

I agree with @kolaai-- I would definitely recommend implementing his solution. Let us know if the issue persists.

Best,
Helen

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.