Joe Gregorio | 351b149 | 2011-05-08 23:32:46 -0700 | [diff] [blame] | 1 | |
| 2 | <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> |
| 3 | <html><head><title>Python: class Resource</title> |
| 4 | </head><body bgcolor="#f0f0f8"> |
| 5 | <p> |
| 6 | <table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section"> |
| 7 | <tr bgcolor="#ffc8d8"> |
| 8 | <td colspan=3 valign=bottom> <br> |
| 9 | <font color="#000000" face="helvetica, arial"><a name="Resource">class <strong>Resource</strong></a>(<a href="__builtin__.html#object">__builtin__.object</a>)</font></td></tr> |
| 10 | |
| 11 | <tr bgcolor="#ffc8d8"><td rowspan=2><tt> </tt></td> |
| 12 | <td colspan=2><tt>A class for interacting with a resource.<br> </tt></td></tr> |
| 13 | <tr><td> </td> |
| 14 | <td width="100%">Methods defined here:<br> |
| 15 | <dl><dt><a name="Resource-__init__"><strong>__init__</strong></a>(self)</dt></dl> |
| 16 | |
| 17 | <dl><dt><a name="Resource-getRest"><strong>getRest</strong></a> = method(self, **kwargs)</dt><dd><tt>Retrieve the description of a particular version of an api.<br> |
| 18 | <br> |
| 19 | Args:<br> |
| 20 | api: string, The name of the API. (required)<br> |
Joe Gregorio | b417caf | 2011-12-08 12:04:24 -0500 | [diff] [blame] | 21 | version: string, The version of the API. (required)<br> |
| 22 | <br> |
| 23 | Returns:<br> |
| 24 | An object of the form<br> |
| 25 | <br> |
| 26 | {<br> |
Joe Gregorio | df70dfc | 2012-04-23 08:31:37 -0400 | [diff] [blame^] | 27 | "protocol": "rest", # The protocol described by this document.<br> |
| 28 | "methods": { # API-level methods for this API.<br> |
| 29 | },<br> |
| 30 | "labels": [ # Labels for the status of this API, such as labs or deprecated.<br> |
| 31 | "A String",<br> |
| 32 | ],<br> |
| 33 | "batchPath": "batch", # The path for REST batch requests.<br> |
| 34 | "id": "A String", # The id of this API.<br> |
Joe Gregorio | d02bf5e | 2012-03-02 13:21:32 -0800 | [diff] [blame] | 35 | "schemas": { # The schemas for this API.<br> |
| 36 | },<br> |
Joe Gregorio | df70dfc | 2012-04-23 08:31:37 -0400 | [diff] [blame^] | 37 | "rootUrl": "A String", # The root url under which all API services live.<br> |
Joe Gregorio | b417caf | 2011-12-08 12:04:24 -0500 | [diff] [blame] | 38 | "parameters": { # Common parameters that apply across all apis.<br> |
| 39 | },<br> |
| 40 | "icons": { # Links to 16x16 and 32x32 icons representing the API.<br> |
| 41 | "x32": "A String", # The url of the 32x32 icon.<br> |
| 42 | "x16": "A String", # The url of the 16x16 icon.<br> |
| 43 | },<br> |
Joe Gregorio | df70dfc | 2012-04-23 08:31:37 -0400 | [diff] [blame^] | 44 | "baseUrl": "A String", # [DEPRECATED] The base URL for REST requests.<br> |
| 45 | "version": "A String", # The version of this API.<br> |
| 46 | "features": [ # A list of supported features for this API.<br> |
Joe Gregorio | d02bf5e | 2012-03-02 13:21:32 -0800 | [diff] [blame] | 47 | "A String",<br> |
| 48 | ],<br> |
Joe Gregorio | df70dfc | 2012-04-23 08:31:37 -0400 | [diff] [blame^] | 49 | "servicePath": "A String", # The base path for all REST requests.<br> |
| 50 | "resources": { # The resources in this API.<br> |
| 51 | },<br> |
| 52 | "revision": "A String", # The version of this API.<br> |
| 53 | "description": "A String", # The description of this API.<br> |
Joe Gregorio | b417caf | 2011-12-08 12:04:24 -0500 | [diff] [blame] | 54 | "auth": { # Authentication information.<br> |
| 55 | "oauth2": { # OAuth 2.0 authentication information.<br> |
| 56 | "scopes": { # Available OAuth 2.0 scopes.<br> |
| 57 | },<br> |
| 58 | },<br> |
| 59 | },<br> |
Joe Gregorio | df70dfc | 2012-04-23 08:31:37 -0400 | [diff] [blame^] | 60 | "kind": "discovery#restDescription", # The kind for this response.<br> |
Joe Gregorio | b417caf | 2011-12-08 12:04:24 -0500 | [diff] [blame] | 61 | "name": "A String", # The name of this API.<br> |
Joe Gregorio | df70dfc | 2012-04-23 08:31:37 -0400 | [diff] [blame^] | 62 | "basePath": "A String", # [DEPRECATED] The base path for REST requests.<br> |
Joe Gregorio | 3d55ac5 | 2012-02-21 10:11:19 -0500 | [diff] [blame] | 63 | "title": "A String", # The title of this API.<br> |
Joe Gregorio | d02bf5e | 2012-03-02 13:21:32 -0800 | [diff] [blame] | 64 | "discoveryVersion": "v1", # Indicate the version of the Discovery API used to generate this doc.<br> |
Joe Gregorio | 3d55ac5 | 2012-02-21 10:11:19 -0500 | [diff] [blame] | 65 | "documentationLink": "A String", # A link to human readable documentation for the API.<br> |
Joe Gregorio | b417caf | 2011-12-08 12:04:24 -0500 | [diff] [blame] | 66 | }</tt></dd></dl> |
Joe Gregorio | 351b149 | 2011-05-08 23:32:46 -0700 | [diff] [blame] | 67 | |
| 68 | <dl><dt><a name="Resource-list"><strong>list</strong></a> = method(self, **kwargs)</dt><dd><tt>Retrieve the list of APIs supported at this endpoint.<br> |
| 69 | <br> |
| 70 | Args:<br> |
| 71 | name: string, Only include APIs with the given name.<br> |
| 72 | preferred: boolean, Return only the preferred version of an API.<br> |
| 73 | label: string, Only include APIs with a matching label, such as 'graduated' or 'labs'.<br> |
| 74 | Allowed values<br> |
| 75 | deprecated - APIs that have been deprecated.<br> |
| 76 | graduated - Supported APIs that have graduated from labs.<br> |
Joe Gregorio | b417caf | 2011-12-08 12:04:24 -0500 | [diff] [blame] | 77 | labs - APIs that are experimental<br> |
| 78 | <br> |
| 79 | Returns:<br> |
| 80 | An object of the form<br> |
| 81 | <br> |
| 82 | {<br> |
| 83 | "items": [ # The individual directory entries. One entry per api/version pair.<br> |
| 84 | {<br> |
| 85 | "kind": "discovery#directoryItem", # The kind for this response.<br> |
Joe Gregorio | 3d55ac5 | 2012-02-21 10:11:19 -0500 | [diff] [blame] | 86 | "labels": [ # Labels for the status of this API, such as labs or deprecated.<br> |
| 87 | "A String",<br> |
| 88 | ],<br> |
Joe Gregorio | b417caf | 2011-12-08 12:04:24 -0500 | [diff] [blame] | 89 | "description": "A String", # The description of this API.<br> |
| 90 | "icons": { # Links to 16x16 and 32x32 icons representing the API.<br> |
| 91 | "x32": "A String", # The url of the 32x32 icon.<br> |
| 92 | "x16": "A String", # The url of the 16x16 icon.<br> |
| 93 | },<br> |
Joe Gregorio | 3d55ac5 | 2012-02-21 10:11:19 -0500 | [diff] [blame] | 94 | "discoveryRestUrl": "A String", # The url for the discovery REST document.<br> |
Joe Gregorio | b417caf | 2011-12-08 12:04:24 -0500 | [diff] [blame] | 95 | "preferred": True or False, # True if this version is the preferred version to use.<br> |
| 96 | "name": "A String", # The name of the API.<br> |
| 97 | "discoveryLink": "A String", # A link to the discovery document.<br> |
| 98 | "version": "A String", # The version of the API.<br> |
| 99 | "title": "A String", # The title of this API.<br> |
| 100 | "id": "A String", # The id of this API.<br> |
| 101 | "documentationLink": "A String", # A link to human readable documentation for the API.<br> |
| 102 | },<br> |
| 103 | ],<br> |
Joe Gregorio | d02bf5e | 2012-03-02 13:21:32 -0800 | [diff] [blame] | 104 | "discoveryVersion": "v1", # Indicate the version of the Discovery API used to generate this doc.<br> |
Joe Gregorio | b417caf | 2011-12-08 12:04:24 -0500 | [diff] [blame] | 105 | "kind": "discovery#directoryList", # The kind for this response.<br> |
| 106 | }</tt></dd></dl> |
Joe Gregorio | 351b149 | 2011-05-08 23:32:46 -0700 | [diff] [blame] | 107 | |
| 108 | <hr> |
| 109 | Data descriptors defined here:<br> |
| 110 | <dl><dt><strong>__dict__</strong></dt> |
| 111 | <dd><tt>dictionary for instance variables (if defined)</tt></dd> |
| 112 | </dl> |
| 113 | <dl><dt><strong>__weakref__</strong></dt> |
| 114 | <dd><tt>list of weak references to the object (if defined)</tt></dd> |
| 115 | </dl> |
| 116 | </td></tr></table> |
| 117 | </body></html> |