blob: ae4966c127c2a4eddaee1ec263eb2f35e584c85d [file] [log] [blame]
Joe Gregorio761c4562011-10-28 14:36:24 -04001
2<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
3<html><head><title>Python: module oauth2client.clientsecrets</title>
4</head><body bgcolor="#f0f0f8">
5
6<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="heading">
7<tr bgcolor="#7799ee">
8<td valign=bottom>&nbsp;<br>
9<font color="#ffffff" face="helvetica, arial">&nbsp;<br><big><big><strong><a href="oauth2client.html"><font color="#ffffff">oauth2client</font></a>.clientsecrets</strong></big></big></font></td
10><td align=right valign=bottom
Joe Gregorio2401bd62011-12-15 09:18:49 -050011><font color="#ffffff" face="helvetica, arial"><a href=".">index</a><br><a href="file:/home/jcgregorio/projects/apiclient-release/oauth2client/clientsecrets.py">/home/jcgregorio/projects/apiclient-release/oauth2client/clientsecrets.py</a></font></td></tr></table>
Joe Gregorio761c4562011-10-28 14:36:24 -040012 <p><tt>Utilities&nbsp;for&nbsp;reading&nbsp;OAuth&nbsp;2.0&nbsp;client&nbsp;secret&nbsp;files.<br>
13&nbsp;<br>
14A&nbsp;client_secrets.json&nbsp;file&nbsp;contains&nbsp;all&nbsp;the&nbsp;information&nbsp;needed&nbsp;to&nbsp;interact&nbsp;with<br>
15an&nbsp;OAuth&nbsp;2.0&nbsp;protected&nbsp;service.</tt></p>
16<p>
17<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
18<tr bgcolor="#aa55cc">
19<td colspan=3 valign=bottom>&nbsp;<br>
20<font color="#ffffff" face="helvetica, arial"><big><strong>Modules</strong></big></font></td></tr>
21
22<tr><td bgcolor="#aa55cc"><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</tt></td><td>&nbsp;</td>
Joe Gregoriob417caf2011-12-08 12:04:24 -050023<td width="100%"><table width="100%" summary="list"><tr><td width="25%" valign=top><a href="simplejson.html">simplejson</a><br>
Joe Gregorio761c4562011-10-28 14:36:24 -040024</td><td width="25%" valign=top></td><td width="25%" valign=top></td><td width="25%" valign=top></td></tr></table></td></tr></table><p>
25<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
26<tr bgcolor="#ee77aa">
27<td colspan=3 valign=bottom>&nbsp;<br>
28<font color="#ffffff" face="helvetica, arial"><big><strong>Classes</strong></big></font></td></tr>
29
30<tr><td bgcolor="#ee77aa"><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</tt></td><td>&nbsp;</td>
31<td width="100%"><dl>
32<dt><font face="helvetica, arial"><a href="exceptions.html#Exception">exceptions.Exception</a>(<a href="exceptions.html#BaseException">exceptions.BaseException</a>)
33</font></dt><dd>
34<dl>
35<dt><font face="helvetica, arial"><a href="oauth2client.clientsecrets.html#Error">Error</a>
36</font></dt><dd>
37<dl>
38<dt><font face="helvetica, arial"><a href="oauth2client.clientsecrets.html#InvalidClientSecretsError">InvalidClientSecretsError</a>
39</font></dt></dl>
40</dd>
41</dl>
42</dd>
43</dl>
44 <p>
45<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
46<tr bgcolor="#ffc8d8">
47<td colspan=3 valign=bottom>&nbsp;<br>
48<font color="#000000" face="helvetica, arial"><a name="Error">class <strong>Error</strong></a>(<a href="exceptions.html#Exception">exceptions.Exception</a>)</font></td></tr>
49
50<tr bgcolor="#ffc8d8"><td rowspan=2><tt>&nbsp;&nbsp;&nbsp;</tt></td>
51<td colspan=2><tt>Base&nbsp;error&nbsp;for&nbsp;this&nbsp;module.<br>&nbsp;</tt></td></tr>
52<tr><td>&nbsp;</td>
53<td width="100%"><dl><dt>Method resolution order:</dt>
54<dd><a href="oauth2client.clientsecrets.html#Error">Error</a></dd>
55<dd><a href="exceptions.html#Exception">exceptions.Exception</a></dd>
56<dd><a href="exceptions.html#BaseException">exceptions.BaseException</a></dd>
57<dd><a href="__builtin__.html#object">__builtin__.object</a></dd>
58</dl>
59<hr>
60Data descriptors defined here:<br>
61<dl><dt><strong>__weakref__</strong></dt>
62<dd><tt>list&nbsp;of&nbsp;weak&nbsp;references&nbsp;to&nbsp;the&nbsp;object&nbsp;(if&nbsp;defined)</tt></dd>
63</dl>
64<hr>
65Methods inherited from <a href="exceptions.html#Exception">exceptions.Exception</a>:<br>
Joe Gregoriob417caf2011-12-08 12:04:24 -050066<dl><dt><a name="Error-__init__"><strong>__init__</strong></a>(...)</dt><dd><tt>x.<a href="#Error-__init__">__init__</a>(...)&nbsp;initializes&nbsp;x;&nbsp;see&nbsp;x.__class__.__doc__&nbsp;for&nbsp;signature</tt></dd></dl>
Joe Gregorio761c4562011-10-28 14:36:24 -040067
68<hr>
69Data and other attributes inherited from <a href="exceptions.html#Exception">exceptions.Exception</a>:<br>
70<dl><dt><strong>__new__</strong> = &lt;built-in method __new__ of type object&gt;<dd><tt>T.<a href="#Error-__new__">__new__</a>(S,&nbsp;...)&nbsp;-&gt;&nbsp;a&nbsp;new&nbsp;object&nbsp;with&nbsp;type&nbsp;S,&nbsp;a&nbsp;subtype&nbsp;of&nbsp;T</tt></dl>
71
72<hr>
73Methods inherited from <a href="exceptions.html#BaseException">exceptions.BaseException</a>:<br>
74<dl><dt><a name="Error-__delattr__"><strong>__delattr__</strong></a>(...)</dt><dd><tt>x.<a href="#Error-__delattr__">__delattr__</a>('name')&nbsp;&lt;==&gt;&nbsp;del&nbsp;x.name</tt></dd></dl>
75
76<dl><dt><a name="Error-__getattribute__"><strong>__getattribute__</strong></a>(...)</dt><dd><tt>x.<a href="#Error-__getattribute__">__getattribute__</a>('name')&nbsp;&lt;==&gt;&nbsp;x.name</tt></dd></dl>
77
78<dl><dt><a name="Error-__getitem__"><strong>__getitem__</strong></a>(...)</dt><dd><tt>x.<a href="#Error-__getitem__">__getitem__</a>(y)&nbsp;&lt;==&gt;&nbsp;x[y]</tt></dd></dl>
79
80<dl><dt><a name="Error-__getslice__"><strong>__getslice__</strong></a>(...)</dt><dd><tt>x.<a href="#Error-__getslice__">__getslice__</a>(i,&nbsp;j)&nbsp;&lt;==&gt;&nbsp;x[i:j]<br>
81&nbsp;<br>
82Use&nbsp;of&nbsp;negative&nbsp;indices&nbsp;is&nbsp;not&nbsp;supported.</tt></dd></dl>
83
84<dl><dt><a name="Error-__reduce__"><strong>__reduce__</strong></a>(...)</dt></dl>
85
86<dl><dt><a name="Error-__repr__"><strong>__repr__</strong></a>(...)</dt><dd><tt>x.<a href="#Error-__repr__">__repr__</a>()&nbsp;&lt;==&gt;&nbsp;repr(x)</tt></dd></dl>
87
88<dl><dt><a name="Error-__setattr__"><strong>__setattr__</strong></a>(...)</dt><dd><tt>x.<a href="#Error-__setattr__">__setattr__</a>('name',&nbsp;value)&nbsp;&lt;==&gt;&nbsp;x.name&nbsp;=&nbsp;value</tt></dd></dl>
89
90<dl><dt><a name="Error-__setstate__"><strong>__setstate__</strong></a>(...)</dt></dl>
91
92<dl><dt><a name="Error-__str__"><strong>__str__</strong></a>(...)</dt><dd><tt>x.<a href="#Error-__str__">__str__</a>()&nbsp;&lt;==&gt;&nbsp;str(x)</tt></dd></dl>
93
94<dl><dt><a name="Error-__unicode__"><strong>__unicode__</strong></a>(...)</dt></dl>
95
96<hr>
97Data descriptors inherited from <a href="exceptions.html#BaseException">exceptions.BaseException</a>:<br>
98<dl><dt><strong>__dict__</strong></dt>
99</dl>
100<dl><dt><strong>args</strong></dt>
101</dl>
102<dl><dt><strong>message</strong></dt>
103</dl>
104</td></tr></table> <p>
105<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
106<tr bgcolor="#ffc8d8">
107<td colspan=3 valign=bottom>&nbsp;<br>
108<font color="#000000" face="helvetica, arial"><a name="InvalidClientSecretsError">class <strong>InvalidClientSecretsError</strong></a>(<a href="oauth2client.clientsecrets.html#Error">Error</a>)</font></td></tr>
109
110<tr bgcolor="#ffc8d8"><td rowspan=2><tt>&nbsp;&nbsp;&nbsp;</tt></td>
111<td colspan=2><tt>Format&nbsp;of&nbsp;ClientSecrets&nbsp;file&nbsp;is&nbsp;invalid.<br>&nbsp;</tt></td></tr>
112<tr><td>&nbsp;</td>
113<td width="100%"><dl><dt>Method resolution order:</dt>
114<dd><a href="oauth2client.clientsecrets.html#InvalidClientSecretsError">InvalidClientSecretsError</a></dd>
115<dd><a href="oauth2client.clientsecrets.html#Error">Error</a></dd>
116<dd><a href="exceptions.html#Exception">exceptions.Exception</a></dd>
117<dd><a href="exceptions.html#BaseException">exceptions.BaseException</a></dd>
118<dd><a href="__builtin__.html#object">__builtin__.object</a></dd>
119</dl>
120<hr>
121Data descriptors inherited from <a href="oauth2client.clientsecrets.html#Error">Error</a>:<br>
122<dl><dt><strong>__weakref__</strong></dt>
123<dd><tt>list&nbsp;of&nbsp;weak&nbsp;references&nbsp;to&nbsp;the&nbsp;object&nbsp;(if&nbsp;defined)</tt></dd>
124</dl>
125<hr>
126Methods inherited from <a href="exceptions.html#Exception">exceptions.Exception</a>:<br>
Joe Gregoriob417caf2011-12-08 12:04:24 -0500127<dl><dt><a name="InvalidClientSecretsError-__init__"><strong>__init__</strong></a>(...)</dt><dd><tt>x.<a href="#InvalidClientSecretsError-__init__">__init__</a>(...)&nbsp;initializes&nbsp;x;&nbsp;see&nbsp;x.__class__.__doc__&nbsp;for&nbsp;signature</tt></dd></dl>
Joe Gregorio761c4562011-10-28 14:36:24 -0400128
129<hr>
130Data and other attributes inherited from <a href="exceptions.html#Exception">exceptions.Exception</a>:<br>
131<dl><dt><strong>__new__</strong> = &lt;built-in method __new__ of type object&gt;<dd><tt>T.<a href="#InvalidClientSecretsError-__new__">__new__</a>(S,&nbsp;...)&nbsp;-&gt;&nbsp;a&nbsp;new&nbsp;object&nbsp;with&nbsp;type&nbsp;S,&nbsp;a&nbsp;subtype&nbsp;of&nbsp;T</tt></dl>
132
133<hr>
134Methods inherited from <a href="exceptions.html#BaseException">exceptions.BaseException</a>:<br>
135<dl><dt><a name="InvalidClientSecretsError-__delattr__"><strong>__delattr__</strong></a>(...)</dt><dd><tt>x.<a href="#InvalidClientSecretsError-__delattr__">__delattr__</a>('name')&nbsp;&lt;==&gt;&nbsp;del&nbsp;x.name</tt></dd></dl>
136
137<dl><dt><a name="InvalidClientSecretsError-__getattribute__"><strong>__getattribute__</strong></a>(...)</dt><dd><tt>x.<a href="#InvalidClientSecretsError-__getattribute__">__getattribute__</a>('name')&nbsp;&lt;==&gt;&nbsp;x.name</tt></dd></dl>
138
139<dl><dt><a name="InvalidClientSecretsError-__getitem__"><strong>__getitem__</strong></a>(...)</dt><dd><tt>x.<a href="#InvalidClientSecretsError-__getitem__">__getitem__</a>(y)&nbsp;&lt;==&gt;&nbsp;x[y]</tt></dd></dl>
140
141<dl><dt><a name="InvalidClientSecretsError-__getslice__"><strong>__getslice__</strong></a>(...)</dt><dd><tt>x.<a href="#InvalidClientSecretsError-__getslice__">__getslice__</a>(i,&nbsp;j)&nbsp;&lt;==&gt;&nbsp;x[i:j]<br>
142&nbsp;<br>
143Use&nbsp;of&nbsp;negative&nbsp;indices&nbsp;is&nbsp;not&nbsp;supported.</tt></dd></dl>
144
145<dl><dt><a name="InvalidClientSecretsError-__reduce__"><strong>__reduce__</strong></a>(...)</dt></dl>
146
147<dl><dt><a name="InvalidClientSecretsError-__repr__"><strong>__repr__</strong></a>(...)</dt><dd><tt>x.<a href="#InvalidClientSecretsError-__repr__">__repr__</a>()&nbsp;&lt;==&gt;&nbsp;repr(x)</tt></dd></dl>
148
149<dl><dt><a name="InvalidClientSecretsError-__setattr__"><strong>__setattr__</strong></a>(...)</dt><dd><tt>x.<a href="#InvalidClientSecretsError-__setattr__">__setattr__</a>('name',&nbsp;value)&nbsp;&lt;==&gt;&nbsp;x.name&nbsp;=&nbsp;value</tt></dd></dl>
150
151<dl><dt><a name="InvalidClientSecretsError-__setstate__"><strong>__setstate__</strong></a>(...)</dt></dl>
152
153<dl><dt><a name="InvalidClientSecretsError-__str__"><strong>__str__</strong></a>(...)</dt><dd><tt>x.<a href="#InvalidClientSecretsError-__str__">__str__</a>()&nbsp;&lt;==&gt;&nbsp;str(x)</tt></dd></dl>
154
155<dl><dt><a name="InvalidClientSecretsError-__unicode__"><strong>__unicode__</strong></a>(...)</dt></dl>
156
157<hr>
158Data descriptors inherited from <a href="exceptions.html#BaseException">exceptions.BaseException</a>:<br>
159<dl><dt><strong>__dict__</strong></dt>
160</dl>
161<dl><dt><strong>args</strong></dt>
162</dl>
163<dl><dt><strong>message</strong></dt>
164</dl>
165</td></tr></table></td></tr></table><p>
166<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
167<tr bgcolor="#eeaa77">
168<td colspan=3 valign=bottom>&nbsp;<br>
169<font color="#ffffff" face="helvetica, arial"><big><strong>Functions</strong></big></font></td></tr>
170
171<tr><td bgcolor="#eeaa77"><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</tt></td><td>&nbsp;</td>
172<td width="100%"><dl><dt><a name="-load"><strong>load</strong></a>(fp)</dt></dl>
173 <dl><dt><a name="-loadfile"><strong>loadfile</strong></a>(filename)</dt></dl>
174 <dl><dt><a name="-loads"><strong>loads</strong></a>(s)</dt></dl>
175</td></tr></table><p>
176<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
177<tr bgcolor="#55aa55">
178<td colspan=3 valign=bottom>&nbsp;<br>
179<font color="#ffffff" face="helvetica, arial"><big><strong>Data</strong></big></font></td></tr>
180
181<tr><td bgcolor="#55aa55"><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</tt></td><td>&nbsp;</td>
182<td width="100%"><strong>TYPE_INSTALLED</strong> = 'installed'<br>
183<strong>TYPE_WEB</strong> = 'web'<br>
184<strong>VALID_CLIENT</strong> = {'installed': {'required': ['client_id', 'client_secret', 'redirect_uris', 'auth_uri', 'token_uri'], 'string': ['client_id', 'client_secret']}, 'web': {'required': ['client_id', 'client_secret', 'redirect_uris', 'auth_uri', 'token_uri'], 'string': ['client_id', 'client_secret']}}<br>
185<strong>__author__</strong> = 'jcgregorio@google.com (Joe Gregorio)'</td></tr></table><p>
186<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
187<tr bgcolor="#7799ee">
188<td colspan=3 valign=bottom>&nbsp;<br>
189<font color="#ffffff" face="helvetica, arial"><big><strong>Author</strong></big></font></td></tr>
190
191<tr><td bgcolor="#7799ee"><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</tt></td><td>&nbsp;</td>
192<td width="100%">jcgregorio@google.com&nbsp;(Joe&nbsp;Gregorio)</td></tr></table>
193</body></html>