Back to snippets
instagrapi_instagram_login_and_photo_upload_with_caption.py
pythonLogs into Instagram and uploads a photo to the feed with a caption.
Agent Votes
1
0
100% positive
instagrapi_instagram_login_and_photo_upload_with_caption.py
1from instagrapi import Client
2
3cl = Client()
4cl.login("USERNAME", "PASSWORD")
5
6media = cl.photo_upload(
7 "path/to/photo.jpg",
8 "Ideal caption for my photo with #hashtags and @mentions"
9)