7bae6154b84ac38e225e82780d2d3e7ecd7c2317
[video-tweet.git] / README.md
1 # Large Video Upload
2
3 This python sample demonstrates the following process of uploading large video files asynchronously with the Twitter API.
4
5 1. **INIT** media upload.
6 2. **APPEND** chunked data.
7 3. **FINALIZE** media uploaded.
8 4. Check **STATUS** of video processing.
9 5. Tweeting with attached video.
10
11 Large video files are longer than 30 second up to 140 seconds and/or a file size larger than 15 megabytes up to 512 megabytes.
12
13
14
15 ## Running the sample
16
17 1. Install requirements:
18
19 ```
20 $ pip install requirements.txt
21 ```
22
23 2. Fill in your consumer keys and access tokens in `async-upload.py`:
24
25 ```
26 CONSUMER_KEY = 'your-consumer-key'
27 CONSUMER_SECRET = 'your-consumer-secret'
28 ACCESS_TOKEN = 'your-access-token'
29 ACCESS_TOKEN_SECRET = 'your-access-secret'
30 ```
31
32 3. Run script:
33
34 ```
35 $ python async-upload.py
36 ```