Trello API: Create card & add members?

Jono Hunt October 30, 2018
I've started using Trello's API to add cards to a list. I can add cards, due dates etc. without any problems.

I'm now trying to add members to cards (that are already members of the board) but can't find a way of doing it.

Here's what I've tried, but doesn't work:

https://api.trello.com/1/lists/<LIST_ID>/cards?name=Test_Card_02&amp;idMembers=jonohunt&amp;key=<MY_KEY>&amp;token=<MY_TOKEN>


This works fine (without trying to add a member):

https://api.trello.com/1/lists/<LIST_ID>/cards?name=Test_Card_01&amp;key=<MY_KEY>&amp;token=<MY_TOKEN>


I'm hoping it's something simple/easy to fix, either via the API or using the URL scheme instead 🙂

1 answer

0 votes

In the example that you gave, you used the member username. You need to use the member(s) ID(s).

 

https://api.trello.com/1/lists/<LIST_ID>/cards?name=Test_Card_02&amp;idMembers=<MEMBER1_ID>,<MEMBER2_ID>&amp;key=<MY_KEY>&amp;token=<MY_TOKEN>

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events