TeamMembershipClient

public class TeamMembershipClient

An iOS client wrapper of the Cisco Webex TeamMemberships REST API .

Since

1.2.0
  • Lists all team memberships where the authenticated user belongs.

    Since

    1.2.0

    Declaration

    Swift

    public func list(teamId: String, max: Int? = nil, queue: DispatchQueue? = nil, completionHandler: @escaping (Result<[TeamMembership]>) -> Void)

    Parameters

    teamId

    Limit results to a specific team, by ID. (Derived parameter: Use TeamClient.list(...) to get a list of teams. Then use Team.id to retrieve the teamId)

    max

    The maximum number of team memberships in the response.

    queue

    The queue on which the completion handler is dispatched.

    completionHandler

    A closure to be executed once the request has finished.

    Return Value

    Void

  • Adds a person to a team by person id; optionally making the person a moderator of the team.

    Since

    1.2.0

    Declaration

    Swift

    public func create(teamId: String, personId: String, isModerator: Bool = false, queue: DispatchQueue? = nil, completionHandler: @escaping (Result<TeamMembership>) -> Void)

    Parameters

    teamId

    The identifier of the team. (Derived parameter: Use TeamClient.list(...) to get a list of teams. Then use Team.id to retrieve the teamId)

    personId

    The identifier of the person. (Derived parameter: Use MembershipClient.list(...) to get the list of members. Then use Membership.personId to get the personId of the member)

    isModerator

    If true, make the person a moderator of the team. The default is false.

    queue

    The queue on which the completion handler is dispatched.

    completionHandler

    A closure to be executed once the request has finished.

    Return Value

    TeamMembership

  • Add a person to a teams by email address; optionally making the person a moderator of the team.

    Since

    1.2.0

    Declaration

    Swift

    public func create(teamId: String, personEmail: EmailAddress, isModerator: Bool = false, queue: DispatchQueue? = nil, completionHandler: @escaping (Result<TeamMembership>) -> Void)

    Parameters

    teamId

    The identifier of the team. (Derived parameter: Use TeamClient.list(...) to get a list of teams. Then use Team.id to retrieve the teamId)

    personEmail

    The email address of the person. (Derived parameter: Use MembershipClient.list(...) to get the list of members. Then use Membership.personEmail to get the email address of the member)

    isModerator

    If true, make the person a moderator of the team. The default is false.

    queue

    The queue on which the completion handler is dispatched.

    completionHandler

    A closure to be executed once the request has finished.

    Return Value

    Void

  • Retrieves the details for a membership by id.

    Since

    1.2.0

    Declaration

    Swift

    public func get(membershipId: String, queue: DispatchQueue? = nil, completionHandler: @escaping (Result<TeamMembership>) -> Void)

    Parameters

    membershipId

    The identifier of the membership. (Derived parameter: Use TeamMembershipClient.list(...) to get the list of team memberships. Then use TeamMembership.id to retrieve the membershipId)

    queue

    The queue on which the completion handler is dispatched.

    completionHandler

    A closure to be executed once the request has finished.

    Return Value

    Void

  • Updates the details for a membership by id.

    Since

    1.2.0

    Declaration

    Swift

    public func update(membershipId: String, isModerator: Bool, queue: DispatchQueue? = nil, completionHandler: @escaping (Result<TeamMembership>) -> Void)

    Parameters

    membershipId

    The identifier of the membership. (Derived parameter: Use TeamMembershipClient.list(...) to get the list of team memberships. Then use TeamMembership.id to retrieve the membershipId)

    isModerator

    If true, make the person a moderator of the team. The default is false.

    queue

    The queue on which the completion handler is dispatched.

    completionHandler

    A closure to be executed once the request has finished.

    Return Value

    Void

  • Deletes a membership by id.

    Since

    1.2.0

    Declaration

    Swift

    public func delete(membershipId: String, queue: DispatchQueue? = nil, completionHandler: @escaping (Result<Void>) -> Void)

    Parameters

    membershipId

    The identifier of the membership. (Derived parameter: Use TeamMembershipClient.list(...) to get the list of team memberships. Then use TeamMembership.id to retrieve the membershipId)

    queue

    The queue on which the completion handler is dispatched.

    completionHandler

    A closure to be executed once the request has finished.

    Return Value

    Void