이제 Google 클래스룸 부가기능이 일반적으로 개발자에게 제공됩니다. 자세한 내용은
부가기능 문서를 참고하세요.
Method: invitations.list
컬렉션을 사용해 정리하기
내 환경설정을 기준으로 콘텐츠를 저장하고 분류하세요.
요청하는 사용자가 볼 수 있는 초대 목록을 반환하며, 목록 요청과 일치하는 초대로 제한됩니다.
참고: userId
또는 courseId
중 하나 이상을 제공해야 합니다. 두 필드 모두 제공할 수 있습니다.
이 메서드는 다음 오류 코드를 반환합니다.
HTTP 요청
GET https://classroom.googleapis.com/v1/invitations
URL은 gRPC 트랜스코딩 구문을 사용합니다.
쿼리 매개변수
매개변수 |
userId |
string
반환된 초대를 특정 사용자의 초대로 제한합니다. 식별자는 다음 중 하나일 수 있습니다.
- 사용자의 숫자 식별자
- 사용자의 이메일 주소
- 요청하는 사용자를 나타내는 문자열 리터럴
"me"
|
courseId |
string
지정된 식별자가 있는 과정의 초대로 반환되는 초대를 제한합니다.
|
pageSize |
integer
반환할 최대 항목 수입니다. 지정하지 않으면 기본값은 500입니다(또는 0 ). 서버에서 지정된 수보다 적은 결과를 반환할 수 있습니다.
|
pageToken |
string
이전 list 호출에서 반환된 nextPageToken 값으로, 후속 결과 페이지를 반환해야 함을 나타냅니다. list 요청은 이 토큰을 생성한 요청과 동일해야 합니다.
|
응답 본문
초대를 나열할 때의 응답입니다.
성공한 경우 응답 본문은 다음과 같은 구조의 데이터를 포함합니다.
JSON 표현 |
{
"invitations": [
{
object (Invitation )
}
],
"nextPageToken": string
} |
필드 |
invitations[] |
object (Invitation )
목록 요청과 일치하는 초대입니다.
|
nextPageToken |
string
반환할 다음 결과 페이지를 식별하는 토큰입니다. 비어 있으면 더 이상 결과를 사용할 수 없습니다.
|
승인 범위
다음 OAuth 범위 중 하나가 필요합니다.
https://www.googleapis.com/auth/classroom.rosters
https://www.googleapis.com/auth/classroom.rosters.readonly
자세한 내용은 승인 가이드를 참고하세요.
달리 명시되지 않는 한 이 페이지의 콘텐츠에는 Creative Commons Attribution 4.0 라이선스에 따라 라이선스가 부여되며, 코드 샘플에는 Apache 2.0 라이선스에 따라 라이선스가 부여됩니다. 자세한 내용은 Google Developers 사이트 정책을 참조하세요. 자바는 Oracle 및/또는 Oracle 계열사의 등록 상표입니다.
최종 업데이트: 2025-07-25(UTC)
[null,null,["최종 업데이트: 2025-07-25(UTC)"],[],[],null,["# Method: invitations.list\n\n- [HTTP request](#body.HTTP_TEMPLATE)\n- [Query parameters](#body.QUERY_PARAMETERS)\n- [Request body](#body.request_body)\n- [Response body](#body.response_body)\n - [JSON representation](#body.ListInvitationsResponse.SCHEMA_REPRESENTATION)\n- [Authorization scopes](#body.aspect)\n- [Try it!](#try-it)\n\nReturns a list of invitations that the requesting user is permitted to view, restricted to those that match the list request.\n\n*Note:* At least one of `userId` or `courseId` must be supplied. Both fields can be supplied.\n\nThis method returns the following error codes:\n\n- `PERMISSION_DENIED` for [access errors](/workspace/classroom/reference/Access.Errors).\n\n### HTTP request\n\n`GET https://classroom.googleapis.com/v1/invitations`\n\nThe URL uses [gRPC Transcoding](https://google.aip.dev/127) syntax.\n\n### Query parameters\n\n| Parameters ||\n|-------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `userId` | `string` Restricts returned invitations to those for a specific user. The identifier can be one of the following: - the numeric identifier for the user - the email address of the user - the string literal `\"me\"`, indicating the requesting user |\n| `courseId` | `string` Restricts returned invitations to those for a course with the specified identifier. |\n| `pageSize` | `integer` Maximum number of items to return. The default is 500 if unspecified or `0`. The server may return fewer than the specified number of results. |\n| `pageToken` | `string` [nextPageToken](/workspace/classroom/reference/rest/v1/invitations/list#body.ListInvitationsResponse.FIELDS.next_page_token) value returned from a previous [list](/workspace/classroom/reference/rest/v1/invitations/list#google.classroom.v1.Invitations.ListInvitations) call, indicating that the subsequent page of results should be returned. The [list](/workspace/classroom/reference/rest/v1/invitations/list#google.classroom.v1.Invitations.ListInvitations) request must be otherwise identical to the one that resulted in this token. |\n\n### Request body\n\nThe request body must be empty.\n\n### Response body\n\nResponse when listing invitations.\n\nIf successful, the response body contains data with the following structure:\n\n| JSON representation |\n|------------------------------------------------------------------------------------------------------------------------------------|\n| ``` { \"invitations\": [ { object (/workspace/classroom/reference/rest/v1/invitations#Invitation) } ], \"nextPageToken\": string } ``` |\n\n| Fields ||\n|-----------------|-----------------------------------------------------------------------------------------------------------------------------------|\n| `invitations[]` | `object (`[Invitation](/workspace/classroom/reference/rest/v1/invitations#Invitation)`)` Invitations that match the list request. |\n| `nextPageToken` | `string` Token identifying the next page of results to return. If empty, no further results are available. |\n\n### Authorization scopes\n\nRequires one of the following OAuth scopes:\n\n- `https://www.googleapis.com/auth/classroom.rosters`\n- `\n https://www.googleapis.com/auth/classroom.rosters.readonly`\n\nFor more information, see the [Authorization guide](/workspace/guides/configure-oauth-consent)."]]