Joe Gregorio | 075572b | 2012-07-09 16:53:09 -0400 | [diff] [blame] | 1 | <html><body> |
| 2 | <style> |
| 3 | |
| 4 | body, 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 | |
| 15 | body { |
| 16 | font-size: 13px; |
| 17 | padding: 1em; |
| 18 | } |
| 19 | |
| 20 | h1 { |
| 21 | font-size: 26px; |
| 22 | margin-bottom: 1em; |
| 23 | } |
| 24 | |
| 25 | h2 { |
| 26 | font-size: 24px; |
| 27 | margin-bottom: 1em; |
| 28 | } |
| 29 | |
| 30 | h3 { |
| 31 | font-size: 20px; |
| 32 | margin-bottom: 1em; |
| 33 | margin-top: 1em; |
| 34 | } |
| 35 | |
| 36 | pre, code { |
| 37 | line-height: 1.5; |
| 38 | font-family: Monaco, 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Lucida Console', monospace; |
| 39 | } |
| 40 | |
| 41 | pre { |
| 42 | margin-top: 0.5em; |
| 43 | } |
| 44 | |
| 45 | h1, h2, h3, p { |
| 46 | font-family: Arial, sans serif; |
| 47 | } |
| 48 | |
| 49 | h1, 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="discovery_v1.html">APIs Discovery Service</a> . <a href="discovery_v1.apis.html">apis</a></h1> |
| 76 | <h2>Instance Methods</h2> |
| 77 | <p class="toc_element"> |
| 78 | <code><a href="#getRest">getRest(api, version)</a></code></p> |
| 79 | <p class="firstline">Retrieve the description of a particular version of an api.</p> |
| 80 | <p class="toc_element"> |
| 81 | <code><a href="#list">list(name=None, preferred=None, label=None)</a></code></p> |
| 82 | <p class="firstline">Retrieve the list of APIs supported at this endpoint.</p> |
| 83 | <h3>Method Details</h3> |
| 84 | <div class="method"> |
| 85 | <code class="details" id="getRest">getRest(api, version)</code> |
| 86 | <pre>Retrieve the description of a particular version of an api. |
| 87 | |
| 88 | Args: |
| 89 | api: string, The name of the API. (required) |
| 90 | version: string, The version of the API. (required) |
| 91 | |
| 92 | Returns: |
| 93 | An object of the form: |
| 94 | |
| 95 | { |
| 96 | "protocol": "rest", # The protocol described by this document. |
| 97 | "methods": { # API-level methods for this API. |
Joe Gregorio | fa08c2e | 2012-07-23 16:52:03 -0400 | [diff] [blame^] | 98 | "a_key": { # An individual method description. |
| 99 | "scopes": [ # OAuth 2.0 scopes applicable to this method. |
| 100 | "", |
| 101 | ], |
| 102 | "description": "A String", # Description of this method. |
| 103 | "parameters": { # Details for all parameters in this method. |
| 104 | "a_key": { # Details for a single parameter in this method. |
| 105 | "properties": { # If this is a schema for an object, list the schema for each property of this object. |
| 106 | "a_key": # Object with schema name: JsonSchema # A single property of this object. The value is itself a JSON Schema object describing this property. |
| 107 | }, |
| 108 | "required": True or False, # Whether the parameter is required. |
| 109 | "type": "A String", # The value type for this schema. A list of values can be found here: http://tools.ietf.org/html/draft-zyp-json-schema-03#section-5.1 |
| 110 | "description": "A String", # A description of this object. |
| 111 | "format": "A String", # An additional regular expression or key that helps constrain the value. For more details see: http://tools.ietf.org/html/draft-zyp-json-schema-03#section-5.23 |
| 112 | "default": "A String", # The default value of this property (if one exists). |
| 113 | "items": # Object with schema name: JsonSchema # If this is a schema for an array, this property is the schema for each element in the array. |
| 114 | "enum": [ # Values this parameter may take (if it is an enum). |
| 115 | "A String", |
| 116 | ], |
| 117 | "maximum": "A String", # The maximum value of this parameter. |
| 118 | "id": "A String", # Unique identifier for this schema. |
| 119 | "enumDescriptions": [ # The descriptions for the enums. Each position maps to the corresponding value in the "enum" array. |
| 120 | "A String", |
| 121 | ], |
| 122 | "minimum": "A String", # The minimum value of this parameter. |
| 123 | "location": "A String", # Whether this parameter goes in the query or the path for REST requests. |
| 124 | "pattern": "A String", # The regular expression this parameter must conform to. |
| 125 | "additionalProperties": # Object with schema name: JsonSchema # If this is a schema for an object, this property is the schema for any additional properties with dynamic keys on this object. |
| 126 | "repeated": True or False, # Whether this parameter may appear multiple times. |
| 127 | "annotations": { # Additional information about this property. |
| 128 | "required": [ # A list of methods for which this property is required on requests. |
| 129 | "A String", |
| 130 | ], |
| 131 | }, |
| 132 | "$ref": "A String", # A reference to another schema. The value of this property is the "id" of another schema. |
| 133 | }, |
| 134 | }, |
| 135 | "supportsMediaUpload": True or False, # Whether this method supports media uploads. |
| 136 | "request": { # The schema for the request. |
| 137 | "$ref": "A String", # Schema ID for the request schema. |
| 138 | }, |
| 139 | "mediaUpload": { # Media upload parameters. |
| 140 | "maxSize": "A String", # Maximum size of a media upload, such as "1MB", "2GB" or "3TB". |
| 141 | "protocols": { # Supported upload protocols. |
| 142 | "simple": { # Supports uploading as a single HTTP request. |
| 143 | "path": "A String", # The URI path to be used for upload. Should be used in conjunction with the basePath property at the api-level. |
| 144 | "multipart": true, # True if this endpoint supports upload multipart media. |
| 145 | }, |
| 146 | "resumable": { # Supports the Resumable Media Upload protocol. |
| 147 | "path": "A String", # The URI path to be used for upload. Should be used in conjunction with the basePath property at the api-level. |
| 148 | "multipart": true, # True if this endpoint supports uploading multipart media. |
| 149 | }, |
| 150 | }, |
| 151 | "accept": [ # MIME Media Ranges for acceptable media uploads to this method. |
| 152 | "A String", |
| 153 | ], |
| 154 | }, |
| 155 | "response": { # The schema for the response. |
| 156 | "$ref": "A String", # Schema ID for the response schema. |
| 157 | }, |
| 158 | "httpMethod": "A String", # HTTP method used by this method. |
| 159 | "supportsSubscription": True or False, # Whether this method supports subscriptions. |
| 160 | "parameterOrder": [ # Ordered list of required parameters, serves as a hint to clients on how to structure their method signatures. The array is ordered such that the "most-significant" parameter appears first. |
| 161 | "A String", |
| 162 | ], |
| 163 | "path": "A String", # The URI path of this REST method. Should be used in conjunction with the basePath property at the api-level. |
| 164 | "id": "A String", # A unique ID for this method. This property can be used to match methods between different versions of Discovery. |
| 165 | "supportsMediaDownload": True or False, # Whether this method supports media downloads. |
| 166 | }, |
Joe Gregorio | 075572b | 2012-07-09 16:53:09 -0400 | [diff] [blame] | 167 | }, |
| 168 | "labels": [ # Labels for the status of this API, such as labs or deprecated. |
| 169 | "A String", |
| 170 | ], |
| 171 | "batchPath": "batch", # The path for REST batch requests. |
| 172 | "id": "A String", # The id of this API. |
| 173 | "schemas": { # The schemas for this API. |
Joe Gregorio | fa08c2e | 2012-07-23 16:52:03 -0400 | [diff] [blame^] | 174 | "a_key": { # An individual schema description. |
| 175 | "properties": { # If this is a schema for an object, list the schema for each property of this object. |
| 176 | "a_key": # Object with schema name: JsonSchema # A single property of this object. The value is itself a JSON Schema object describing this property. |
| 177 | }, |
| 178 | "required": True or False, # Whether the parameter is required. |
| 179 | "type": "A String", # The value type for this schema. A list of values can be found here: http://tools.ietf.org/html/draft-zyp-json-schema-03#section-5.1 |
| 180 | "description": "A String", # A description of this object. |
| 181 | "format": "A String", # An additional regular expression or key that helps constrain the value. For more details see: http://tools.ietf.org/html/draft-zyp-json-schema-03#section-5.23 |
| 182 | "default": "A String", # The default value of this property (if one exists). |
| 183 | "items": # Object with schema name: JsonSchema # If this is a schema for an array, this property is the schema for each element in the array. |
| 184 | "enum": [ # Values this parameter may take (if it is an enum). |
| 185 | "A String", |
| 186 | ], |
| 187 | "maximum": "A String", # The maximum value of this parameter. |
| 188 | "id": "A String", # Unique identifier for this schema. |
| 189 | "enumDescriptions": [ # The descriptions for the enums. Each position maps to the corresponding value in the "enum" array. |
| 190 | "A String", |
| 191 | ], |
| 192 | "minimum": "A String", # The minimum value of this parameter. |
| 193 | "location": "A String", # Whether this parameter goes in the query or the path for REST requests. |
| 194 | "pattern": "A String", # The regular expression this parameter must conform to. |
| 195 | "additionalProperties": # Object with schema name: JsonSchema # If this is a schema for an object, this property is the schema for any additional properties with dynamic keys on this object. |
| 196 | "repeated": True or False, # Whether this parameter may appear multiple times. |
| 197 | "annotations": { # Additional information about this property. |
| 198 | "required": [ # A list of methods for which this property is required on requests. |
| 199 | "A String", |
| 200 | ], |
| 201 | }, |
| 202 | "$ref": "A String", # A reference to another schema. The value of this property is the "id" of another schema. |
| 203 | }, |
Joe Gregorio | 075572b | 2012-07-09 16:53:09 -0400 | [diff] [blame] | 204 | }, |
| 205 | "rootUrl": "A String", # The root url under which all API services live. |
| 206 | "parameters": { # Common parameters that apply across all apis. |
Joe Gregorio | fa08c2e | 2012-07-23 16:52:03 -0400 | [diff] [blame^] | 207 | "a_key": { # Description of a single parameter. |
| 208 | "properties": { # If this is a schema for an object, list the schema for each property of this object. |
| 209 | "a_key": # Object with schema name: JsonSchema # A single property of this object. The value is itself a JSON Schema object describing this property. |
| 210 | }, |
| 211 | "required": True or False, # Whether the parameter is required. |
| 212 | "type": "A String", # The value type for this schema. A list of values can be found here: http://tools.ietf.org/html/draft-zyp-json-schema-03#section-5.1 |
| 213 | "description": "A String", # A description of this object. |
| 214 | "format": "A String", # An additional regular expression or key that helps constrain the value. For more details see: http://tools.ietf.org/html/draft-zyp-json-schema-03#section-5.23 |
| 215 | "default": "A String", # The default value of this property (if one exists). |
| 216 | "items": # Object with schema name: JsonSchema # If this is a schema for an array, this property is the schema for each element in the array. |
| 217 | "enum": [ # Values this parameter may take (if it is an enum). |
| 218 | "A String", |
| 219 | ], |
| 220 | "maximum": "A String", # The maximum value of this parameter. |
| 221 | "id": "A String", # Unique identifier for this schema. |
| 222 | "enumDescriptions": [ # The descriptions for the enums. Each position maps to the corresponding value in the "enum" array. |
| 223 | "A String", |
| 224 | ], |
| 225 | "minimum": "A String", # The minimum value of this parameter. |
| 226 | "location": "A String", # Whether this parameter goes in the query or the path for REST requests. |
| 227 | "pattern": "A String", # The regular expression this parameter must conform to. |
| 228 | "additionalProperties": # Object with schema name: JsonSchema # If this is a schema for an object, this property is the schema for any additional properties with dynamic keys on this object. |
| 229 | "repeated": True or False, # Whether this parameter may appear multiple times. |
| 230 | "annotations": { # Additional information about this property. |
| 231 | "required": [ # A list of methods for which this property is required on requests. |
| 232 | "A String", |
| 233 | ], |
| 234 | }, |
| 235 | "$ref": "A String", # A reference to another schema. The value of this property is the "id" of another schema. |
| 236 | }, |
Joe Gregorio | 075572b | 2012-07-09 16:53:09 -0400 | [diff] [blame] | 237 | }, |
| 238 | "icons": { # Links to 16x16 and 32x32 icons representing the API. |
| 239 | "x32": "A String", # The url of the 32x32 icon. |
| 240 | "x16": "A String", # The url of the 16x16 icon. |
| 241 | }, |
| 242 | "baseUrl": "A String", # [DEPRECATED] The base URL for REST requests. |
| 243 | "version": "A String", # The version of this API. |
| 244 | "features": [ # A list of supported features for this API. |
| 245 | "A String", |
| 246 | ], |
| 247 | "servicePath": "A String", # The base path for all REST requests. |
| 248 | "resources": { # The resources in this API. |
Joe Gregorio | fa08c2e | 2012-07-23 16:52:03 -0400 | [diff] [blame^] | 249 | "a_key": { # An individual resource description. Contains methods and sub-resources related to this resource. |
| 250 | "methods": { # Methods on this resource. |
| 251 | "a_key": { # Description for any methods on this resource. |
| 252 | "scopes": [ # OAuth 2.0 scopes applicable to this method. |
| 253 | "", |
| 254 | ], |
| 255 | "description": "A String", # Description of this method. |
| 256 | "parameters": { # Details for all parameters in this method. |
| 257 | "a_key": { # Details for a single parameter in this method. |
| 258 | "properties": { # If this is a schema for an object, list the schema for each property of this object. |
| 259 | "a_key": # Object with schema name: JsonSchema # A single property of this object. The value is itself a JSON Schema object describing this property. |
| 260 | }, |
| 261 | "required": True or False, # Whether the parameter is required. |
| 262 | "type": "A String", # The value type for this schema. A list of values can be found here: http://tools.ietf.org/html/draft-zyp-json-schema-03#section-5.1 |
| 263 | "description": "A String", # A description of this object. |
| 264 | "format": "A String", # An additional regular expression or key that helps constrain the value. For more details see: http://tools.ietf.org/html/draft-zyp-json-schema-03#section-5.23 |
| 265 | "default": "A String", # The default value of this property (if one exists). |
| 266 | "items": # Object with schema name: JsonSchema # If this is a schema for an array, this property is the schema for each element in the array. |
| 267 | "enum": [ # Values this parameter may take (if it is an enum). |
| 268 | "A String", |
| 269 | ], |
| 270 | "maximum": "A String", # The maximum value of this parameter. |
| 271 | "id": "A String", # Unique identifier for this schema. |
| 272 | "enumDescriptions": [ # The descriptions for the enums. Each position maps to the corresponding value in the "enum" array. |
| 273 | "A String", |
| 274 | ], |
| 275 | "minimum": "A String", # The minimum value of this parameter. |
| 276 | "location": "A String", # Whether this parameter goes in the query or the path for REST requests. |
| 277 | "pattern": "A String", # The regular expression this parameter must conform to. |
| 278 | "additionalProperties": # Object with schema name: JsonSchema # If this is a schema for an object, this property is the schema for any additional properties with dynamic keys on this object. |
| 279 | "repeated": True or False, # Whether this parameter may appear multiple times. |
| 280 | "annotations": { # Additional information about this property. |
| 281 | "required": [ # A list of methods for which this property is required on requests. |
| 282 | "A String", |
| 283 | ], |
| 284 | }, |
| 285 | "$ref": "A String", # A reference to another schema. The value of this property is the "id" of another schema. |
| 286 | }, |
| 287 | }, |
| 288 | "supportsMediaUpload": True or False, # Whether this method supports media uploads. |
| 289 | "request": { # The schema for the request. |
| 290 | "$ref": "A String", # Schema ID for the request schema. |
| 291 | }, |
| 292 | "mediaUpload": { # Media upload parameters. |
| 293 | "maxSize": "A String", # Maximum size of a media upload, such as "1MB", "2GB" or "3TB". |
| 294 | "protocols": { # Supported upload protocols. |
| 295 | "simple": { # Supports uploading as a single HTTP request. |
| 296 | "path": "A String", # The URI path to be used for upload. Should be used in conjunction with the basePath property at the api-level. |
| 297 | "multipart": true, # True if this endpoint supports upload multipart media. |
| 298 | }, |
| 299 | "resumable": { # Supports the Resumable Media Upload protocol. |
| 300 | "path": "A String", # The URI path to be used for upload. Should be used in conjunction with the basePath property at the api-level. |
| 301 | "multipart": true, # True if this endpoint supports uploading multipart media. |
| 302 | }, |
| 303 | }, |
| 304 | "accept": [ # MIME Media Ranges for acceptable media uploads to this method. |
| 305 | "A String", |
| 306 | ], |
| 307 | }, |
| 308 | "response": { # The schema for the response. |
| 309 | "$ref": "A String", # Schema ID for the response schema. |
| 310 | }, |
| 311 | "httpMethod": "A String", # HTTP method used by this method. |
| 312 | "supportsSubscription": True or False, # Whether this method supports subscriptions. |
| 313 | "parameterOrder": [ # Ordered list of required parameters, serves as a hint to clients on how to structure their method signatures. The array is ordered such that the "most-significant" parameter appears first. |
| 314 | "A String", |
| 315 | ], |
| 316 | "path": "A String", # The URI path of this REST method. Should be used in conjunction with the basePath property at the api-level. |
| 317 | "id": "A String", # A unique ID for this method. This property can be used to match methods between different versions of Discovery. |
| 318 | "supportsMediaDownload": True or False, # Whether this method supports media downloads. |
| 319 | }, |
| 320 | }, |
| 321 | "resources": { # Sub-resources on this resource. |
| 322 | "a_key": # Object with schema name: RestResource # Description for any sub-resources on this resource. |
| 323 | }, |
| 324 | }, |
Joe Gregorio | 075572b | 2012-07-09 16:53:09 -0400 | [diff] [blame] | 325 | }, |
| 326 | "revision": "A String", # The version of this API. |
| 327 | "description": "A String", # The description of this API. |
| 328 | "auth": { # Authentication information. |
| 329 | "oauth2": { # OAuth 2.0 authentication information. |
| 330 | "scopes": { # Available OAuth 2.0 scopes. |
Joe Gregorio | fa08c2e | 2012-07-23 16:52:03 -0400 | [diff] [blame^] | 331 | "a_key": { # The scope value. |
| 332 | "description": "A String", # Description of scope. |
| 333 | }, |
Joe Gregorio | 075572b | 2012-07-09 16:53:09 -0400 | [diff] [blame] | 334 | }, |
| 335 | }, |
| 336 | }, |
| 337 | "kind": "discovery#restDescription", # The kind for this response. |
| 338 | "name": "A String", # The name of this API. |
| 339 | "basePath": "A String", # [DEPRECATED] The base path for REST requests. |
| 340 | "title": "A String", # The title of this API. |
| 341 | "discoveryVersion": "v1", # Indicate the version of the Discovery API used to generate this doc. |
| 342 | "documentationLink": "A String", # A link to human readable documentation for the API. |
| 343 | }</pre> |
| 344 | </div> |
| 345 | |
| 346 | <div class="method"> |
| 347 | <code class="details" id="list">list(name=None, preferred=None, label=None)</code> |
| 348 | <pre>Retrieve the list of APIs supported at this endpoint. |
| 349 | |
| 350 | Args: |
| 351 | name: string, Only include APIs with the given name. |
| 352 | preferred: boolean, Return only the preferred version of an API. |
| 353 | label: string, Only include APIs with a matching label, such as 'graduated' or 'labs'. |
| 354 | Allowed values |
| 355 | deprecated - APIs that have been deprecated. |
| 356 | graduated - Supported APIs that have graduated from labs. |
| 357 | labs - APIs that are experimental |
| 358 | |
| 359 | Returns: |
| 360 | An object of the form: |
| 361 | |
| 362 | { |
| 363 | "items": [ # The individual directory entries. One entry per api/version pair. |
| 364 | { |
| 365 | "kind": "discovery#directoryItem", # The kind for this response. |
| 366 | "labels": [ # Labels for the status of this API, such as labs or deprecated. |
| 367 | "A String", |
| 368 | ], |
| 369 | "description": "A String", # The description of this API. |
| 370 | "icons": { # Links to 16x16 and 32x32 icons representing the API. |
| 371 | "x32": "A String", # The url of the 32x32 icon. |
| 372 | "x16": "A String", # The url of the 16x16 icon. |
| 373 | }, |
| 374 | "discoveryRestUrl": "A String", # The url for the discovery REST document. |
| 375 | "preferred": True or False, # True if this version is the preferred version to use. |
| 376 | "name": "A String", # The name of the API. |
| 377 | "discoveryLink": "A String", # A link to the discovery document. |
| 378 | "version": "A String", # The version of the API. |
| 379 | "title": "A String", # The title of this API. |
| 380 | "id": "A String", # The id of this API. |
| 381 | "documentationLink": "A String", # A link to human readable documentation for the API. |
| 382 | }, |
| 383 | ], |
| 384 | "discoveryVersion": "v1", # Indicate the version of the Discovery API used to generate this doc. |
| 385 | "kind": "discovery#directoryList", # The kind for this response. |
| 386 | }</pre> |
| 387 | </div> |
| 388 | |
| 389 | </body></html> |