Adding subscribers to items via API

Hi, I create items in Monday using the create_item GraphQL mutation but I can’t find a way to assign multiple users to the item. Is that possible using the API?

Hi @colin_stewart!

Yes, this is absolutely possible. You can specify multiple user IDs in the column_values argument. The structure would look something like this:

column_values: "{\"people3\":\"12345, 23456, 34567\"}"

Try this out and let me know if you’re still running into trouble!

Thanks for that, how do you know the id of the column (in your example ‘people3’) or is it always called people3 ?
Also, can I set the due date using the same method and how do I know the name of that column?
Thanks

Hey @colin_stewart :wave:

You can find the column IDs by using the API and querying the column IDs directly, or you can activate Developer’s mode. This will show you the column IDs when you open the column menu, like so:

You can also find more info on this in the following article:

Where to find board, item, and column IDs

I hope this helps clarify :slight_smile:

-Alex

So as we are integrating with multiple Monday systems that belong to our customers, I have no way of accessing that information automatically, which seems very strange as we have already integrated our system with Asana, Trello and Clickup which all provide standard fields to pass the data to.
Can you suggest a way for us to assign this data?

@colin_stewart

Thank you for circling back with me! All of the column IDs will be unique on a per board basis. This means that the same board can not have 2 Status columns, for example, with the id of “status”. One of them will be “status”, and the other will likely be “status_1”. Those are generated automatically by our platform and there isn’t a way to map your integrations to a pre-set list of IDs, since each board will have its own set of IDs. Does that make sense?

If you have the board ID, you can get a list of columns with their IDs, type and title, as well as additional settings, by using a query like the below:

query {
  boards (ids:1232810882) {
    columns {
      type
      id
      title
      settings_str
    }
  }
}

I hope this helps put things into context a bit further :slight_smile:

-Alex

Yes that makes sense.
I’ll just have to get our user to select the column from a list and then map the data to it.
Thanks for your help.

2 Likes

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