def create(self, project, email, role, **attrs):
        """
        Create a new :class:`Membership`.

        :param project: :class:`Project` id
        :param email: email of the :class:`Membership`
        :param role: role of the :class:`Membership`
        :param attrs: optional attributes of the :class:`Membership`
        """
        attrs.update({'project': project, 'email': email, 'role': role})
        return self._new_resource(payload=attrs)
def create ( self , project , email , role , ** attrs ) : attrs . update ( { 'project' : project , 'email' : email , 'role' : role } ) return self . _new_resource ( payload = attrs )
Create a new :class:`Membership`.

        :param project: :class:`Project` id
        :param email: email of the :class:`Membership`
        :param role: role of the :class:`Membership`
        :param attrs: optional attributes of the :class:`Membership`