Skip to main content

Create Subitem Columns through API / Customize ColumnID

  • March 23, 2023
  • 10 replies
  • 1001 views

jsararas

I see a few topics on this but they are closed to new replies. I would like to control the naming of columns in the subitem, so that I’m not dealing with the default ‘text’, ‘text5’, ‘text7’ in my query creation efforts. I can create columns in a parent item via the API and name it whatever I want using:

mutation{
  create_column(board_id: 1234567, title:"Meaningful Column Name", description: "Test Column Creation", column_type:status) {
    id
    title
    description
  }
}

but when I substitute the board id for the subitem board, I get a 500 Internal server error in the API playground.

Is there a way to create subitem columns with meaningful ids?

10 replies

  • March 24, 2023

Hi @jsararas,

Currently, our API does not support updating column IDs.


jsararas
  • Author
  • Participating Frequently
  • March 24, 2023

Thanks @alessandra- I meant upon creation (not trying to update). If I create a (parent) column via API, the ID generates from the column name I specify, which is great. But it doesn’t seem to work the same way if I change the boardID to the subitem boardID using the same API call. I was hoping there was a correct way to do it so that the subitem columnID would get created in the same fashion.


Matias.Monday
Forum|alt.badge.img
  • monday.com Team Member
  • March 26, 2023

Hello there @jsararas,

This should work in the same way as regular items.

I just tested this to double-check.

Using this query:

mutation{
  create_column(board_id:1234567890, title:"this is my column", column_type:text){
    id
  }
}

I created a new column in my subitems board of the type text and with the ID this_is_my_column.

Please remember about this limitation we have!

Is the title you are using for the column longer than 20 characters? What mutation are you using and which result are you getting? Can you show a screenshot of you testing it in your Playground?

Cheers,
Matias


jsararas
  • Author
  • Participating Frequently
  • March 28, 2023

I was using a pulse ID instead of the board ID. 🤦‍♂️


Matias.Monday
Forum|alt.badge.img
  • monday.com Team Member
  • March 28, 2023

Hello @jsararas,

It is great that you found the source of the issue!

Don’t worry, it happens to the best hahaha 🙂

Cheers,
Matias


  • New Participant
  • November 20, 2023

Hi Alessandra,
Does the current API still not supporting updating column ID’s?
It is quite difficult to deal with an integration with all your columns with random names text5, numbers8, dropdown4, etc…
Regards
Victor,


Matias.Monday
Forum|alt.badge.img
  • monday.com Team Member
  • November 21, 2023

Hello there @Vics,

You can choose an ID as explained here when creating a column via API, but changing an existing column’s ID is not possible at the moment.

Cheers,
Matias


jsararas
  • Author
  • Participating Frequently
  • November 21, 2023

Hey @Matias.Monday! I have just submitted a feature request around the auto-naming of ColumnID. Please take a look! I’ll post the link here once approved.


jsararas
  • Author
  • Participating Frequently
  • November 22, 2023

Here is the feature request. Basically asking for columnID auto-naming to base off of the supplied column title -the way it already works when you create a column using an API mutation- instead of appending a number to the column type as the columnID, like text31.

Please vote!


jsararas
  • Author
  • Participating Frequently
  • November 29, 2023

@Vics Throw a vote down for this if you want to be able to have sensible column IDs! ID is a keyfield so you’ll likely never be able to change them, but at least they could get created with more meaning.