Skip to main content

API issue with checkbox

  • July 8, 2021
  • 6 replies
  • 1830 views

jasmined

Hello - I am trying to populate an external form data into monday.com using the GraphQL API. When I try to create an item and populate a checkbox - it seems to set the checkbox to true even if the value provided is true or false.
When I do this:
mutation { create_item (board_id: 1409811733, item_name: “test_item_name”,column_values: “{"check": {"checked":"false"}}”) { id }}
OR
mutation { create_item (board_id: 1409811733, item_name: “test_item_name”,column_values: “{"check": {"checked":"true"}}”) { id }}

It sets the checkbox to true. “False” does not matter. Is this a bug?

This topic has been closed for replies.

6 replies

Forum|alt.badge.img
  • monday.com Team Member
  • July 9, 2021

Hi @jasmined!

In this case, you want to clear the column value in your checkbox column like this:

This should work.


jasmined
  • Author
  • New Participant
  • July 9, 2021

Thank you. I do not have much flexibility with the gravity form that i’m trying to send over to monday.com. I can send the values true or false but not have an if/else condition to check.

If false does not work - I will simply use a formula or automation to populate the value!


Forum|alt.badge.img
  • monday.com Team Member
  • July 9, 2021

Hi @jasmined,

Do you mind letting me know a bit more about the workflow you’re looking to set up?

What if you can set the value to be either true or empty? So if it’s not true, the user doesn’t select an option at all.


jasmined
  • Author
  • New Participant
  • July 9, 2021

Hello yes - I can set to true or empty. How would I pass the JSON string when its empty? Thank you


Forum|alt.badge.img
  • monday.com Team Member
  • July 12, 2021

Hi @jasmined!

The JSON string would be empty, just like in the screenshot I sent above:

"{}"


  • July 19, 2021

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