Trello Board button for admin/normal user only


I’m trying to figure out how to hide the board button for the observer type of user.

I have found it is possible to check memberType using rest api 1/board/{boardId}/memberships, but I think there should be an easier way.

Is checking ‘write’ user permissions in client.js the right way?


Or is there something even better, more obvious?

Thank you.

FWIW, I’ve ended up with condition: ‘edit’ in TrelloPowerUp.initialize, e.g.

  'board-buttons': function (t, opts) {
    return t.get('member', 'private', 'token')
      .then(function (token) {
        return [{
          condition: 'edit'