Welcome to TrelloDotNet - a .NET wrapper of the Trello REST API.
- A TrelloClient for CRUD operations on most Trello features
- An Automation Engine and Webhook Data Reciver for handling Webhook Events from a Trello Board
- Install the 'TrelloDotNet' NuGet Package (dotnet add package TrelloDotNet)
- Retrieve your API-Key and Token
- Create new instance of the
TrelloClient
(located in namespace 'TrelloDotNet') - Locate you Ids of your Boards, List, and Cards (see video here or at the end on this ReadMe)
- Use the TrelloClient based on the examples below and/or the Wiki.
TrelloClient client = new TrelloDotNet.TrelloClient("APIKey", "TOKEN"); //IMPORTANT: Remember to NOT leave Key and Token in clear text!
//Get a board
Board board = await client.GetBoardAsync("<boardId>");
//Get Lists on a board
List<List> lists = await client.GetCardsOnBoardAsync("<boardId>");
//Get a card
Card card = await client.GetCardAsync("<cardId>");
//Get Cards on Board
List<Card> cardsOnBoard = await trelloClient.GetCardsOnBoardAsync("<boardId>");
//Get Cards in List
List<Card> cardsInList = await trelloClient.GetCardsInListAsync("<listId>");
//Add a card
Card input = new Card("<listId>", "My Card", "My Card description");
//todo - add more about the card
Card newCard = await client.AddCardAsync(input);
//Add a Checklist to a card
var checklistItems = new List<ChecklistItem>
{
new("ItemA"),
new("ItemB"),
new("ItemC")
};
Checklist newChecklist = new Checklist("Sample Checklist", checklistItems);
Checklist addedChecklist = await client.AddChecklistAsync("<cardId>", newChecklist);
- Trello Developer Fundamentals
- TrelloDotNet
- Wiki
- Changelog
- Report an issue
- Report a security concern
- TrelloDotNet Nuget Package
- Developers LinkedIn Group
- Power-Up to locate Ids
- Trello API YouTube Playlist
- Power-Ups Admin Center for API Keys and Tokens
- Trello API Documentation
- Trello Changelog
- How to build your first Power-Up
The easiest way to get Ids in Trello is to use this Power-Up to copy/paste them (Recommended)
Alternative use the share buttons in the project (require no Power-Up but more cumbersome)
The Export looks like this (search for id or use a tool to pretty-print the JSON to get a better view)
Have Fun :-)