def invite_user(self, user=github.GithubObject.NotSet, email=github.GithubObject.NotSet, role=github.GithubObject.NotSet, teams=github.GithubObject.NotSet):
        """
        :calls: `POST /orgs/:org/invitations <http://developer.github.com/v3/orgs/members>`_
        :param user: :class:`github.NamedUser.NamedUser`
        :param email: string
        :param role: string
        :param teams: array of :class:`github.Team.Team`
        :rtype: None
        """
        assert user is github.GithubObject.NotSet or isinstance(user, github.NamedUser.NamedUser), user
        assert email is github.GithubObject.NotSet or isinstance(email, (str, unicode)), email
        assert (email is github.GithubObject.NotSet) ^ (user is github.GithubObject.NotSet), "specify only one of email or user"
        parameters = {}
        if user is not github.GithubObject.NotSet:
            parameters["invitee_id"] = user.id
        elif email is not github.GithubObject.NotSet:
            parameters["email"] = email
        if role is not github.GithubObject.NotSet:
            assert isinstance(role, (str, unicode)), role
            assert role in ['admin', 'direct_member', 'billing_manager']
            parameters["role"] = role
        if teams is not github.GithubObject.NotSet:
            assert all(isinstance(team, github.Team.Team) for team in teams)
            parameters["team_ids"] = [t.id for t in teams]
        headers, data = self._requester.requestJsonAndCheck(
            "POST",
            self.url + "/invitations",
            headers={'Accept': Consts.mediaTypeOrganizationInvitationPreview},
            input=parameters
        )
:calls: `POST /orgs/:org/invitations <http://developer.github.com/v3/orgs/members>`_
        :param user: :class:`github.NamedUser.NamedUser`
        :param email: string
        :param role: string
        :param teams: array of :class:`github.Team.Team`
        :rtype: None