Hello,
I am currently developing a Trello Power-Up and would like to manage so-called "link cards".
https://support.atlassian.com/trello/docs/link-cards/
I can create cards with all different parameters, as referred in API section :
https://developer.atlassian.com/cloud/trello/rest/api-group-cards/#api-cards-post
BUT, I didn't find any way to make the card be a "link card" automatically at creation time.
And surprisingly, I found no difference in data returned by API, between normal cards and link cards...
Is there any way ?
Thanks :)
I think I found my answer : the card attribute in the API is "cardRole", can be set to "link" or "".
Seems to do the job ;-)
Now I understand your question and thanks for the information on “card role”
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @grub5
I'm not fully sure of your question but I will try to answer
The "connect cards" part of Trello is just a client side button that attaches the source card to the card you just attached...
You can do this also via the API...
You can determine if a card has attached trello cards by using /cards/{id}/attachments and filtering on the URL
You can also check by this attribute to see if there is a linked card, from Get a Card:
"badges":
{
"attachmentsByType":
{
"trello":
{
"board": 0,
"card": 1
}
}
}
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @Dreamsuite Mike ,
Thanks for your answer :).
The feature I was referring to is when you just paste an URL in a Trello card (ex. Youtube video), and Trello automatically transform it as a "link card".
Such "link card" displays a preview of the content as cover (ex. Youtube video caption), and the card become clickable.
This is described as a different "card type" in documentation, rather than as a card property : https://support.atlassian.com/trello/docs/card-types/
I guess my question would be : is there a way to get/update the card type with the API (separator, link card, ...) ?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Sorry, I misunderstood and thought it was to do with linked cards...
Link cards I am sure is a client-side action and thus isn't part of the API. However, so long as cards created by the API are supported as smartlinks, the client side will process them.
There is no card-type attribute as part of the API
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
But if you are referring to ‘card’ created when you copy and paste a url it creates a link to the target and when convert it to a card, it will be just another card with the card name being the url. I believed the link card is managed by Trello app itself.
Each card has a card url and you can access the card via the url (or the shortUrl) from within Trello. So if you are referring to two cards as linked then each of them has in their attachment the url of the linked card.
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.