Trello API: getting boards / lists / cards information

前端 未结 5 1261
余生分开走
余生分开走 2021-02-03 22:12

Using Trello API: - I\'ve been able to get all the cards that are assigned to a Trello user - I\'ve been able to get all the boards that are assigned to an Organization

5条回答
  •  不思量自难忘°
    2021-02-03 23:00

    For the users who want the easiest way to access the id of a list :

    Use the ".json" hack !

    add ".json" at the end of your board URL to display the same output of the API query for that board, in your browser ! (no other tool needed, no hassle dealing with authentication).

    For instance, if the URL of your board is :

    https://trello.com/b/EI6aGV1d/blahblah
    

    point your browser to

    https://trello.com/b/EI6aGV1d/blahblah.json
    

    And you will obtain something like

    {
      "id": "5a69a1935e732f529ef0ad8e",
      "name": "blahblah",
      "desc": "",
      "descData": null,
      "closed": false,
      [...]
        "cards": [
          {
              "id": "5b2776eba95348dd45f6b745",
              "idMemberCreator": "58ef2cd98728a111e6fbd8d3",
              "data": {
                "list": {
                  "name": "Bla blah blah blah blah",
                  "id": "5a69a1b82f62a7af027d0378"
                },
                "board": {
                [...]
    

    Where you can just search for the name of your list to easily find its id next to it.

    tip: use a json viewer extension to make your browser display a nice json. Personnally I use https://github.com/tulios/json-viewer/tree/0.18.0 but I guess there are a lot of good alternatives out there.

提交回复
热议问题