이제 Google 클래스룸 부가기능이 일반적으로 개발자에게 제공됩니다. 자세한 내용은
부가기능 문서를 참고하세요.
AddOnContext
컬렉션을 사용해 정리하기
내 환경설정을 기준으로 콘텐츠를 저장하고 분류하세요.
특정 게시물의 맥락에서 클래스룸 부가기능의 첨부파일 관련 메타데이터입니다.
JSON 표현 |
{
"courseId": string,
"postId": string,
"itemId": string,
"supportsStudentWork": boolean,
// Union field context can be only one of the following:
"studentContext": {
object (StudentContext )
},
"teacherContext": {
object (TeacherContext )
}
// End of list of possible types for union field context .
} |
필드 |
courseId |
string
변경할 수 없습니다. 과정의 식별자입니다.
|
postId (deprecated) |
string
변경할 수 없습니다. 지원 중단되었으므로 대신 itemId 을 사용하세요.
|
itemId |
string
변경할 수 없습니다. 첨부파일이 첨부된 Announcement , CourseWork 또는 CourseWorkMaterial 의 식별자입니다.
|
supportsStudentWork |
boolean
선택사항입니다. 게시물에서 교사가 학생 과제물을 보고 성적을 전달할 수 있는지 여부입니다.
|
통합 필드 context . context 는 다음 중 하나여야 합니다.
|
studentContext |
object (StudentContext )
요청하는 사용자의 학생 역할에 해당하는 부가기능 컨텍스트입니다. 이 속성이 있으면 요청하는 사용자가 과정의 학생임을 의미합니다.
|
teacherContext |
object (TeacherContext )
요청하는 사용자의 교사 역할에 해당하는 부가기능 컨텍스트입니다. 이 속성이 있으면 요청하는 사용자가 과정의 교사임을 의미합니다.
|
StudentContext
JSON 표현 |
{
"submissionId": string
} |
필드 |
submissionId |
string
교사에게 학생 과제물을 표시할 때 학생을 식별하고 성적을 전달하는 데 사용할 사용자의 제출 ID를 요청합니다. supportsStudentWork 이 true 일 때 정확하게 설정됩니다.
|
TeacherContext
이 유형에는 필드가 없습니다.
달리 명시되지 않는 한 이 페이지의 콘텐츠에는 Creative Commons Attribution 4.0 라이선스에 따라 라이선스가 부여되며, 코드 샘플에는 Apache 2.0 라이선스에 따라 라이선스가 부여됩니다. 자세한 내용은 Google Developers 사이트 정책을 참조하세요. 자바는 Oracle 및/또는 Oracle 계열사의 등록 상표입니다.
최종 업데이트: 2025-07-25(UTC)
[null,null,["최종 업데이트: 2025-07-25(UTC)"],[],[],null,["# AddOnContext\n\n- [JSON representation](#SCHEMA_REPRESENTATION)\n- [StudentContext](#StudentContext)\n - [JSON representation](#StudentContext.SCHEMA_REPRESENTATION)\n- [TeacherContext](#TeacherContext)\n\nAttachment-relevant metadata for Classroom add-ons in the context of a specific post.\n\n| JSON representation |\n|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| ``` { \"courseId\": string, \"postId\": string, \"itemId\": string, \"supportsStudentWork\": boolean, // Union field `context` can be only one of the following: \"studentContext\": { object (/workspace/classroom/reference/rest/v1/AddOnContext#StudentContext) }, \"teacherContext\": { object (/workspace/classroom/reference/rest/v1/AddOnContext#TeacherContext) } // End of list of possible types for union field `context`. } ``` |\n\n| Fields ||\n|---------------------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `courseId` | `string` Immutable. Identifier of the course. |\n| `postId` **(deprecated)** | `string` | This item is deprecated! Immutable. Deprecated, use `itemId` instead. |\n| `itemId` | `string` Immutable. Identifier of the `Announcement`, `CourseWork`, or `CourseWorkMaterial` under which the attachment is attached. |\n| `supportsStudentWork` | `boolean` Optional. Whether the post allows the teacher to see student work and passback grades. |\n| Union field `context`. `context` can be only one of the following: ||\n| `studentContext` | `object (`[StudentContext](/workspace/classroom/reference/rest/v1/AddOnContext#StudentContext)`)` Add-on context corresponding to the requesting user's role as a student. Its presence implies that the requesting user is a student in the course. |\n| `teacherContext` | `object (`[TeacherContext](/workspace/classroom/reference/rest/v1/AddOnContext#TeacherContext)`)` Add-on context corresponding to the requesting user's role as a teacher. Its presence implies that the requesting user is a teacher in the course. |\n\nStudentContext\n--------------\n\nRole-specific context if the requesting user is a student.\n\n| JSON representation |\n|------------------------------------|\n| ``` { \"submissionId\": string } ``` |\n\n| Fields ||\n|----------------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `submissionId` | `string` Requesting user's submission id to be used for grade passback and to identify the student when showing student work to the teacher. This is set exactly when `supportsStudentWork` is `true`. |\n\nTeacherContext\n--------------\n\nThis type has no fields.\nRole-specific context if the requesting user is a teacher."]]