Use Butler to restore legacy link card behaviour
Asked by Pascal Raabe:

I used to be able to paste a URL to a Trello board and it would automatically create a card, pull the page title from the URL and set it as the card title, attach the URL as card attachment, pull the preview image from the URL and attach it as a card cover and pull the first few lines of text from the URL and set it as description. That used to be the standard behaviour when you paste a URL to a Trello list. It worked beautifully and the world was a happy place.

Now Trello is trying to be smart and introduced "link cards" which generate a special type of card with all the above. The problem is that a link card is literally just a link on the board with dynamic text and images. It means if the page content changes, so will the card. It also means it doesn't behave like any other Trello card. I can't can't add labels, comments, contributors or make any changes to the card. This is severely hampering my workflow.

I want the old behaviour, where the card functions like a card and I can add labels, comments etc. There's no way to turn off the annoying link cards feature so I was hoping I could use Butler to achieve the old behaviour but I'm already stuck at extracting the page title from the URL, let alone images etc.

I tried:

```
when the name of a card starts with "http", add the green "link" label to the card, add link "{cardname}", get url "\"{cardname}\"", and post comment "{httpresponse}"
```

It works insofar that it attaches the URL as a card attachment but I don't know how to get the page title and preview image.

I'm not a web developer, but I've tried my best. I'm stuck here. Please help.


Answers:
author: milynnus
body: [@Pascal Raabe](/t5/user/viewprofilepage/user-id/4699480)

This is my version of Trello legacy copy and paste of url on a card.

All it is needed is to have \>\> before the url.

<https://youtu.be/Mj5vUyZbujM>

comments: author: Pascal Raabe
body: Magic! That is exactly what I want! Can you share the Butler rules to achieve this please?


author: milynnus
body: [@Pascal Raabe](/t5/user/viewprofilepage/user-id/4699480)

The butler command is just to use http request to call an endpoint.

The 'magic' happens at the endpoint. It uses BeautifulSoup get the metadata from the cardname which is the \>\>http{\*} and it creates a new card inline and delete the trigger card.
> when a card with a name starting with "\>\>http{\*}" is added to the board, post to url "<https://xxxxxx.wayscript.io/runtest>" with payload "{"card_id" : "{triggercardidlong}"}"


author: Pascal Raabe
body: Amazing! So would I go about deploying that on my boards?


author: milynnus
body: [@Pascal Raabe](/t5/user/viewprofilepage/user-id/4699480)

My contact details are on my profile page. We can discuss this offline.


author: Pascal Raabe
body: I'm confused now. Why would we discuss this offline? Isn't that what this community is for?


author: milynnus
body: [@Pascal Raabe](/t5/user/viewprofilepage/user-id/4699480)

**Update: Reading your post carefully, I think you are referring on webpage url. Sorry. You can ignore the my post.**

I will have go at it later today. Will update this post.

comments: author: milynnus
body: [@Pascal Raabe](/t5/user/viewprofilepage/user-id/4699480)

Is this what you are looking for? If you copy and paste into a old card, that old card will be deleted but replace inline with the new card.

<https://youtu.be/IGVU7gF27XY>

**Update:**

I saw your comment about dynamic updates. The above implementation does have a

```
"cardSource":{"id":"6176b629....097c42a52",...
```

Which means you should be able to return to the card to get a new copy and insert in place if so required.


author: Felix
body: Hey [@Pascal Raabe](/t5/user/viewprofilepage/user-id/4699480)

there's unfortunately no easy way (without writing some code) to restore the old behavior, as far as I'm aware.

Link cards have replaced that functionality (previewing the link as a card). That said, we know folks like you (and me ?) who want to use labels/checklists/descriptions and other Trello features with Link Cards are out there. There's quite a few proposals floating around internally on how we can make that happen in a good way, and we're trying a bunch of stuff out.

comments: author: Michael Pryor
body: "I want the old behaviour, where the card functions like a card and I can add labels, comments etc."

This is what we intend to do. I don't have timing but your want is aligned with what we want as well.


author: Pascal Raabe
body: Thanks [@Felix](/t5/user/viewprofilepage/user-id/853253) and [@Michael Pryor](/t5/user/viewprofilepage/user-id/1131556)

I appreciate that you're working on improving link cards. It's a bummer for me also that link cards just update dynamically when the page content changes. I really liked having a snapshot in time when the link was added. This is useful for a number of use cases, e.g. real estate listings or ebay listings that tend to change or disappear after a while. I like to save content from a URL to Trello for safekeeping. I hope that link cards in the future will have the option to save a snapshot or be dynamic.


Tags: butler

link