Skip to content
Scalekit Docs
Talk to an Engineer Dashboard

Connect AI agents to Google Classroom

Scalekit connector
Open markdown

The Google Classroom connector lets your AI agent act in each user's Google Classroom account. Each user signs in to Google Classroom once, and Scalekit stores and refreshes their tokens, so your agent never handles credentials. It comes with 76 tools.

Tools
76
What they doRead · write · destructive
29 · 33 · 1429 read33 write14 destructive
Users sign in with
OAuth app
Your own Google app

Setup

  1. Install the SDK

    Terminal window
    npm install @scalekit-sdk/node dotenv
  2. Set your credentials

    Add your Scalekit credentials to your .env file. Find values in app.scalekit.com > Developers > API Credentials.

    .env
    SCALEKIT_ENVIRONMENT_URL=<your-environment-url>
    SCALEKIT_CLIENT_ID=<your-client-id>
    SCALEKIT_CLIENT_SECRET=<your-client-secret>
  3. Create the Google Classroom connection

    In AgentKit > Connections, create a Google Classroom connection and copy its redirect URI. The name you give it is the connection_name your code passes. See Configure connections.

  4. Register a Google OAuth app

    Google Classroom connections use your own OAuth app. Register one with Google and add the redirect URI you copied.

    Then enter the app's Client ID and Client Secret on the Google Classroom connection.

  5. Authorize a user and make your first call

    quickstart.mts
    import { ScalekitClient } from '@scalekit-sdk/node'
    import 'dotenv/config'
    import { createInterface } from 'node:readline/promises'
    const scalekit = new ScalekitClient(
    process.env.SCALEKIT_ENVIRONMENT_URL,
    process.env.SCALEKIT_CLIENT_ID,
    process.env.SCALEKIT_CLIENT_SECRET,
    )
    const actions = scalekit.actions
    const connector = 'googleclassroom'
    const identifier = 'user_123'
    // Generate an authorization link for the user
    const { link } = await actions.getAuthorizationLink({ connectionName: connector, identifier })
    console.log('Authorize Google Classroom:', link)
    const rl = createInterface({ input: process.stdin, output: process.stdout })
    await rl.question('Press Enter after authorizing...')
    rl.close()
    // Make your first call
    const result = await actions.executeTool({
    connector,
    identifier,
    toolName: 'googleclassroom_courses_list',
    toolInput: {},
    })
    console.log(result)
    Terminal window
    npx tsx quickstart.mts

    Each user signs in once. See Authorize a user for the full flow and statuses.

Tools

