Text

Learn how to filter by, read, update, and clear the text column on monday boards using the platform API

The text column contains any text you want to store in a column on your board(s). The API allows you to read, filter, update, and clear the text column.

🚧

Text column limit

The text column itself has no explicit character limit. However, each item has a column value limit of approximately 64KB.

Read a text column

You can query the text column using the column_values object that enables you to return column-specific subfields by sending a fragment in your query. Values for the text column are of the TextValue type.

query {
  items (ids:[1234567890, 9876543210]) {
    column_values {
      ... on TextValue {
        text
        value
      }
    }
  }
}

Fields

FieldDescription
column Column!The column the value belongs to.
id ID!The column's unique identifier.
text StringThe column's textual value. This field will return "" if the column has an empty value.
type ColumnType!The column's type.
value JSONThe column's JSON-formatted raw value.

Filter a text column

Using the items_page object, you can easily filter a board's items by specific columns or column values. The table below contains the text column's supported operators and compare values.

Operators

Compare Values

any_of

  • The whole text value to filter by
  • "" (blank values)

not_any_of

  • The whole text value to filter by
  • "" (blank values)

is_empty

[]

is_not_empty

[]

contains_text

The partial or whole text value to filter by

not_contains_text

The partial or whole text value to filter by

Examples

The following example returns all items on the specified board without an empty text column.

query {
  boards(ids: 1234567890) {
    items_page(
      query_params: {
        rules: [
          {
            column_id: "text"
            compare_value: [""]
            operator:not_any_of
          }
        ]
      }
	) {
      items {
        id
        name
      }
    }
  }
}

Update a text column

You can update a text column using the change_simple_column_value mutation and sending a simple string in the value argument. You can also use the change_multiple_column_values mutation and pass a JSON string in the column_values argument.

Simple strings

To update the text column, send a simple String value.

mutation {
  change_simple_column_value(
    item_id:9876543210
    board_id:1234567890
    column_id:"text"
    value: "Sample text"
	) {
    id
  }
}

JSON

To update the text column using JSON, send the value as a string.

mutation {
  change_multiple_column_values(
    item_id:9876543210
    board_id:1234567890
    column_values: "{\"text\" : \"Sample text\"}"
	) {
    id
  }
}

Clear a text column

You have two options to clear a text column. First, you can use the change_multiple_column_values mutation and pass null or an empty string in the column_values argument.

mutation {
  change_multiple_column_values(
    item_id:9876543210
    board_id:1234567890
    column_values: "{\"text\" : null}"
	) {
    id
  }
}

You can also use the change_simple_column_value mutation and pass an empty string in the value argument.

mutation {
  change_simple_column_value(
    item_id:9876543210
    board_id:1234567890
    column_id: "text"
    value: ""
	) {
    id
  }
}