#NEWLINE# @ base . apimethod #NEWLINE# def invite( self , user , permission ) : #NEWLINE# #INDENT# '\n        Invite a user to participate in the repository, with the given\n        permissions.\n\n        :var user: The email of the user to invite.\n        :vartype user: str\n\n        :var permission: The permission to grant (either read or write)\n        :vartype permission: str\n        ' #NEWLINE# url = '{0}/invitations/{1}/{2}/{3}' . format ( self . parent . get_url ( ) , self . user , self . repo , permission ) #NEWLINE# params = base . get_params ( ( 'permission' , ) , locals ( ) ) #NEWLINE# request = http . Request ( 'POST' , url , params ) #NEWLINE# return ( request , parsers . parse_json )