blob: 2af1da62775cea35ed8e4db316cef138ad93a6c7 [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>
79<p class="firstline">Accepts an invitation, removing it and adding the invited user to the teachers or students (as appropriate) of the specified course. Only the invited user may accept an invitation. This method returns the following error codes: * `PERMISSION_DENIED` if the requesting user is not permitted to accept the requested invitation. * `NOT_FOUND` if no invitation exists with the requested ID.</p>
80<p class="toc_element">
81 <code><a href="#create">create(body, x__xgafv=None)</a></code></p>
82<p class="firstline">Creates a invitation. Only one invitation for a user and course may exist at a time. Delete and recreate an invitation to make changes. This method returns the following error codes: * `PERMISSION_DENIED` if the requesting user is not permitted to create invitations for this course. * `NOT_FOUND` if the course or the user does not exist. * `ALREADY_EXISTS` if an invitation for the specified user and course already exists.</p>
83<p class="toc_element">
84 <code><a href="#delete">delete(id, x__xgafv=None)</a></code></p>
85<p class="firstline">Deletes a invitation. This method returns the following error codes: * `PERMISSION_DENIED` if the requesting user is not permitted to delete the requested invitation. * `NOT_FOUND` if no invitation exists with the requested ID.</p>
86<p class="toc_element">
87 <code><a href="#get">get(id, x__xgafv=None)</a></code></p>
88<p class="firstline">Returns a invitation. This method returns the following error codes: * `PERMISSION_DENIED` if the requesting user is not permitted to view the requested invitation. * `NOT_FOUND` if no invitation exists with the requested ID.</p>
89<p class="toc_element">
90 <code><a href="#list">list(pageSize=None, courseId=None, userId=None, x__xgafv=None, pageToken=None)</a></code></p>
91<p class="firstline">Returns a list of invitations that the requesting user is permitted to view, restricted to those that match the request. *Note:* At least one of `user_id` or `course_id` must be supplied.</p>
92<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>
98 <pre>Accepts an invitation, removing it and adding the invited user to the teachers or students (as appropriate) of the specified course. Only the invited user may accept an invitation. This method returns the following error codes: * `PERMISSION_DENIED` if the requesting user is not permitted to accept the requested invitation. * `NOT_FOUND` if no invitation exists with the requested ID.
99
100Args:
101 id: string, Identifier of the invitation to accept. (required)
102 x__xgafv: string, V1 error format.
103
104Returns:
105 An object of the form:
106
107 { # A generic empty message that you can re-use to avoid defining duplicated empty messages in your APIs. A typical example is to use it as the request or the response type of an API method. For instance: service Foo { rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); } The JSON representation for `Empty` is empty JSON object `{}`.
108 }</pre>
109</div>
110
111<div class="method">
112 <code class="details" id="create">create(body, x__xgafv=None)</code>
113 <pre>Creates a invitation. Only one invitation for a user and course may exist at a time. Delete and recreate an invitation to make changes. This method returns the following error codes: * `PERMISSION_DENIED` if the requesting user is not permitted to create invitations for this course. * `NOT_FOUND` if the course or the user does not exist. * `ALREADY_EXISTS` if an invitation for the specified user and course already exists.
114
115Args:
116 body: object, The request body. (required)
117 The object takes the form of:
118
119{ # An invitation to join a course.
120 "courseId": "A String", # Identifier of the course to invite the user to.
121 "role": "A String", # Role to invite the user to have. Must not be `COURSE_ROLE_UNSPECIFIED`.
122 "userId": "A String", # Identifier of the invited user. When specified as a parameter of a request, this may be set to an alias that identifies the user to invite. The supported aliases are: * the e-mail address of the user * the string literal `"me"`, indicating that the requesting user
123 "id": "A String", # Unique identifier assigned by Classroom. Read-only
124 }
125
126 x__xgafv: string, V1 error format.
127
128Returns:
129 An object of the form:
130
131 { # An invitation to join a course.
132 "courseId": "A String", # Identifier of the course to invite the user to.
133 "role": "A String", # Role to invite the user to have. Must not be `COURSE_ROLE_UNSPECIFIED`.
134 "userId": "A String", # Identifier of the invited user. When specified as a parameter of a request, this may be set to an alias that identifies the user to invite. The supported aliases are: * the e-mail address of the user * the string literal `"me"`, indicating that the requesting user
135 "id": "A String", # Unique identifier assigned by Classroom. Read-only
136 }</pre>
137</div>
138
139<div class="method">
140 <code class="details" id="delete">delete(id, x__xgafv=None)</code>
141 <pre>Deletes a invitation. This method returns the following error codes: * `PERMISSION_DENIED` if the requesting user is not permitted to delete the requested invitation. * `NOT_FOUND` if no invitation exists with the requested ID.
142
143Args:
144 id: string, Identifier of the invitation to delete. (required)
145 x__xgafv: string, V1 error format.
146
147Returns:
148 An object of the form:
149
150 { # A generic empty message that you can re-use to avoid defining duplicated empty messages in your APIs. A typical example is to use it as the request or the response type of an API method. For instance: service Foo { rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); } The JSON representation for `Empty` is empty JSON object `{}`.
151 }</pre>
152</div>
153
154<div class="method">
155 <code class="details" id="get">get(id, x__xgafv=None)</code>
156 <pre>Returns a invitation. This method returns the following error codes: * `PERMISSION_DENIED` if the requesting user is not permitted to view the requested invitation. * `NOT_FOUND` if no invitation exists with the requested ID.
157
158Args:
159 id: string, Identifier of the invitation to return. (required)
160 x__xgafv: string, V1 error format.
161
162Returns:
163 An object of the form:
164
165 { # An invitation to join a course.
166 "courseId": "A String", # Identifier of the course to invite the user to.
167 "role": "A String", # Role to invite the user to have. Must not be `COURSE_ROLE_UNSPECIFIED`.
168 "userId": "A String", # Identifier of the invited user. When specified as a parameter of a request, this may be set to an alias that identifies the user to invite. The supported aliases are: * the e-mail address of the user * the string literal `"me"`, indicating that the requesting user
169 "id": "A String", # Unique identifier assigned by Classroom. Read-only
170 }</pre>
171</div>
172
173<div class="method">
174 <code class="details" id="list">list(pageSize=None, courseId=None, userId=None, x__xgafv=None, pageToken=None)</code>
175 <pre>Returns a list of invitations that the requesting user is permitted to view, restricted to those that match the request. *Note:* At least one of `user_id` or `course_id` must be supplied.
176
177Args:
178 pageSize: integer, The maximum number of items to return. Zero means no maximum. The server may return fewer than the specified number of results.
179 courseId: string, Restricts returned invitations to those for a course with the specified identifier.
180 userId: string, Restricts returned invitations to those for a specific user. This may be the unique identifier for the user or an alias. The supported aliases are: * the e-mail address of the user * the string literal `"me"`, indicating the requesting user
181 x__xgafv: string, V1 error format.
182 pageToken: string, [nextPageToken][google.classroom.v1.ListInvitationsRespnse.next_page_token] value returned from a previous [list][google.classroom.v1.Users.ListInvitations] call, indicating that the subsequent page of results should be returned. The [list][google.classroom.v1.Users.ListInvitations] request must be identical to the one which resulted in this token.
183
184Returns:
185 An object of the form:
186
187 { # Response when listing invitations.
188 "nextPageToken": "A String", # Token identifying the next page of results to return. If empty, no further results are available.
189 "invitations": [ # Invitations that match the request.
190 { # An invitation to join a course.
191 "courseId": "A String", # Identifier of the course to invite the user to.
192 "role": "A String", # Role to invite the user to have. Must not be `COURSE_ROLE_UNSPECIFIED`.
193 "userId": "A String", # Identifier of the invited user. When specified as a parameter of a request, this may be set to an alias that identifies the user to invite. The supported aliases are: * the e-mail address of the user * the string literal `"me"`, indicating that the requesting user
194 "id": "A String", # Unique identifier assigned by Classroom. Read-only
195 },
196 ],
197 }</pre>
198</div>
199
200<div class="method">
201 <code class="details" id="list_next">list_next(previous_request, previous_response)</code>
202 <pre>Retrieves the next page of results.
203
204Args:
205 previous_request: The request for the previous page. (required)
206 previous_response: The response from the request for the previous page. (required)
207
208Returns:
209 A request object that you can call 'execute()' on to request the next
210 page. Returns None if there are no more items in the collection.
211 </pre>
212</div>
213
214</body></html>