Pass the exact name to execute_tool
Try in PlaygroundRequest a tool
  • googleclassroom_announcement_getRetrieve a single announcement from a Google Classroom course by its ID.Read-only

    Get Announcement

    Retrieve a single announcement from a Google Classroom course by its ID. Returns the announcement's text, state, assignee mode, materials, and timestamps. Use this when you already know the announcement's ID; use announcements_list to browse or find announcements in a course.

    Inputs

    announcement_idstringrequired
    Classroom-assigned identifier of the announcement to retrieve, unique per course. Example: 167869283124.
    course_idstringrequired
    Identifier of the course the announcement belongs to. This can be either the Classroom-assigned course ID (a numeric string) or an alias (e.g. prefixed with 'd:' for a domain-scoped alias or 'p:' for a project-scoped alias).
  • googleclassroom_announcements_listList announcements posted to a Google Classroom course, optionally filtered by state and sorted.Read-only

    List Announcements

    List announcements posted to a Google Classroom course, optionally filtered by state and sorted. Returns a page of announcements plus a nextPageToken for fetching further pages. Use this to browse or search announcements in a course; use announcement_get when you already know a specific announcement's ID. Students only ever see PUBLISHED announcements regardless of the filter; teachers and domain administrators see all states.

    Inputs

    course_idstringrequired
    Identifier of the course whose announcements to list. This can be either the Classroom-assigned course ID (a numeric string) or an alias (e.g. prefixed with 'd:' for a domain-scoped alias or 'p:' for a project-scoped alias).
    announcement_statesarray
    Restrict returned announcements to these states. Pass one or more values to include multiple states. If omitted, only PUBLISHED announcements are returned by default. Example: PUBLISHED.
    order_bystring
    Sort ordering for results, as a comma-separated list of fields with an optional 'asc' or 'desc' direction keyword. The only supported field is updateTime. If omitted, results are returned in an unspecified order. Example: 'updateTime desc'.
    page_sizeinteger
    Maximum number of announcements to return per page. Zero or unspecified lets the server assign a maximum; the server may return fewer than requested. Example: 20.
    page_tokenstring
    nextPageToken value returned by a previous call to this endpoint, used to fetch the next page of results. Omit to fetch the first page. Example: 'CAoQABoQ'.
  • googleclassroom_course_aliases_listList all aliases of a Google Classroom course, paginated.Read-only

    List Course Aliases

    List all aliases of a Google Classroom course, paginated. Returns an array of alias objects (each with an alias string) along with a next-page token when more results exist. Use this to discover the alias strings you'd pass to course_alias_delete, or to check whether a course already has an alias before creating a new one with course_alias_create.

    Inputs

    course_idstringrequired
    Identifier of the course whose aliases should be listed. This can be either the Classroom-assigned numeric course ID or an existing alias for the course.
    page_sizeinteger
    Maximum number of aliases to return. If zero or unspecified, the server may assign a maximum. The server may return fewer than the specified number of results.
    page_tokenstring
    The nextPageToken value returned from a previous course_aliases_list call, used to retrieve the subsequent page of results. Omit this to fetch the first page.
  • googleclassroom_course_getRetrieve a single Google Classroom course by its Classroom-assigned ID or alias.Read-only

    Get Course

    Retrieve a single Google Classroom course by its Classroom-assigned ID or alias. Returns the course's name, section, description, room, state, owner ID, enrollment codes, and other course details. Use this when you already know the course ID or alias; use a list or search tool to find a course otherwise.

    Inputs

    idstringrequired
    Identifier of the course to return. This can be either the Classroom-assigned course ID (a numeric string) or an alias (e.g. prefixed with 'd:' for a domain-scoped alias or 'p:' for a project-scoped alias).
  • googleclassroom_course_get_grading_period_settingsRetrieve the grading period settings configured for a course in Google Classroom.Read-only

    Get Grading Period Settings

    Retrieve the grading period settings configured for a course in Google Classroom. Returns whether grading periods apply to existing coursework (applyToExistingCoursework) and the full ordered list of grading periods (id, title, startDate, endDate) defined for the course. Use this to inspect the current grading periods before calling course_update_grading_period_settings, since that call replaces the entire grading-periods list.

    Inputs

    course_idstringrequired
    Identifier of the course whose grading period settings to retrieve. This can be either the Classroom-assigned course ID (a numeric string) or an alias.
  • googleclassroom_courses_listList courses in Google Classroom that the requesting user is permitted to view, optionally filtered by teacher, student, or course state.Read-only

    List Courses

    List courses in Google Classroom that the requesting user is permitted to view, optionally filtered by teacher, student, or course state. Returns a page of Course resources (id, name, section, room, state, owner, and other course details) plus a nextPageToken for fetching subsequent pages. Use this to browse or filter courses; use course_get instead when you already know a specific course's id or alias.

    Inputs

    course_statesarray
    Restrict returned courses to those in one or more of these states. If omitted, courses in any state are returned.
    page_sizeinteger
    Maximum number of courses to return per page. Zero or unset lets the server assign a default page size; the server may return fewer than requested.
    page_tokenstring
    Pagination token from a previous call's nextPageToken, used to fetch the next page of results. Must be used with request parameters identical to the call that produced it.
    student_idstring
    Restrict returned courses to those having a student with this identifier. Accepts a numeric user id, an email address, or the literal string "me". If set, teacher_id must be left empty.
    teacher_idstring
    Restrict returned courses to those having a teacher with this identifier. Accepts a numeric user id, an email address, or the literal string "me". If set, student_id must be left empty.
  • googleclassroom_coursework_getRetrieve a single course work item (assignment, short-answer question, or multiple-choice question) from a Google Classroom course by its ID.Read-only

    Get Course Work

    Retrieve a single course work item (assignment, short-answer question, or multiple-choice question) from a Google Classroom course by its ID. Returns the CourseWork resource: title, description, work type, state, due date/time, max points, and materials. Use this when you already know the course work ID; use coursework_list to browse or search for items in a course.

    Inputs

    course_idstringrequired
    Identifier of the course. This can be either the Classroom-assigned course identifier or an alias.
    coursework_idstringrequired
    Identifier of the course work to return.
  • googleclassroom_coursework_listList course work items in a Google Classroom course, optionally filtered by state and sorted, with pagination.Read-only

    List Course Work

    List course work items in a Google Classroom course, optionally filtered by state and sorted, with pagination. Returns an array of CourseWork resources plus a nextPageToken for further pages. Students only see PUBLISHED items; teachers and admins see all. Use this to browse or enumerate a course's assignments and questions; use coursework_get when you already know a specific course work ID.

    Inputs

    course_idstringrequired
    Identifier of the course. This can be either the Classroom-assigned course identifier or an alias.
    course_work_statesarray
    Restrict results to course work with these statuses. If unspecified, only PUBLISHED items are returned. Pass multiple values to include more than one state.
    order_bystring
    Comma-separated list of fields to sort by, each optionally followed by 'asc' or 'desc'. Supported fields are updateTime and dueDate. If not specified, updateTime desc is the default (most recently updated first); example: 'dueDate desc,updateTime asc'.
    page_sizeinteger
    Maximum number of items to return. Zero or unspecified lets the server choose a maximum; the server may return fewer than requested.
    page_tokenstring
    The nextPageToken value returned from a previous list call, to fetch the next page of results. The request must otherwise be identical to the one that produced this token.