Hi! Please help.How do I update a linked column with moncli?

Hey!
I have tried everything for the last 24 hours and going crazy!
I can’t seem to update a linked column with moncli api.

  column_value = row.column_values['title of column']
  column_value.text='some value'
  column_value = row.column_values['Operator- old']
  row.change_column_value(column_value)

Here is the log of the script:
‘id’: ‘connect_boards5’, ‘title’: ‘Operator- old’, ‘value’: }
Traceback (most recent call last):
File “Populate_Operators.py”, line 72, in
row.change_column_value(column_value)
File “/home/nestlogic/.local/lib/python3.7/site-packages/moncli/entities/item.py”, line 909, in change_column_value
column_value = self.column_values[id]
File “/home/nestlogic/.local/lib/python3.7/site-packages/moncli/entities/base.py”, line 17, in getitem
return self._values[self._key(index)]
File “/home/nestlogic/.local/lib/python3.7/site-packages/moncli/entities/column.py”, line 94, in get_index
raise TypeError(‘Expected index type of int or str, got “{}” instead.’.format(index.class.name))
TypeError: Expected index type of int or str, got “ItemLinkValue” instead.

Please help!
Thanks!
KEREN

I also tried:

  itemlink_value = row.column_values['connect_boards5']
  itemlink_value.value = [23456789]
  row.change_column_value(itemlink_value)

raise TypeError('Expected index type of int or str, got "{}" instead.'.format(index.__class__.__name__))

TypeError: Expected index type of int or str, got “ItemLinkValue” instead.

Any ideas?
Thanks!
KEREN

In general I cannot use the function: (change_column_value):
column_value = row.column_values[‘test’]
print(column_value.value)
column_value.value=‘testing’
row.change_column_value(column_value)

TypeError: Expected index type of int or str, got “TextValue” instead.

Did you ever find a solution for this? i’m in the same boat right now!

I would abandon moncli

Monday changed the API with breaking changes at the end of 2023, and I don’t believe moncli has ever been updated. Its unlikely you will ever have success getting it to work properly at this point.

You should be able to use any graphql client for python (esp if you use the 2025-01 release candidate API version) instead. You will just have to write queries directly - but that gives you much more flexibility anyway.