Error : There are items that are not in the connected boards

hi all
i’m trying to create an item with column value as linked ref.

example of existed item

{
  "data": {
    "boards": [
      {
        "items": [
          {
            "id": "1457000300",
            "name": "new item",
            "column_values": [
              {
                "id": "connect_boards",
                "title": "Partner",
                "value": "{\"changed_at\":\"2021-07-06T23:03:30.192Z\",\"linkedPulseIds\":[{\"linkedPulseId\":1290737106}]}"
              }

and than i’m trying to create a new one at the same board to the same linked item

mutation {
  create_item(board_id: 1457000226, 
    item_name: "one new item", 
    column_values: "{\"connect_boards\": {\"linkedPulseIds\": [{\"linkedPulseId\": \"1290737106\"}]}}"
  
  ) {
    id
  }
}

but getting an error:

{
  "error_code": "ColumnValueException",
  "status_code": 200,
  "error_message": "There are items that are not in the connected boards",
  "error_data": {}
}```

hi @AntonL

I am wondering where you get the boardId 1457000226 in your create_item mutation from. If you want to create a subitem, there are two options:

  • use the mutation create_subitem, which takes the parent itemId as an argument, so in this case the parent itemId is 1457000300
  • use the mutation create_item but specify the board where the subitems live, this is not the same board where the parent items lives (although it looks like one board, you are viewing multiple board). To get hold of the board where the subitems live you can query the board for the parent items by querying the setting_str of the subitems column.

As you can see I query a board and a column (i happen to know the columnId for the subitems column) for the setting_str and get the boardId for the board where the subitems live. Now I can use that boardId to create an item with create_item.

The first option is the easiest one to use.

Perhaps I made a mistake in the question.(seems i dont understand what is subitem)
i’m trying to create an item with column value which is linkedPulseIds

Ahhh, I see. I got a little confused because of the subitems terminology which is something else.

The error shows that the item (itemId: 1290737106) is found, but the board it lives in is not configured in your connect_boards column. You have to connect the boards where the item 1290737106 lives in your connect_boards column through the UI with: connect_boards column > Settings > Customize… > Connect more boards. Unfortunatly this can’t be done throught the API as the API does not have access to the settings_str where this value is stored in. You can query it (but not change it) by:

thank you for you reply
but other board is already connected in settings
and i can manually set reference to other board.
i’ve found solution

result is received with next query:
“linkedpulseID” - replaced with “item_ids”

mutation {
  create_item(
    board_id: 1457000226,
    item_name: "one another new item",
    column_values: "{\"connect_boards\" : {\"item_ids\" : [2520632780]}}"
  ) {
    id
  }
}

ohh, ok

But the create_item mutation is setting the value for connect_boards in a way I don’t think is correct. The mutation you show throws a 500 Internal server error, Try this one instead:

mutation {
  create_item(
    board_id: 1457000226,
    item_name: "one another new item",
    column_values: "{\"connect_boards\": {\"linkedPulseIds\":[{\"linkedPulseId\":2520632780}]}}"
  ) {
    id
  }
}

wow, cool, its working.
thanks!!!
i compared your with my query from first post
the mistake was in quotes on linked ID

your variant: "{\"connect_boards\": {\"linkedPulseIds\":[{\"linkedPulseId\":2520632780}]}}"
my variant  : "{\"connect_boards\": {\"linkedPulseIds\":[{\"linkedPulseId\":\"1290737106\"}]}}"
  

thanks again!!!