14

I'm trying to compare Trello boards in order to highlight differences. You can easily download a board in JSON format from Trello by replacing the board's name with ".json" in the url:

http://trello.com/b/board_id_here.json

This requires you to be authenticated with Trello, however. Is there a way to get this exact JSON output directly out of the Trello API? There are ways of getting each of the child objects from the API, but I don't see a way to extract an entire JSON representation of the board and everything related to it.

Any help greatly appreciated!

Brian Tompsett - 汤莱恩
  • 5,753
  • 72
  • 57
  • 129
sillfishes
  • 390
  • 3
  • 9
  • 1
    Were you ever able to resolve this? I'm trying to do the same thing so I can work with it in Power BI and it's getting really frustrating. – SqlRyan Jul 13 '18 at 18:20

1 Answers1

7

That backup route is just a synonym for GETting /1/boards/board_id_here with the following parameters:

fields: "all"
actions: "all"
action_fields: "all"
actions_limit: 1000
cards: "all"
card_fields: "all"
card_attachments: true
labels: "all"
lists: "all"
list_fields: "all"
members: "all"
member_fields: "all"
checklists: "all"
checklist_fields: "all"
organization: false

Summing everything up in a cURL request*:

curl --location --request GET 'https://api.trello.com/1/boards/{{ BOARD_ID }}/?filters=all&actions=all&action_fields=all&actions_limit=1000&cards=all&card_fields=all&card_attachments=true&labels=all&lists=all&list_fields=all&members=all&member_fields=all&checklists=all&checklist_fields=all&organization=false' \
--header 'Content-Type: application/json' \
--data '{
  "key": "{{ KEY }}",
  "token": "{{ TOKEN }}"
}'
  • You can easily import and execute this request in POSTMAN: First, replace the 3 {{ dynamic }} variables with the Board ID, API KEY and TOKEN, then go to Import > Raw Text then paste the code above and execute.
Kostas Minaidis
  • 4,681
  • 3
  • 17
  • 25
Aaron Dufour
  • 17,288
  • 1
  • 47
  • 69
  • While this is correct, it appears that setting an `actions_limit` to anything higher than `1000` will result in a 400 error saying it's an invalid value provided for that field. – Michael Cox Mar 08 '18 at 13:58
  • Worth noting `customFields: true` and `card_customFieldItems: true` now also appear to be part of the "symlink". – maaarghk Mar 06 '19 at 20:06
  • 4
    For convenience, those URL parameters are `&fields=all&actions=all&action_fields=all&actions_limit=1000&cards=all&card_fields=all&card_attachments=true&labels=all&lists=all&list_fields=all&members=all&member_fields=all&checklists=all&checklist_fields=all&organization=false'` With api key: `curl 'https://api.trello.com/1/boards/?key=&token=&fields=all&actions=all&action_fields=all&actions_limit=1000&cards=all&card_fields=all&card_attachments=true&labels=all&lists=all&list_fields=all&members=all&member_fields=all&checklists=all&checklist_fields=all&organization=false'` – Holly Cummins Aug 14 '19 at 20:59