User eligibility

While any developer can make requests to the Google Classroom API, some Google Classroom features are only available to certain users. Each feature can have different requirements, such as having a certain Google Workspace for Education license type. For a detailed breakdown of features at each Google Workspace for Education license level, see the editions comparison page.

Features with eligibility requirements

The following Classroom API features are only available to eligible users:

Determine user capabilities

Requests to Classroom API are made on behalf of individual users. Therefore, you should check whether a user has the appropriate capabilities before issuing API requests with eligibility requirements.

To determine whether a user has a particular capability, make an API request to the checkUserCapability method. Include the appropriate Capability type for the Classroom feature you intend to use. Specify the appropriate Capability for each feature:

To see if the user... Capability
Can create or modify a Classroom add-on attachment associated with the Google Cloud project of the OAuth client ID used to make the request CREATE_ADD_ON_ATTACHMENT
Can modify grading period settings UPDATE_GRADING_PERIOD_SETTINGS
Can create, modify, or delete a rubric CREATE_RUBRIC

Next, check the allowed field in the response. If allowed is true, then the user has access to the chosen Capability. You can then make API requests related the Capability on behalf of the user.