Require name parameter for API.create_list
authorHarmon <Harmon758@gmail.com>
Sun, 14 Feb 2021 06:30:53 +0000 (00:30 -0600)
committerHarmon <Harmon758@gmail.com>
Sun, 14 Feb 2021 06:30:53 +0000 (00:30 -0600)
tweepy/api.py

index 2a463744f38311933b7aaa58626d74475f6cc0bc..0344c61b78f95330bda18a53e8b68abcc19600d7 100644 (file)
@@ -893,11 +893,11 @@ class API:
         return self.request('POST', f'saved_searches/destroy/{id}', **kwargs)
 
     @payload('list')
-    def create_list(self, *args, **kwargs):
+    def create_list(self, name, *args, **kwargs):
         """ :reference: https://developer.twitter.com/en/docs/accounts-and-users/create-manage-lists/api-reference/post-lists-create
         """
         return self.request(
-            'POST', 'lists/create', *args, endpoint_parameters=(
+            'POST', 'lists/create', name, *args, endpoint_parameters=(
                 'name', 'mode', 'description'
             ), **kwargs
         )