Class: Team

TrelloEntities.Team(data)

The Team class represents a Team in Trello.

You will mostly deal with this as a return value from Member and Trellinator.

Constructor

new Team(data)

Parameters:
Name Type Description
data

(Object} key/value pairs of information, must at least contain "id", can basically just pass in response from Trello API

Source:
Example
new Trellinator().team("New Or Existing Team");

Methods

(static) this.addMember(email, full_name, type)

Add a member to this team, must be via email rather than by username (weirdly!)

Parameters:
Name Type Description
email string

the email of the person to invite

full_name string

full name for the person

type string

either "admin" or "normal", optional, default normal

Source:
Example
new Trellinator().team("Some Team").addMember("team@theprocedurepeople.com","Cool Folks","admin");

(static) this.board(name)

Return a board that is in this team filtered by name or regex, if more than one board matches the first will be returned

Parameters:
Name Type Description
name string | RegExp

the string or regex to match against the board names

Source:
Example
new Trellinator().team("My Team").boards().each(function(board)
{
    board.list("ToDo").cards().first().postComment("Me first!");
});

(static) this.boards(name)

Return an IterableCollection of boards that are in this team, filtered by string/regex

Parameters:
Name Type Description
name string | RegExp

a string or regex to match against board names

Source:
Example
new Trellinator().team("My Team").boards();

(static) this.del()

Remove this board

Source:
Example
new Trellinator().team("My Team").del();

(static) this.id()

Return the id of this Team

Source:
Example
new Trellinator().team("New Or Existing Team").id();

(static) this.name()

Return the name of this team

Source:
Example
new Trellinator().team("Name").name();