It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

Trello API search for cards with multi-word labels

Hello Community,

I'd like to ask about Trello API search options and possibilities. (https://developers.trello.com/reference#search-1)

I'm trying to search for specific Trello Cards which have multiple labels - if I choose labels, which are one-word long ('One', 'Two',..) it works fine, however problem is when  I try to search for cards which have multi-word labels (eg. 'All Clients', 'Something else',..). Passing multi-word label to search parameter causes the label to get truncated and only first word is used for search.

What I have tried so far:

  • Search query - unfortunately when using 'label:All clients' search would be performed for label:All - which is not correct

Other option would be to parse ALL Trello Board labels and use the label ID(s) to search for cards which have attached label with specific label ID(s).

Technically it's possible to load ALL cards, and filter the results by labelId, but is there really no other option to accomplish such task with the Trello API?

 

Thanks for any insights!

Tom

2 answers

1 accepted

0 votes
Answer accepted
Iain Dooley Community Leader Feb 04, 2019

@Tom Piešťanský If you want to do a multi word search you need to enclose the search term in double quotes eg.:

board:iaindooley label:"sales follow up"

Thank you for the answer@Iain Dooley, I remember trying single quotes, which did not work. Double quotes work like a charm. 

Thanks again!

Tom

Like # people like this

Is it possible to filter by multiple labels each one with multiple words?

In trello's site works OK. The URL is something like this:

https://trello.com/b/id/name?menu=filter&filter=label:i%20-%20one,label:s%20-%20two,label:a%20-%20three,mode:and

0 votes
marc Community Leader Feb 04, 2019

@Tom Piešťanskýwhat often helps is to encode a space with e.g. %20.  E.g. you example 'Something else' would become 'Something%20else'.  I have not tried this specifically for search in Trello, but it works in other cases in Trello.

Hi thanks for the reply, I have forgot to mention that I have tried that as well, unfortunately it did not work in this case.

Suggest an answer

Log in or Sign up to answer
TAGS
Community showcase
Published in Trello

Develop a new Habit during Lockdown

If you had to thrive a new habit during a lockdown, what would it be? Trello

1,631 views 15 7
Read article

Community Events

Connect with like-minded Atlassian users at free events near you!

Find an event

Connect with like-minded Atlassian users at free events near you!

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you