Create new item with link column

Hi,

I’m trying to create new items, providing column values. Everything it’s fine, except with link (url) columns. Can anybody tell me how to add a link field?

I know that a link field has 2 subfields (“web address” and “text to display”), so I suppose that I have to provide an object with both values, but I cannot find any example in the documentation.

What should be the proper way to add the link field:

mutation {
create_item (board_id:111111, item_name:“test3”, column_values: “{"link": "www.test.com"}”
) {
id
}
}

hi @alexander.herranz

Welcome to the community. It is sometimes hard to find the exact object notation including escapes quotes. This one should work. Change the board_id and don’t hesitate to click on the “visit me” link.:slight_smile:

mutation {
create_item(board_id: 1111111111, item_name: "Best site for monday apps", column_values: "{\"link\":{\"url\":\"https://excellent-team.nl\",\"text\":\"visit me\"}}") {
    id
  }
}

Hi @alexander.herranz!

You can also check out the “Link” column in our documentation that also provides an example of the structure you would need: https://api.developer.monday.com/docs/link.

Let us know if you have additional questions or concerns at this time.

Thanks too much! That’s exactly what I was looking for.

Very useful link in that documentation, thanks too much. I didn’t locate that info at first.

2 Likes

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