Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to create video pins? #147

Open
jamesnfl opened this issue Jun 25, 2021 · 1 comment
Open

How to create video pins? #147

jamesnfl opened this issue Jun 25, 2021 · 1 comment
Labels
feature request feature request

Comments

@jamesnfl
Copy link

jamesnfl commented Jun 25, 2021

Hello,

i have a few video and i want a solution where we can upload those video as video pins.
video pins feature is only available for business users.

Is that possible to achieve that?

@sanind
Copy link

sanind commented Sep 29, 2021

I am also looking for this, is this possible?
Image upload works fine, but Video upload fails.

~.virtualenvs\Vidzy-ILdJulPR\lib\site-packages\py3pin\Pinterest.py in upload_pin(self, board_id, image_file, description, link, title, section_id)
462 This method is simmilar to 'pin' except the image for the pin is local file.
463 """
--> 464 image_url = self._upload_image(
465 image_file=image_file).json()['image_url']
466 return self.pin(board_id=board_id, description=description, image_url=image_url, link=link, title=title,

~.virtualenvs\Vidzy-ILdJulPR\lib\site-packages\py3pin\Pinterest.py in _upload_image(self, image_file)
500 }
501
--> 502 return self.post(url=UPLOAD_IMAGE, data=form_data, headers=headers)
503
504 def delete_pin(self, pin_id):

~.virtualenvs\Vidzy-ILdJulPR\lib\site-packages\py3pin\Pinterest.py in post(self, url, data, files, headers)
114
115 def post(self, url, data=None, files=None, headers=None):
--> 116 return self.request('POST', url=url, data=data, files=files, extra_headers=headers)
117
118 def login(self, headless=True, wait_time=15, proxy=None):

~.virtualenvs\Vidzy-ILdJulPR\lib\site-packages\py3pin\Pinterest.py in request(self, method, url, data, files, extra_headers)
106 response = self.http.request(
107 method, url, data=data, headers=headers, files=files, proxies=self.proxies)
--> 108 response.raise_for_status()
109
110 return response

~.virtualenvs\Vidzy-ILdJulPR\lib\site-packages\requests\models.py in raise_for_status(self)
951
952 if http_error_msg:
--> 953 raise HTTPError(http_error_msg, response=self)
954
955 def close(self):

HTTPError: 400 Client Error: Bad Request for url: https://www.pinterest.com/upload-image/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature request feature request
Projects
None yet
Development

No branches or pull requests

3 participants