dillenmeister / trello.net Goto Github PK
View Code? Open in Web Editor NEWA .NET client library for Trello
A .NET client library for Trello
Any plan to add Wp8 and 8.1 support?
When the culture for the application is not set to en-US, the date is serialized wrong.
example: when the due date is set to 11 may 2012 when the cultrue is nl-BE, in Trello the due date for the card is set to 5 november 2012
so the serialization for Date has to be MM/dd/yyyy no matter what the culture is.
Kind regards,
Tom
Hey there, when I try to delete a card with an attachment, I get a null exception. If I run a loop removing the attachments first, it seems to work, but this seems like a clunky workaround. Is this a known issue? Any ideas what might be going wrong? Cards.Delete seems to work just fine when there are no attachments. Thanks, and let me know if you need any additional information.
This may be just my misunderstanding of how they are supposed to be working, but there isn't any real verbose documentation on it. Is so I apologize ahead of time.
I'm using the following code to get a list of actions that have happened on the board, what I'm looking for are only actions since the last time I queried (Since.LastView), or since the last time my app ran (Since.Date()).
IEnumerable<TrelloNet.Action> actList = t.Actions.ForBoard(new BoardId("50e5fcd7e1d97f0238000337"), since: Since.LastView);
foreach (TrelloNet.Action act in actList)
Console.WriteLine(act.Date.AddHours(-7));
This returns way more events than expected. The last change on the board was over 15 hours ago, and I'm getting 13 actions. So the question is what is Since.LastView using to determine what to return?
The next thing is that Actions times are UTC. I'm in Mountian Time (UTC -7), but using Since.Date(DateTime.UtcNow.AddMinutes(-1)) doesn't return something that was modified in the last minute. I made a change in Trello and then checked and had to do (-60) to get results. Is this a bug with the wrapper? with Trello?
Has anyone installed the Nuget package successively in a WP 7.1 solution? Is it possible?
Thanks
ITrello trello = new Trello("MyAppToken");
trello.Authorize("MyUserToken");
Member me = trello.Members.Me();
var cards = trello.Cards.ForMe();
var allboards = trello.Boards.ForMe();
So I got all my cards without any problems. But how can I get all my boards? It's always null and I don't understand what is the problem. My user and application tokens are valid.
My me object is not null and I have information about my account.
What did I miss? Thank you!
UPD: I can't even get board by board ID. I got the boardId from the card.
No issue from me - just wanted to heap some praise on you for developing this! Life saver! Thank you so so much :)
I've a board with a lot of cards. But I got every time null as a result in ....Async.Cards.ForBoard() only in this board from the organization. I guess I found the reason for this: it exists a card from a member created who is no more in the organization. When I deleted this card, the cards are fetched correctly.
I don't know, whether it is a bug in the api from trello. or in trello.net.
hi
I NEED HELP TO GET THE CARD CREATION DATE AND TIME
THANKS
The application terminated with an error.
Method not found: 'Void RestSharp.RestClient.AddDefaultParameter(System.String, System.Object)'
Looks like AddDefaultParameter has been deprecated.
dependencies set on >= 103.1 for install.
Right now Trello.NET only supports attachment links. Some of the other libs like python based Trolly supports file attachment upload. Can this be added?
After assigning a Member to Card I then call _trello.Actions.ForCard(new CardId()) and I do not see an Action of type AddMemberToCardAction. I do get back an array of Actions, but only of types UpdateCardMoveAction and CommentCardAction.
When I setup my own mock object of ITrello, I can build up an AddMemberToCardAction and it is returned in my unit tests, but when trying to hit the LIVE data on Trello, I never see the AddMemberToCardAction Action.
Please let me know if I'm doing something wrong or if there is a potential bug.
Thanks!
It looks like there hasn't been any development in several months, and I see that the Trello API supports webhooks, but I don't see any examples for webhooks with TrelloNet. I was just wondering if this project supports webhooks.
I am able to create a card with no issues. I am also able to add file attachments after the card is created. However, I am not able to assign a Label to a card through the API. I'm using the following method with no luck:
ITrello trelloAPI = new Trello(TrelloAppKey);
... authentication and whatnot...
trelloAPI.Cards.AddLabel(newCard, Color.Orange);
I place a breakpoint directly after the AddLabel method call and see no Labels in newCard, I also do not see the Label in the Trello board.
Any ideas?
I am noticing a long delay on some actions in Trello. Would be very helpful to support an async service call similar to Twitter:
IAsyncResult result = service.ListTweetsOnHomeTimeline(
(tweets, response) =>
{
if (response.StatusCode == HttpStatusCode.OK)
{
...
}
}
You can't get boards using this lib but his Edge version on Nuget works. Just letting you know in case you end up here like me after having issues getting it to work.
Trello have added pink, sky, lime and black to the labaleNames in the JSON representation these need to be added to TrelloNet.Color otherwise you get a serialization error of the form "Error converting value "pink" to type 'TrelloNet.Color'. Path '[23].labelNames.pink'"
Is there a way to invite members to a board or even just assign them as admins/users via the API? I'm trying to automate our project request system so that when a new project is approved a new Trello board is created and my team is assigned as admins to the board.
See: http://stackoverflow.com/questions/14345104/invite-members-to-board-with-trello-net
I may have to place each of these guys in a separate DLL, but just to log it. I reference (install) DropNet use it and it works. I reference (install) TrelloNet and I use it and it works. I then go back and try a DropNet call and it breaks. I re-install DropNet and it works. I go back and try a TrelloNet call and it breaks. It's our old friend AddDefaultParameter. Looks like DropNet is using RestSharp 102 and even though it states no dependencies that's what we have. I will post something at DropNet as well.
The application terminated with an error.
Method not found: 'Void RestSharp.RestClientExtensions.AddDefaultParameter(RestSharp.IRestClient, System.String, System.Object)'.
Hi,
Short questions; Iโm trying to inherit and extend the Trello.net objects (card, list etc), and then I would like to make a binary serialization to disk. But I see that the objects are not marked as serializable. Is there any workaround to make this possible?
/Erik (also from Sweden)
Hi,
Could you add support for the Pos property on both Checklist and CheckItem.
The Trello API doesn't seem to return them in the correct order and I am building an application which needs them to be in the same order as in Trello.
Thanks
Paul
Hi, I'm using a TrelloNet to create/edit cards, to add checklists...it's awesome!
But, trying to export all Json data from board, this json data resulted inside TrelloNet is very very smaller then a Json extracted in browser (using the SAME account, in browser as in Trellonet.)
One example is my principal board. at browser, it returns a 3.5 million caracters in json, but at Trellonet, the same board returns 8 thousand charcters.
Theres no observable restriction to the search in Trellonet request.
Somebody knows how to solve this? I need get the complete json information from board.
This is my actual code:
public TrelloNet.ITrello Trello { get; set; }
// .......some anether code
private Dictionary<string, string> GetJsonFromAllBoars(string organizationName)
{
Organization org = Trello.Organizations.WithId(organizationName);
var dic = new Dictionary<string, string>();
foreach (var item in Trello.Boards.ForOrganization(org))
{
//working on URL, then result the expected URI used in browser to get the json information
var url = item.Url.Substring(item.Url.IndexOf("/b/"), item.Url.LastIndexOf("/") - item.Url.IndexOf("/b/")) + ".json";
url = item.Url.Replace("https://trello.com", "");
// this is the point!!!!
dynamic json = Trello.Advanced.Get(url); // --> THIS JSON IS VERY SMALLER THEN THE OBTAINED IN BROWSER
// this is the point!!!!
dic.Add(item.Name, json.ToString());
}
return dic;
}
I tested Trello.NETs reaction on an offline async application, by unplugging my network cable. As result i got an AggregateException which was an effect of the in the title mentioned unhandled exception.
I debugged it myself:
In TrelloRestClient.RequestAsync
, the anon function gets a nulled response
argument, which causes a NullReferenceException in TrelloRestClient.ThrowIfRequestWasUnsuccessful
Maybe #27 is a effect of that one, too.
Hi,
I am getting this error:
Could not convert string 'sky' to dictionary key type 'TrelloNet.Color'. Create a TypeConverter to convert from the string to the key type object. Path '[0].labelNames.sky', line 1, position 1013.
Hi,
I'm getting this error when I try to get cards.fromboard. Could you please help
Message: ""
HResult: -2146233088
StackTrace:
at TrelloNet.Internal.TrelloRestClient.ThrowIfRequestWasUnsuccessful(IRestRequest request, IRestResponse response)
at TrelloNet.Internal.TrelloRestClient.Request[T](IRestRequest request)
at TrelloNet.Internal.Cards.ForBoard(IBoardId board, BoardCardFilter filter)
at TrelloNightbuild.Trello.RemoveRepeatedCards(BoardEnum board, String collection) in \TrelloTfs\Trello.Nightbuild.Sync\Workers\Trello.cs:line 333
at TrelloNightbuild.Program.Main(String[] args) in \TrelloTfs\Trello.Nightbuild.Sync\Program.cs:line 21
Thank you
No updates since 2014. Retrieving boards and cards don't work.
For your own sanity, don't go any further.
I noticed when i call for a card's actions that some of the actions are not present. Specifically the UpdateCheckItemStateOnCardAction is missing.
trello.Actions.ForCard(new Card(){Id="51bb62f0027d886426005f19"}).Dump();
link to method output:
http://bit.ly/17F4O4p
link to json data:
http://bit.ly/14clVWD
Maybe I am missing something, but this is the most active area in our site and I can't get access to it.
I want add a card with a customfield item, i don't find any function.
This isn't exactly an issue with the code, but more the documentation. Can you please provide and example on how to add a file attachment to a card. I tried looking at the test fixtures and they use static action ids. I don't know where the action id comes from.
Hi there,
I've tried a number of the examples from the wiki, and am unfortunately unable to get any usable data back from the API. I've debugged the request itself and can definitely see the raw JSON coming back, so maybe be an issue deserializing the response?
Simplified example:
var trello = new Trello(ConfigurationManager.AppSettings["TrelloAPIKey"]);
trello.Authorize(ConfigurationManager.AppSettings["TrelloAPIToken"]);
Board theTrelloDevBoard = trello.Boards.WithId("4d5ea62fd76aa1136000000c"); // null
The format the of the date used in the request to the Trello API is not formatted in a way that results are consistent.
I believe trello expects 2013-12-30T17:45:23.001Z (for Utc, for local replace Z with offset (ex -5:00)).
I tried to read a public board without prior authorization, but my call to
Trello trelloAPI = new Trello("<my API key>");
Board updateBoard = trelloAPI.Boards.WithId("5245a378c49bbb017d003a93");
only returns null.
When i add a AuthToken, Trello.NET returns the right object.
Its not the fault of the Trello API, i can fetch the JSON in my browser.
I installed Trello.NET via NuGet so i am not able to debug it myself. I'll pull the sources soon, but maybe you know a solution, that makes that process unnecessary.
Hi,
I really like the Trello API wrapper that you have built so far.
I'd love it if you were able to implement the trello search function - https://trello.com/docs/api/search/index.html#get-1-search
I spent some time looking at the source code to see if it would be easy for me to code the functionality and submit a pull request however it didn't seem very straightforward to me, not knowing your code base very well.
regards,
Paul.
hi
I WANT TO GET THE CARD CREATION DATE AND TIME.I need help from you.
Thanks
Trello.Cards.ChangePos(ICardId card, double pos)
PUT /1/cards/[card id or shortlink]/pos
Trello.Lists.ChangePos(IListId list, double pos)
PUT /1/lists/[idList]/pos
I've been using this library for months and all of the sudden my code is returning null for everything.
var trello = new Trello("[key]");
trello.Authorize("[token]");
var board = trello.Boards.WithId("[private board name]");
I've tried getting a new api key, generating a new token. Nothing works and every call I make returns null. Did something on Trello's end change? Any thoughts?
I've tried to copy a card from a list to another using the TrelloNet DLL, but i fink i did not do this in the best way that i can, so i want to know how i can do this?
Obs.: I tried to do this creating a card and simply creating another and attributing he to other card and putting the new card in another list.
Card card1 = new Card("Card1",MyList);
Card card2 = card1;
Trello.Net depends on RestSharp >= 104.1.0, but if you upgrade RestSharp to 105.2.3, you get the following exception:
System.MissingMethodException: Method was not found: 'Void RestSharp.RestClient.set_Authenticator(RestSharp.IAuthenticator)'.
at TrelloNet.Internal.TrelloRestClient.Authenticate(String memberToken)
at TrelloNet.Trello.Authorize(String token)
Trello.Net should either restrict its dependency on RestSharp, or upgrade to the latest version.
Calling Card.ForBoard()
returns that boad cards with the member null. Is it possible to get the Member info (at least id and name) on the same call?
The 'Getting started' link in the readme returns a 404 error.
More of a question than an issue.
It is possible through Trello.Net to pass through the optional parameters?
For example Trello.Lists.WithId() calls /lists/[id] - but I will like to also pass the optional "cards" parameter to retrieve all the cards at the same time.
My requirement would not be restricted to just the lists method, I would like to know if it is possible to do this for all methods?
Thanks
Paul
Attempting to use 0.5.5-beta (from NuGet) to move a Card from one Board to another.
Is this the correct method to use?
TrelloNet.Trello.Cards.SendToBoard(TrelloNet.Card)
If not, what is the correct method to Move a Card to a new Board? Where do you specify the BoardID to send the Card to?
Thanks
I try to use Newtonsoft.Json (5.0.3) but I can't install because TrelloNet used a older version (4.5.11).
Isn't Newtonsoft.Json in the dependency packages configured?
What in the name of the great lord cthulhu does that mean? - shouldn't one be sufficient?
Does anybody know how to fix this issue?
Hi,
Congratulations on such a great library. I'm trying to implement this stackoverflow question:
http://stackoverflow.com/questions/9812453/trello-api-determine-when-a-card-changed-lists
However, I think I need the listAfter or listBefore from the listUpdate actions and I can't find where this is. Do you have any suggestions on how to do this, or is this not yet implemented in the library?
Thanks!
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.