Skip to content

Instantly share code, notes, and snippets.

@object
Created September 28, 2015 11:38
Show Gist options
  • Save object/d335aac92e2d251aff1c to your computer and use it in GitHub Desktop.
Save object/d335aac92e2d251aff1c to your computer and use it in GitHub Desktop.
Trello: updating a card
Run(() =>
{
TrelloProcessor.WaitForPendingRequests = true;
var card = new Card("5609144868309d39826b61f1");
card.Name = "UPDATED: " + card.Name;
TrelloProcessor.Shutdown();
});
private static void Run(Action action)
{
var serializer = new ManateeSerializer();
TrelloConfiguration.Serializer = serializer;
TrelloConfiguration.Deserializer = serializer;
TrelloConfiguration.JsonFactory = new ManateeFactory();
//TrelloConfiguration.RestClientProvider = new RestSharpClientProvider();
TrelloConfiguration.RestClientProvider = new WebApiClientProvider();
TrelloAuthorization.Default.AppKey = authKey;
TrelloAuthorization.Default.UserToken = authToken;
TrelloConfiguration.ThrowOnTrelloError = true;
action();
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment