blob: a67ba8a6e62787ef83960a79f210470a2ba79785 [file] [log] [blame]
Joe Gregoriod67010d2012-11-05 08:57:06 -05001<html><body>
2<style>
3
4body, h1, h2, h3, div, span, p, pre, a {
5 margin: 0;
6 padding: 0;
7 border: 0;
8 font-weight: inherit;
9 font-style: inherit;
10 font-size: 100%;
11 font-family: inherit;
12 vertical-align: baseline;
13}
14
15body {
16 font-size: 13px;
17 padding: 1em;
18}
19
20h1 {
21 font-size: 26px;
22 margin-bottom: 1em;
23}
24
25h2 {
26 font-size: 24px;
27 margin-bottom: 1em;
28}
29
30h3 {
31 font-size: 20px;
32 margin-bottom: 1em;
33 margin-top: 1em;
34}
35
36pre, code {
37 line-height: 1.5;
38 font-family: Monaco, 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Lucida Console', monospace;
39}
40
41pre {
42 margin-top: 0.5em;
43}
44
45h1, h2, h3, p {
46 font-family: Arial, sans serif;
47}
48
49h1, h2, h3 {
50 border-bottom: solid #CCC 1px;
51}
52
53.toc_element {
54 margin-top: 0.5em;
55}
56
57.firstline {
58 margin-left: 2 em;
59}
60
61.method {
62 margin-top: 1em;
63 border: solid 1px #CCC;
64 padding: 1em;
65 background: #EEE;
66}
67
68.details {
69 font-weight: bold;
70 font-size: 14px;
71}
72
73</style>
74
75<h1><a href="youtube_v3.html">YouTube API</a> . <a href="youtube_v3.search.html">search</a></h1>
76<h2>Instance Methods</h2>
77<p class="toc_element">
78 <code><a href="#list">list(part, videoCaption=None, onBehalfOfContentOwner=None, pageToken=None, type=None, topicId=None, videoDimension=None, videoLicense=None, maxResults=None, videoDuration=None, videoDefinition=None, relatedToVideo=None, q=None, published=None, order=None)</a></code></p>
79<p class="firstline">Universal search for youtube.</p>
80<p class="toc_element">
81 <code><a href="#list_next">list_next(previous_request, previous_response)</a></code></p>
82<p class="firstline">Retrieves the next page of results.</p>
83<h3>Method Details</h3>
84<div class="method">
85 <code class="details" id="list">list(part, videoCaption=None, onBehalfOfContentOwner=None, pageToken=None, type=None, topicId=None, videoDimension=None, videoLicense=None, maxResults=None, videoDuration=None, videoDefinition=None, relatedToVideo=None, q=None, published=None, order=None)</code>
86 <pre>Universal search for youtube.
87
88Args:
89 part: string, Search result parts to include in the returned response. Valid values are: id and snippet. (required)
90 videoCaption: string, Add a filter on the the presence of captions on the videos.
91 Allowed values
92 any - No filter on the captions.
93 closedCaption - Videos with closed captions.
94 none - Videos without captions.
95 onBehalfOfContentOwner: string, The authenticated user acts on behalf of this content owner.
96 pageToken: string, Token for the page selection.
97 type: string, Type of resource to search.
98 topicId: string, Only search for resources with the specified topic
99 videoDimension: string, Add a filter for the number of dimensions in the videos.
100 Allowed values
101 2d - Videos in two dimensions.
102 3d - Videos in three dimensions.
103 any - No filter on the dimension.
104 videoLicense: string, Add a filter on the licensing of the videos.
105 Allowed values
106 any - No filter on the license.
107 creativeCommon - Videos under the Creative Common license.
108 youtube - Videos under the YouTube license.
109 maxResults: integer, Maximum number of search results to return per page.
110 videoDuration: string, Add a filter on the duration of the videos.
111 Allowed values
112 any - No filter on the duration.
113 long - Videos with a duration longer than 20 minutes.
114 medium - Videos with a duration between 4 and 20 minutes.
115 short - Videos with a duration under 4 minutes.
116 videoDefinition: string, Add a filter for the definition of the videos.
117 Allowed values
118 any - No filter on the definition.
119 high - Videos in high definition.
120 standard - Videos in standard definition.
121 relatedToVideo: string, Search for resources related to this video. Need to be used with type set to 'video'
122 q: string, Query to search in Youtube.
123 published: string, Only search for resources uploaded at a specific pediod
124 Allowed values
125 any - No filter on the release date
126 thisWeek - Videos uploaded this month
127 today - Videos uploaded today
128 order: string, Sort order.
129 Allowed values
130 date - Sort according to the date.
131 rating - Sort according to the rating.
132 relevance - Sort according to the relevance.
133 view_count - Sort according to the view count.
134
135Returns:
136 An object of the form:
137
138 { # A paginated list of search results returned as the response to a youtube.search.list call.
139 "nextPageToken": "A String", # Token to the next page.
140 "kind": "youtube#searchListResponse", # The type of this API response.
141 "items": [ # List of results matching the request criteria.
142 { # A search result contains information about a YouTube video, channel, or playlist that matches the search parameters specified in an API request.
143 "snippet": { # Basic details about a search result, including title, description and thumbnails of the item referenced by the search result. # Basic details about the search result: title, description, author.
144 "title": "A String", # Title of the found resource.
145 "channelId": "A String", # Channel publishing the found resource.
146 "description": "A String", # Description of the found resource.
147 "publishedAt": "A String", # Date and time the found resource was published at.
148 "thumbnails": { # Thumbnails for the found resource.
149 "a_key": { # A thumbnail is an image representing a YouTube resource. # A map of thumbnails by their name.
150 "url": "A String", # The URL for the thumbnail.
151 },
152 },
153 },
154 "kind": "youtube#searchResult", # The type of this API resource.
155 "etag": "A String", # The eTag of the search result.
156 "id": { # A resource id is a generic reference that points to another YouTube resource. # The id of the resource.
157 "kind": "A String", # The kind of the referred resource.
158 "channelId": "A String", # ID of the referred channel. Present only when type is "CHANNEL".
159 "playlistId": "A String", # ID of the referred playlist. Present only when type is "PLAYLIST".
160 "videoId": "A String", # ID of the referred video. Present only when type is "VIDEO".
161 },
162 },
163 ],
164 "etag": "A String", # The eTag of the response.
165 "prevPageToken": "A String", # Token to the previous page.
166 "pageInfo": { # Paging details for lists of resources, including total number of items available and number of resources returned in a single page. # Paging information for the search result.
167 "totalResults": 42, # The total number of results.
168 "resultsPerPage": 42, # The number of results to display for each page.
169 },
170 }</pre>
171</div>
172
173<div class="method">
174 <code class="details" id="list_next">list_next(previous_request, previous_response)</code>
175 <pre>Retrieves the next page of results.
176
177Args:
178 previous_request: The request for the previous page. (required)
179 previous_response: The response from the request for the previous page. (required)
180
181Returns:
182 A request object that you can call 'execute()' on to request the next
183 page. Returns None if there are no more items in the collection.
184 </pre>
185</div>
186
187</body></html>