Process for Trello automated backups AND restores of boards, cards, and card comments
Asked by Jennifer Leigh:

Our little start-up is using Trello for several mission critical functions. We just had a little scare with some minor data loss that pointed out how catastrophic it could be to lose a trello board, so I came to the site to find out how to pay you money for a robust backup solution.

I am stunned this doesn't seem to be a solved problem.

I'm looking at third party options and also at rolling our own backup/restore system, but want to be sure that I'm not missing something before I either pay someone else or put development cycles into a homebrew solution. We love your product and are prepared to pay for an official, supported solution. How is this not something that already exists? It's clear from the proliferation of git repositories and third party plug-ins that many people need this functionality.

Is there really no Atlassian supported backup AND restore solution for Trello boards?

Thanks!


Answers:
author: Mike Potter
body: Rewind now has support for Trello. You can sign up and start backing up and restoring Trello boards, cards and more at <https://rewind.com/products/backups/productivity/trello/>

Rewind has been trusted by over 80,000 businesses to protect their data, and is already protecting thousands of Trello boards.

comments: author: Dasha Shakov
body: Just a heads up to those who find this thread -- the [**Backups for Trello**](https://trello.com/power-ups/5f68db5b510db84238769710) Power-Up is now available in the Power-Up Marketplace.

Trello users can use it to run daily, automated backups of your Trello boards, lists, cards, and more. You can also run a backup any time if your team is making a lot of changes to a board or testing a new Power-Up.

If you have any questions, you can contact me directly at dasha@rewind.com.


author: Iain Dooley
body: [@Jennifer Leigh](/t5/user/viewprofilepage/user-id/1127276) this is a fantastic write up and example based on Google Apps Script/Sheets:

<http://www.littlebluemonkey.com/blog/trello-backup-30>

Ian's work has been the inspiration for all the automation stuff I do with Google Apps Script and Trello, and was the basis for Trellinator:

<https://trello.com/integrations/#trellinator>

Google Apps Script generally is a great match for creating Trello automations. The combination of Google and Trello is really powerful.

comments: author: Jennifer Leigh
body: That looks like an awesome backup system, but unless I'm missing something there's no restore functionality. I need both. :-)


author: Iain Dooley
body: [@Jennifer Leigh](/t5/user/viewprofilepage/user-id/1127276) yeah you'd need to extract the info you wanted -- his vibe there is more about disaster recovery for if Trello disappears.

If you wanted a solution to Backup Trello boards with easy restore, why not just use snapshots by copying the board?

There's no limit to the number of boards you can have, and you could rotate them out so you keep, say, hourly backups for the last 24 hours, then daily backups for the past 30 days or whatever frequency you needed.

Here's an example of using Trellinator to create hourly backups, with each backup board being linked to a card on a backup board for easy reference:

<https://gist.github.com/iaindooley/57127d008c8829168f17cc070da85bde>

You'd probably want to add some other functionality to group/organise the backups, clear old backups after they'd been around for a certain period, etc. etc. etc

You can see how to install Trellinator here:

<https://community.atlassian.com/t5/Marketplace-Apps-articles/Introducing-Trellinator-Automate-Trello-with-Google-Apps-Script/ba-p/925271>


author: Jennifer Leigh
body: We use search extensively, so this would multiply the number of results we would find. I saw this suggested solution as well.

I'm leaning towards setting up a backup server and running a script to take snapshots regularly through the API, with another script to find and restore in a disaster scenario. We already run occasional scripts through the API for process tasks, so this would be incremental development for us.


author: Iain Dooley
body: [@Jennifer Leigh](/t5/user/viewprofilepage/user-id/1127276) You only see search results on boards you're a member of. In the above case so long as each team member isn't added to the copied board they won't see any additional search results. The only member of the boards will be the Trellinator user itself


author: Jennifer Leigh
body: Hmm. Ok. I'll look into this solution more. Thanks!


author: shail
body: hello [@Jennifer Leigh](/t5/user/viewprofilepage/user-id/1127276)

did your team pull something together to be able to backup and restore?

---

if not, would this be a solution (using the API)?

* create a backup card with suitable name
* create all the lists in the source card
* copy cards from source board+list to backup board+list

There would still be a copy and that can mess up searches etc, but at least there is a full backup on Trello.


author: Jennifer Leigh
body: We have a backup through the API running, and are working on the restore.

Right now we would have to directly manipulate the database to get the data back out and create a replacement card/list/board, but it's all getting stored, so we're protected from a catastrophic loss. Eventually we will have enough of a front-end that our less techy data ingestion folks can recover lost things.

We're building it in python and it's a git project- when it gets running to our satisfaction we'll make the project public and I'll post a link here.

We also have a bunch of smaller tools for auto-generating tickets from a .csv and performing other manipulations on tickets shuffling them between boards based on what's in the description and/or what's in a .csv. We'll probably put it all out in the same project. :-)


author: shail
body: Looking forward to your sharing the project.

And thanks for the reply.


author: shail
body: [@Jennifer Leigh](/t5/user/viewprofilepage/user-id/1127276) pinging again as your "little" project would be immensely useful if you decide to share. :)

Thanks!


author: Jennifer Leigh
body: We realized that the tool as we conceived it would violate the Trello ToS, so we're trying to figure out what our next steps are. :-/

Really sucks that Atlassian has crippled trello this way.


author: shail
body: Oh no. That sounds terrible.

So I guess that means that you cannot even share your not suitable and incomplete code.

Can you share what sort of stuff would violate Trello ToS if one is backing up one's own data?

And thanks for the quick reply!


author: Jennifer Leigh
body: Atlassian offers (partial) backups as a paid service, and their API terms of use forbid duplicating paid services through use of the API. So we would have to create the full back-up/restore system as an augment on the paid back-ups solution, rather than as a stand alone system.

Since the paid backups are incomplete and would require parsing and augmenting, it's sort of daunting to look at.


author: Iain Dooley
body: [@Jennifer Leigh](/t5/user/viewprofilepage/user-id/1127276) the Trello developer terms only prevent you from charging for access to Trello or it's APIs, so you can't, for example, have a login that charges someone for creating a Trello account in the background or something, but it doesn't say anything about duplicating functionality someone might otherwise pay for:

<https://developers.trello.com/page/trello-developer-terms>


author: Jennifer Leigh
body: So if we develop a tool to back-up and restore boards and publish the source under the creative commons, that won't break the terms?

We've been exploring working with the Trello backups output and trying to build some sort of hybrid using that functionality, but it would be a lot easier if we didn't have to integrate against the Trello backups and could just work with the API and our own database.

We don't want to run afoul of the ToS and jeopardize our company's access, or face other repercussions.

Thanks!

-jennifer


author: Iain Dooley
body: [@Jennifer Leigh](/t5/user/viewprofilepage/user-id/1127276) well, I'm not a lawyer, but nothing in the terms for the Trello dev agreement would suggest that to me. Also, I created a project that replaces Butler which is now a paid feature of Trello and released as open source, and I post it all over the place here all the time and no-one has sent me a cease and desist letter. So do with that information what you will :)

Also note that this solution creates a total backup of the board, runs in G-Suite and consists of 11 lines of code:

<https://gist.github.com/iaindooley/57127d008c8829168f17cc070da85bde>

The only thing that it doesn't do is provide point in time backups in case of actual catastrophic loss of Trello itself. If you combined this with a basic JSON export of the board as a snapshot to cover the case in which you lose access to Trello you'd have a pretty solid solution.

Note that you'll probably also need something that removes boards/cards after a certain period of time.


author: Jennifer Leigh
body: The backup isn't the hard part, it's the restore that we're most interested in. We have backups happening, but right now would have to manually restore any lost content from them.

Our Trello process uses persistent cards (as in once created they are rarely destroyed/resolved/archived) that cycle through a monthly process, and we need the comment history and attachments to streamline the monthly processing. This exploration started when a new operator accidentally deleted attachments from a card, and we realized how vulnerable we were to that sort of error.

Thanks for your note! We're reactivating the project. :-)


author: shail
body: Looking forward to your project Jennifer, if you can post it for others to use!


author: Jennifer Leigh
body: If we get it working we'll definitely make it public!


author: Iain Dooley
body: [@Jennifer Leigh](/t5/user/viewprofilepage/user-id/1127276) if you copy a board periodically then your restore process is as simple as just moving a card or list from your backup board to your backed up board (or, if someone deleted the entire board accidentally, just add everyone to the most recent backup). This won't preserve all the actions or checklist states, but it will preserve all the data such as attachments, comments, title, description, labels, due dates. I guess if you want to preserve the order of actions, checklist item states and member assignments then you'd need a more sophisticated solution but protecting data is pretty trivial by just copying the board.


author: shail
body: [@Iain Dooley](/t5/user/viewprofilepage/user-id/1416112) This backup approach is also better than not having one.

Although one issue would be that the Trello search function would become even more difficult to use, with at least two of every search result...


author: Iain Dooley
body: [@shail](/t5/user/viewprofilepage/user-id/3064201) Trello only searches boards you're a member of. In this case, the only user that would need to be a member of those boards is your Trellinator account, so as long as it runs as it's own "bot" user (ie. don't put your personal API key/token into the configuration) the results won't show up. When you want to access your backups, just login as Trellinator and restore from there


author: shail
body: [@Iain Dooley](/t5/user/viewprofilepage/user-id/1416112) So I guess I will have to invite my "Trellinator account" to the private boards so that this account can access all the boards. Can do that and sounds like a good idea.

And just for confirmation - this Trellinator account will need to be an account that is created purely for such scripting purposes and this account will have to be invited to all of the boards that are to be copied, right?

Thank you for your help!


author: Iain Dooley
body: [@shail](/t5/user/viewprofilepage/user-id/3064201) yeah it's Trellinator that copies the boards, so it will already be a member of the boards that get created. You just need Trellinator to be a member of any board that needs to be backed up.

And yes I generally create a Trello account to be the "bot user".


author: Jennifer Leigh
body: [@Iain Dooley](/t5/user/viewprofilepage/user-id/1416112) we are doing daily backups into a database capturing all changes now, so the backup part is managed. We're a small enough team that we can just keep everything, so that part was straightforward. :-) The restore system and interface will be more involved, though!


author: Mike Potter
body: [@Jennifer Leigh](/t5/user/viewprofilepage/user-id/1127276) I'd love to talk to you about the backup solution that you built. I'm the CEO at Rewind, a cloud to cloud backup company, and we're working on a Trello backup \*and restore\* product. You can learn more about it at <https://rewind.io/backup/trello/>

If you've got time to talk on the phone about your backup tool, please email me at mike at rewind.io.

Thanks,  

Mike


author: Jennifer Leigh
body: We got a major contract in July, so no dev work has been put into this tool for months. Living without restore, and so far our data handling practices have been adequate, so we haven't needed to manually restore anything.

Thanks, though!

-jennifer


author: Jeremy Wong
body: Hi [@Jennifer Leigh](/t5/user/viewprofilepage/user-id/1127276)

I've developed a solution that both backs up and restores Trello boards.

Am I able to discuss this with you over email initially to get your feedback/thoughts?

Cheers,

Jeremy


Tags: backup

restore