I use the card cover to make it easier to identify and categorize requests within the board.
I found this post here on the forum, trying exactly the same thing as me, and @Dreamsuite Mike posted a solution.
HOW TO SET A COVER COLOR ON MY TRELLO CARD AUTOMATICALLY
But even following his step by step, several times, I couldn't get it to work... I managed to extract the API Keys and Tokens, but thats all.
Has anyone managed to replicate it? Was there a problem that you managed to get around? Thank you very much!
Hello @Marcelo _ MSocial Design e Mídias
If you search this forum for the topic 'automation cover color' you'll find this thread from waaayyy back in 2021, where I described step-by-step exactly how to set the cover color via the REST API using Trello automation.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Also, don't put actual square brackets around the key or token:
Those are used in the documentation as symbols to denote demarcation and are not supposed to be put in the automation text itself.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
It worked! Well, almost...
I managed to make the automation work with the fixed color, the one in the old thread you posted...
This one works normally for the fixed color:
URL - https://api.trello.com/1/cards/{cardid}
PAYLOAD - {"key" : "[your_rest_key_here]","token" : "[your_rest_token_here]","cover" : {"color" : "green","size" : "full" }}
But I couldn't, in any way, not even by making some adjustments with the help of ChatGPT (lol), make the version with the color corresponding to the label color work.
I get the error "There was an error requesting the URL..." and "400 Error parsing body:"
This is the one that doesn't work:
URL - https://api.trello.com/1/cards/{cardid}?key=[enteryourapikeyhere]&token=[enteryourtokenhere]
PAYLOAD - {\"cover\": {\"color\": \"{labelcolor}\", \"size\": \"normal\"}}
I tried to do a hybrid between the two:
URL - https://api.trello.com/1/cards/{cardid}
PAYLOAD - {"key" : "[your_rest_key_here]","token" : "[your_rest_token_here]","cover" : {"color" : "{labelcolor}","size" : "full" }}
But I got "400 {"message":"invalid cover color","error":"ERROR"}"
In short, for now, what I did was create several automations, one for each label/cover color.
Thanks for your help! If I see anything I might have done wrong, I'll try again with the version with the "{labelcolor}" variable.
Cheers!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
The cover color can only be set to 10 different colors, whereas labels can be set to 30 different colors:
Cover Color. Can be 'green', 'yellow', 'orange', 'red', 'purple', 'blue', 'sky', 'lime', 'pink' or 'black’.
Label Color. Can be 'green', 'yellow', 'orange', 'red', 'purple', 'blue', 'sky', 'lime', 'pink' or 'black', each of which can be suffixed with '_light' or '_dark' (ie. 'green', 'green_light' or 'green_dark' for a total of 30 possible colors)
... so the 20 light or dark label colors cannot be used for the cover color.
Also, I assume you are aware that {labelcolor} will only contain a value if the rule trigger was a new label being added to the card; otherwise, the smart value has no idea which specific label on the card you are referring to.
Lastly, it seems you're duplicating all these questions in another thread, so I'll stop adding to this thread.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.