Roblox-trello | Object Oriented Trello API

roblox-trello v2.0.0 is being written right now. A new thread will be made after the first stable release. However, pre-release versions will be available in github prior to that.

More information available here:
v2 Project: Motivation and path



I created a OOP Trello API
I am actively developing and updating the API, so feel free to create a github issue if you want to report a bug, or request a feature.

The documentation can be found in the github’s wiki.

Here is an example of code:

local Trello = require(script.Parent.Trello.Main)

local myBoard = Trello:GetBoardByName("SomeBoard")
local newBoard = Trello.new("Board", "AnotherBoard")
for _,v in pairs (myBoard:GetLists()) do
	v:SetName(v:GetId()) --sets the name of every list to their own id
	v:Move(newBoard)  --moves all lists to the specified board
end

Another example:

game.Players.PlayerAdded:Connect(function(Plr)
    local MainBoard = Trello:GetBoardByName("Name of the board")
    local Fcard = MainBoard:GetCardByName(tostring(Plr.UserId))
    if Fcard then
        local newText = Fcard:GetDesc()
        --more code
    end
end)

I hope you like it! And please remember to give feedback either through a reply, or through a github issue. :smile:

License

image
This is free and unencumbered software released into the public domain.

Anyone is free to copy, modify, publish, use, compile, sell, or

distribute this software, either in source code form or as a compiled

binary, for any purpose, commercial or non-commercial, and by any

means.

In jurisdictions that recognize copyright laws, the author or authors

of this software dedicate any and all copyright interest in the

software to the public domain. We make this dedication for the benefit

of the public at large and to the detriment of our heirs and

successors. We intend this dedication to be an overt act of

relinquishment in perpetuity of all present and future rights to this

software under copyright law.

THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND,

EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF

MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.

IN NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY CLAIM, DAMAGES OR

OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,

ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR

OTHER DEALINGS IN THE SOFTWARE.

For more information, please refer to <http://unlicense.org>

Documentation

The documentation for the API can be found here:
Home · HypheX/roblox-trello Wiki · GitHub
The wiki always features the documentation for the latest version.

Change log

The change log and downloads can be found here:
Releases · HypheX/roblox-trello · GitHub

Featured projects

[Open Source] Fast-Flag System

102 Likes

Although I probably won’t use this, I just wanted to say this is good and to keep it up!

3 Likes

Nice API. I would suggest adding 1 thing: descriptions.
Currently there is no explanation what anything does. Adding just an 1 line description for every function would help alot.

3 Likes

The github page has a Wiki with all of the documentation.

1 Like

Oh sorry, I compleetly missed the Wiki button.:sweat_smile:

2 Likes

Don’t worry, it happens to the best of us. :smile:

2 Likes

What is this API for?
:thinking:

4 Likes

This API is made to interact with Trello via scripts using objects, hence the “Object Oriented” label.
Each object has a variety of functions (methods) available, all of which are listed on the Wiki of the github.

1 Like

This is fantastic, I can make use of this for players to report bugs, glitches and exploiters to my game’s private Trello board. Thanks a lot!

However, I want to know if there’s a throttle limit on the post interval on Trello’s backend?

2 Likes

Yeah even though I make my own APIs for things and won’t be using this. This looks great for new developers to use and build upon. :+1:

2 Likes

Thank you! I appreciate your feedback. :grinning:

And yes, Trello does throttle your requests, the following info was grabbed from their API docs.

To help prevent strain on Trello’s servers, our API imposes rate limits per API key for all issued tokens. There is a limit of 300 requests per 10 seconds for each API key and no more than 100 requests per 10 second interval for each token. If a request exceeds the limit, Trello will return a 429 error.

But still, it is very hard to reach the limit. You can send a request every 0.1 seconds, and still be within the limits by a thin margin.

2 Likes

This looks useful, I might look into using it for some sort of automated ban-list synchronises to a trello easily.

Thanks for the contribution! :+1:

3 Likes

Although I won’t use because I’ve already made my own.
I think that this is useful and great! This will sure help new developers. Thanks for sharing this and keep up the great work !

2 Likes

Important notice:
I received an amazing amount of reports of the script giving an error when attempting to create a new card.
I want to apologize to those that were affected by this error, as it took me way to long to fix it.

For those users that were affected by this bug, I have released version 1.1.2, which includes the hotfix for the error.

If you are currently using version 1.1.1, you should update to version 1.1.2.

2 Likes

This will be useful in my future projects. Good job!

3 Likes

How do you set the description when creating a card?

1 Like

Card:SetDesc(string) seems to be the function that does it, although it isn’t listed in the documentation.

2 Likes

Oh didn’t even knew that existed. Thanks! I just did Card:SetProperty("desc", description)

1 Like

I’d love if you add a List:Added() or a Card:Added() function! It’d be lovely for Cross-Server Messaging, Near Real-Time (Leaderboards(?)), etc, without the hassle of using Datastores, MessagingService, or other hacky ways around it!

I am currently working on a newer version, which will have a lot more features, which will include everything the Trello HTTP API has to offer.

I cannot promise a release time currently.