blob: 078d83b1b4bc4b858c8f8fc757266cb4c8475676 [file] [log] [blame]
Takashi Matsuo06694102015-09-11 13:55:40 -07001<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="classroom_v1.html">Google Classroom API</a> . <a href="classroom_v1.invitations.html">invitations</a></h1>
76<h2>Instance Methods</h2>
77<p class="toc_element">
78 <code><a href="#accept">accept(id, x__xgafv=None)</a></code></p>
Sai Cheemalapatie833b792017-03-24 15:06:46 -070079<p class="firstline">Accepts an invitation, removing it and adding the invited user to the</p>
Takashi Matsuo06694102015-09-11 13:55:40 -070080<p class="toc_element">
81 <code><a href="#create">create(body, x__xgafv=None)</a></code></p>
Sai Cheemalapatie833b792017-03-24 15:06:46 -070082<p class="firstline">Creates an invitation. Only one invitation for a user and course may exist</p>
Takashi Matsuo06694102015-09-11 13:55:40 -070083<p class="toc_element">
84 <code><a href="#delete">delete(id, x__xgafv=None)</a></code></p>
Sai Cheemalapatie833b792017-03-24 15:06:46 -070085<p class="firstline">Deletes an invitation.</p>
Takashi Matsuo06694102015-09-11 13:55:40 -070086<p class="toc_element">
87 <code><a href="#get">get(id, x__xgafv=None)</a></code></p>
Sai Cheemalapatie833b792017-03-24 15:06:46 -070088<p class="firstline">Returns an invitation.</p>
Takashi Matsuo06694102015-09-11 13:55:40 -070089<p class="toc_element">
90 <code><a href="#list">list(pageSize=None, courseId=None, userId=None, x__xgafv=None, pageToken=None)</a></code></p>
Sai Cheemalapatie833b792017-03-24 15:06:46 -070091<p class="firstline">Returns a list of invitations that the requesting user is permitted to</p>
Takashi Matsuo06694102015-09-11 13:55:40 -070092<p class="toc_element">
93 <code><a href="#list_next">list_next(previous_request, previous_response)</a></code></p>
94<p class="firstline">Retrieves the next page of results.</p>
95<h3>Method Details</h3>
96<div class="method">
97 <code class="details" id="accept">accept(id, x__xgafv=None)</code>
Sai Cheemalapatie833b792017-03-24 15:06:46 -070098 <pre>Accepts an invitation, removing it and adding the invited user to the
99teachers or students (as appropriate) of the specified course. Only the
100invited user may accept an invitation.
101
102This method returns the following error codes:
103
104* `PERMISSION_DENIED` if the requesting user is not permitted to accept the
105requested invitation or for access errors.
106* `FAILED_PRECONDITION` for the following request errors:
107 * CourseMemberLimitReached
108 * CourseNotModifiable
109 * CourseTeacherLimitReached
110 * UserGroupsMembershipLimitReached
111* `NOT_FOUND` if no invitation exists with the requested ID.
Takashi Matsuo06694102015-09-11 13:55:40 -0700112
113Args:
114 id: string, Identifier of the invitation to accept. (required)
115 x__xgafv: string, V1 error format.
Sai Cheemalapatie833b792017-03-24 15:06:46 -0700116 Allowed values
117 1 - v1 error format
118 2 - v2 error format
Takashi Matsuo06694102015-09-11 13:55:40 -0700119
120Returns:
121 An object of the form:
122
Sai Cheemalapatie833b792017-03-24 15:06:46 -0700123 { # A generic empty message that you can re-use to avoid defining duplicated
124 # empty messages in your APIs. A typical example is to use it as the request
125 # or the response type of an API method. For instance:
126 #
127 # service Foo {
128 # rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty);
129 # }
130 #
131 # The JSON representation for `Empty` is empty JSON object `{}`.
Takashi Matsuo06694102015-09-11 13:55:40 -0700132 }</pre>
133</div>
134
135<div class="method">
136 <code class="details" id="create">create(body, x__xgafv=None)</code>
Sai Cheemalapatie833b792017-03-24 15:06:46 -0700137 <pre>Creates an invitation. Only one invitation for a user and course may exist
138at a time. Delete and re-create an invitation to make changes.
139
140This method returns the following error codes:
141
142* `PERMISSION_DENIED` if the requesting user is not permitted to create
143invitations for this course or for access errors.
144* `NOT_FOUND` if the course or the user does not exist.
145* `FAILED_PRECONDITION` if the requested user's account is disabled or if
146the user already has this role or a role with greater permissions.
147* `ALREADY_EXISTS` if an invitation for the specified user and course
148already exists.
Takashi Matsuo06694102015-09-11 13:55:40 -0700149
150Args:
151 body: object, The request body. (required)
152 The object takes the form of:
153
154{ # An invitation to join a course.
155 "courseId": "A String", # Identifier of the course to invite the user to.
Sai Cheemalapatie833b792017-03-24 15:06:46 -0700156 "userId": "A String", # Identifier of the invited user.
157 #
158 # When specified as a parameter of a request, this identifier can be set to
159 # one of the following:
160 #
161 # * the numeric identifier for the user
162 # * the email address of the user
163 # * the string literal `"me"`, indicating the requesting user
164 "role": "A String", # Role to invite the user to have.
165 # Must not be `COURSE_ROLE_UNSPECIFIED`.
166 "id": "A String", # Identifier assigned by Classroom.
167 #
168 # Read-only.
Takashi Matsuo06694102015-09-11 13:55:40 -0700169 }
170
171 x__xgafv: string, V1 error format.
Sai Cheemalapatie833b792017-03-24 15:06:46 -0700172 Allowed values
173 1 - v1 error format
174 2 - v2 error format
Takashi Matsuo06694102015-09-11 13:55:40 -0700175
176Returns:
177 An object of the form:
178
179 { # An invitation to join a course.
180 "courseId": "A String", # Identifier of the course to invite the user to.
Sai Cheemalapatie833b792017-03-24 15:06:46 -0700181 "userId": "A String", # Identifier of the invited user.
182 #
183 # When specified as a parameter of a request, this identifier can be set to
184 # one of the following:
185 #
186 # * the numeric identifier for the user
187 # * the email address of the user
188 # * the string literal `"me"`, indicating the requesting user
189 "role": "A String", # Role to invite the user to have.
190 # Must not be `COURSE_ROLE_UNSPECIFIED`.
191 "id": "A String", # Identifier assigned by Classroom.
192 #
193 # Read-only.
Takashi Matsuo06694102015-09-11 13:55:40 -0700194 }</pre>
195</div>
196
197<div class="method">
198 <code class="details" id="delete">delete(id, x__xgafv=None)</code>
Sai Cheemalapatie833b792017-03-24 15:06:46 -0700199 <pre>Deletes an invitation.
200
201This method returns the following error codes:
202
203* `PERMISSION_DENIED` if the requesting user is not permitted to delete the
204requested invitation or for access errors.
205* `NOT_FOUND` if no invitation exists with the requested ID.
Takashi Matsuo06694102015-09-11 13:55:40 -0700206
207Args:
208 id: string, Identifier of the invitation to delete. (required)
209 x__xgafv: string, V1 error format.
Sai Cheemalapatie833b792017-03-24 15:06:46 -0700210 Allowed values
211 1 - v1 error format
212 2 - v2 error format
Takashi Matsuo06694102015-09-11 13:55:40 -0700213
214Returns:
215 An object of the form:
216
Sai Cheemalapatie833b792017-03-24 15:06:46 -0700217 { # A generic empty message that you can re-use to avoid defining duplicated
218 # empty messages in your APIs. A typical example is to use it as the request
219 # or the response type of an API method. For instance:
220 #
221 # service Foo {
222 # rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty);
223 # }
224 #
225 # The JSON representation for `Empty` is empty JSON object `{}`.
Takashi Matsuo06694102015-09-11 13:55:40 -0700226 }</pre>
227</div>
228
229<div class="method">
230 <code class="details" id="get">get(id, x__xgafv=None)</code>
Sai Cheemalapatie833b792017-03-24 15:06:46 -0700231 <pre>Returns an invitation.
232
233This method returns the following error codes:
234
235* `PERMISSION_DENIED` if the requesting user is not permitted to view the
236requested invitation or for access errors.
237* `NOT_FOUND` if no invitation exists with the requested ID.
Takashi Matsuo06694102015-09-11 13:55:40 -0700238
239Args:
240 id: string, Identifier of the invitation to return. (required)
241 x__xgafv: string, V1 error format.
Sai Cheemalapatie833b792017-03-24 15:06:46 -0700242 Allowed values
243 1 - v1 error format
244 2 - v2 error format
Takashi Matsuo06694102015-09-11 13:55:40 -0700245
246Returns:
247 An object of the form:
248
249 { # An invitation to join a course.
250 "courseId": "A String", # Identifier of the course to invite the user to.
Sai Cheemalapatie833b792017-03-24 15:06:46 -0700251 "userId": "A String", # Identifier of the invited user.
252 #
253 # When specified as a parameter of a request, this identifier can be set to
254 # one of the following:
255 #
256 # * the numeric identifier for the user
257 # * the email address of the user
258 # * the string literal `"me"`, indicating the requesting user
259 "role": "A String", # Role to invite the user to have.
260 # Must not be `COURSE_ROLE_UNSPECIFIED`.
261 "id": "A String", # Identifier assigned by Classroom.
262 #
263 # Read-only.
Takashi Matsuo06694102015-09-11 13:55:40 -0700264 }</pre>
265</div>
266
267<div class="method">
268 <code class="details" id="list">list(pageSize=None, courseId=None, userId=None, x__xgafv=None, pageToken=None)</code>
Sai Cheemalapatie833b792017-03-24 15:06:46 -0700269 <pre>Returns a list of invitations that the requesting user is permitted to
270view, restricted to those that match the list request.
271
272*Note:* At least one of `user_id` or `course_id` must be supplied. Both
273fields can be supplied.
274
275This method returns the following error codes:
276
277* `PERMISSION_DENIED` for access errors.
Takashi Matsuo06694102015-09-11 13:55:40 -0700278
279Args:
Sai Cheemalapatie833b792017-03-24 15:06:46 -0700280 pageSize: integer, Maximum number of items to return. Zero means no maximum.
281
282The server may return fewer than the specified number of results.
283 courseId: string, Restricts returned invitations to those for a course with the specified
284identifier.
285 userId: string, Restricts returned invitations to those for a specific user. The identifier
286can be one of the following:
287
288* the numeric identifier for the user
289* the email address of the user
290* the string literal `"me"`, indicating the requesting user
Takashi Matsuo06694102015-09-11 13:55:40 -0700291 x__xgafv: string, V1 error format.
Sai Cheemalapatie833b792017-03-24 15:06:46 -0700292 Allowed values
293 1 - v1 error format
294 2 - v2 error format
295 pageToken: string, nextPageToken
296value returned from a previous
297list call, indicating
298that the subsequent page of results should be returned.
299
300The list request must be
301otherwise identical to the one that resulted in this token.
Takashi Matsuo06694102015-09-11 13:55:40 -0700302
303Returns:
304 An object of the form:
305
306 { # Response when listing invitations.
Sai Cheemalapatie833b792017-03-24 15:06:46 -0700307 "nextPageToken": "A String", # Token identifying the next page of results to return. If empty, no further
308 # results are available.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800309 "invitations": [ # Invitations that match the list request.
Takashi Matsuo06694102015-09-11 13:55:40 -0700310 { # An invitation to join a course.
311 "courseId": "A String", # Identifier of the course to invite the user to.
Sai Cheemalapatie833b792017-03-24 15:06:46 -0700312 "userId": "A String", # Identifier of the invited user.
313 #
314 # When specified as a parameter of a request, this identifier can be set to
315 # one of the following:
316 #
317 # * the numeric identifier for the user
318 # * the email address of the user
319 # * the string literal `"me"`, indicating the requesting user
320 "role": "A String", # Role to invite the user to have.
321 # Must not be `COURSE_ROLE_UNSPECIFIED`.
322 "id": "A String", # Identifier assigned by Classroom.
323 #
324 # Read-only.
Takashi Matsuo06694102015-09-11 13:55:40 -0700325 },
326 ],
327 }</pre>
328</div>
329
330<div class="method">
331 <code class="details" id="list_next">list_next(previous_request, previous_response)</code>
332 <pre>Retrieves the next page of results.
333
334Args:
335 previous_request: The request for the previous page. (required)
336 previous_response: The response from the request for the previous page. (required)
337
338Returns:
339 A request object that you can call 'execute()' on to request the next
340 page. Returns None if there are no more items in the collection.
341 </pre>
342</div>
343
344</body></html>