Skip to main content

I want to create an item with column value, the column ID is “project_status”, the column value is “Done”. I’d like to use the create_item api in cRUL format by Postman.


curl --location --request POST 'https://api.monday.com/v2' \\
--header 'Authorization: YourSuperSecretAPIkey' \\
--header 'Content-Type: application/json' \\
--data-raw '{"query": "mutation { create_item (board_id: 3819303550, item_name: \\"item 101\\", column_values: \\"{\\"project_status\\": \\"Done\\"}\\", create_labels_if_missing: true) { board {id name} column_values {id title} created_at creator {id name} group {id title} id name parent_item {id name} state subscribers {id name} updated_at email relative_link subitems {id name}}}"}'

I got error as below:


{
"errors": "
{
"message": "Parse error on \\": \\" (STRING) at T1, 100]",
"locations": c
{
"line": 1,
"column": 100
}
]
}
],
"account_id": 14649038
}

Could you tell me why?

I just found the solution. The JSON format in cRUL is different from simple double quote (using escape ""). I modified the request body as below, then it successed.


{"query": "mutation { create_item (board_id: 3819303550, item_name: \\"item 101\\", column_values: \\"{\\\\\\"project_status\\\\\\": \\\\\\"Done\\\\\\"}\\", create_labels_if_missing: true) { board {id name} column_values {id title} created_at creator {id name} group {id title} id name parent_item {id name} state subscribers {id name} updated_at email relative_link subitems {id name}}}"}


Hi @OktaDev,


Looks good! I’m happy to see you found a solution.


Let me know if you have any more questions.


Reply