示例#1
0
    def delete_contact(self, contact_id):
        """
        Delete single contact
        """
        url = self.CONTACTS_ID_URL % contact_id

        connection = Connection(self.token)
        connection.set_url(self.production, url)

        return connection.delete_request()
示例#2
0
    def delete_subscription(self, subscription_id):
        """
        Delete single subscription
        """
        url = self.SUBSCRIPTIONS_ID_URL % subscription_id

        connection = Connection(self.token)
        connection.set_url(self.production, url)

        return connection.delete_request()
示例#3
0
    def remove_manager_from_group(self, group_id, user_id):
        """
        Add a user to a group as a member
        :param group_id:
        :param user_id:
        """
        url = self.TEAM_MANAGERS_URL % (group_id, user_id)

        connection = Connection(self.token)
        connection.set_url(self.production, url)

        return connection.delete_request()
示例#4
0
    def delete_group(self, group_id):
        """
        Remove a group from your team
        :param group_id: Id of group
        """

        url = self.TEAM_GROUPS_ID_URL % group_id

        connection = Connection(self.token)
        connection.set_url(self.production, url)

        return connection.delete_request()
示例#5
0
    def remove_seat(self, seat_id):
        """
        Remove a seat from your team
        :param seat_id: Id of user
        """

        url = self.TEAM_SEATS_ID_URL % seat_id

        connection = Connection(self.token)
        connection.set_url(self.production, url)

        return connection.delete_request()
示例#6
0
    def remove_user(self, user_id):
        """
        Remove a user from your team
        :param user_id: Id of user
        """

        url = self.TEAM_USERS_ID_URL % user_id

        connection = Connection(self.token)
        connection.set_url(self.production, url)

        return connection.delete_request()