Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit8f4ba51

Browse files
author
Alex Schworer
committed
Update docs.
1 parent788f60a commit8f4ba51

File tree

4 files changed

+177
-131
lines changed

4 files changed

+177
-131
lines changed

‎docs/conf.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -48,9 +48,9 @@
4848
# built documents.
4949
#
5050
# The short X.Y version.
51-
version='0.5'
51+
version='0.6'
5252
# The full version, including alpha/beta/rc tags.
53-
release='0.5'
53+
release='0.6.3'
5454

5555
# The language for content autogenerated by Sphinx. Refer to documentation
5656
# for a list of supported languages.

‎docs/index.rst

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,10 +15,10 @@ Contents:
1515
zencoder
1616

1717
Introduction:
18-
`zencoder` is a Python module for theZencoder_ API
1918

20-
Source ishosted at github: http://github.com/schworer/zencoder-py
19+
`zencoder` isa Python module for the ZencoderAPI_. For Zencoder guides and API documentation, check out the official Zencoder docshere_.
2120

21+
Source is hosted at github: http://github.com/zencoder/zencoder-py
2222

2323
Indices and tables
2424
==================
@@ -27,5 +27,6 @@ Indices and tables
2727
*:ref:`modindex`
2828
*:ref:`search`
2929

30-
.. _Zencoder:http://zencoder.com/api
30+
.. _Zencoder API:https://app.zencoder.com/docs
31+
.. _here:https://app.zencoder.com/docs
3132

‎docs/usage.rst

Lines changed: 37 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -1,39 +1,41 @@
11
Usage
22
=====
33

4-
Here is some basic usage information::
5-
6-
import zencoder
7-
zen = zencoder.Zencoder()
8-
zen.jobs.list()
9-
10-
from zencoder import Zencoder
11-
zen = Zencoder('abc123') # enter your api key
12-
13-
# creates an encoding job with the defaults
14-
job = zen.job.create('http://input-file/movie.avi')
15-
print job.code
16-
print job.body
17-
print job.body['id']
18-
19-
# get the transcode progress of the first output
20-
progress = zen.output.progress(job.body['outputs'][0]['id'])
21-
print progress.body
22-
23-
24-
# configure your outputs with dictionaries
25-
iphone = {
26-
'label': 'iPhone',
27-
'url': 's3://output-bucket/output-file-1.mp4',
28-
'width': 480,
29-
'height': 320
30-
}
31-
web = {
32-
'label': 'web',
33-
'url': 's3://output-bucket/output-file.vp8',
34-
'video_codec':, 'vp8'
35-
}
36-
# the outputs kwarg requires an iterable
37-
outputs = (iphone, web)
38-
another_job = zen.job.create(input_url, outputs=outputs)
4+
Create an instance of `Zencoder`::
5+
6+
from zencoder import Zencoder
7+
zen = Zencoder('abc123') # enter your api key
8+
9+
Submit a job to Zencoder::
10+
11+
# creates an encoding job with the defaults
12+
job = zen.job.create('http://input-file/movie.avi')
13+
print job.code
14+
print job.body
15+
print job.body['id']
16+
17+
Return output progress::
18+
19+
# get the transcode progress of the first output
20+
progress = zen.output.progress(job.body['outputs'][0]['id'])
21+
print progress.body
22+
23+
Create a new job with multiple outputs::
24+
25+
# configure your outputs with dictionaries
26+
iphone = {
27+
'label': 'iPhone',
28+
'url': 's3://output-bucket/output-file-1.mp4',
29+
'width': 480,
30+
'height': 320
31+
}
32+
web = {
33+
'label': 'web',
34+
'url': 's3://output-bucket/output-file.vp8',
35+
'video_codec':, 'vp8'
36+
}
37+
38+
# the outputs kwarg requires an iterable
39+
outputs = (iphone, web)
40+
another_job = zen.job.create(input_url, outputs=outputs)
3941

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp