| Teams | R Documentation |
R6 Class representing teams resource endpoints.
sevenbridges2::Resource -> Teams
URLList of URL endpoints for this resource.
new()Create new Teams resource object.
Teams$new(...)
...Other response arguments.
query()This call retrieves a list of all teams in a division that you are a member of. Each team's ID and name will be returned.
Teams$query(division, list_all = FALSE, ...)
divisionThe string ID of the division or Division object you are querying.
list_allBoolean. Set this field to TRUE if you want to list
all teams within the division (regardless of whether you are a member
of a team or not). Default value is FALSE.
...Other arguments that can be passed to core api() function
like 'fields', etc.
A Collection of Team objects.
\dontrun{
# Retrieve a list of all teams within the division regardless of
# whether you are a member of a team or not
a$teams$query(division = "division-id", list_all = TRUE)
}
get()This call returns the details of a specified team. You can only get details of a team you are a member of.
Teams$get(id, ...)
idThe ID of the team you are querying. The function also accepts a Team object and extracts the ID.
...Other arguments that can be passed to core api() function
like 'fields', etc.
Team object.
\dontrun{
# Retrieve details of a specified team
a$teams$get(id = "team-id")
}
create()This call creates a new team within a specified division.
Teams$create(division, name)
divisionThe string ID of the division or Division object where you want to create a team.
nameEnter the name for the new team.
A Team object.
\dontrun{
# Create new team
a$teams$create(division = "division-id", name = "my-new-team")
}
delete()This call deletes a team. By deleting a team, you remove the users' membership to the team, but do not remove their accounts from the division.
Teams$delete(team, ...)
teamThe team ID or Team object that you want to delete.
...Other arguments that can be passed to core api() function.
\dontrun{
# Delete a team
a$teams$delete(team = "team-id")
}
clone()The objects of this class are cloneable with this method.
Teams$clone(deep = FALSE)
deepWhether to make a deep clone.
## ------------------------------------------------
## Method `Teams$query`
## ------------------------------------------------
## Not run:
# Retrieve a list of all teams within the division regardless of
# whether you are a member of a team or not
a$teams$query(division = "division-id", list_all = TRUE)
## End(Not run)
## ------------------------------------------------
## Method `Teams$get`
## ------------------------------------------------
## Not run:
# Retrieve details of a specified team
a$teams$get(id = "team-id")
## End(Not run)
## ------------------------------------------------
## Method `Teams$create`
## ------------------------------------------------
## Not run:
# Create new team
a$teams$create(division = "division-id", name = "my-new-team")
## End(Not run)
## ------------------------------------------------
## Method `Teams$delete`
## ------------------------------------------------
## Not run:
# Delete a team
a$teams$delete(team = "team-id")
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.