Skip to main content

Datacurso Ratings plugin permissions

The following table summarises the main permissions used by the Datacurso Ratings plugin and their default role assignments.

Technical permissionDescriptionDefault roles
local/datacurso_ratings:viewcoursereportView the Datacurso ratings report inside a course and call the supporting AJAX services (activity comments, AI summaries, etc.).Manager, Editing teacher, Teacher, Course creator
local/datacurso_ratings:viewgeneralreportIntended to guard the global ratings dashboard and plugin settings, although the current UI still checks moodle/site:config.Manager
local/datacurso_ratings:generateanalysisgeneralMarks users who are allowed to generate the global AI analysis when contacting the Datacurso AI provider.Manager
local/datacurso_ratings:generateanalysiscourseMarks users who are allowed to trigger the course-level AI analysis endpoints.Manager, Editing teacher, Course creator
local/datacurso_ratings:generateanalysisactivityMarks users who are allowed to request AI analyses focused on individual activities.Manager, Editing teacher, Course creator

local/datacurso_ratings:viewcoursereport

Allows users to access the Activity ratings report inside each course (local/datacurso_ratings/admin/report_ratings_course.php) and the navigation shortcut injected via local_datacurso_ratings_extend_navigation_course() in lib.php.

With this permission, a user can:

  • Open the in-course report UI to inspect likes, dislikes, and comments per activity.
  • Use the AJAX services that power the report (get_activity_comments, get_ai_analysis_comments, get_ai_analysis_course, get_ratings_report_course, and related AMD modules), because each service checks this capability before returning data.
  • Be included in the course picker returned by get_courses_by_category, which allows the global dashboard to list only courses where the user has this capability or moodle/course:view.

local/datacurso_ratings:viewgeneralreport

Designed to protect the site-wide ratings dashboard and settings (admin/report.php and settings.php). The string description ("Manage datacurso ratings settings") reflects that intent. At the moment those entry points still call require_capability('moodle/site:config'), so this capability is not enforced yet. You can assign it to custom roles in preparation for when the plugin switches the checks to this capability.

local/datacurso_ratings:generateanalysisgeneral

Identifies who is allowed to ask the Datacurso AI provider for a global analysis (/rating/general).

With this permission a user can:

  • Request global AI summaries once the Datacurso AI service is configured.

local/datacurso_ratings:generateanalysiscourse

Marks the users that can request course-level AI analyses through the Datacurso AI services (/rating/course).

With this permission, a user can:

  • Generate the "AI analysis" visible in the course report once the permissions are granted.

local/datacurso_ratings:generateanalysisactivity

Complements the previous permission by signalling which users can send activity-level AI analysis requests (/rating/query).

With this permission, a user can:

  • Trigger the activity comment analysis widget that appears next to the ratings report once the AI integration is enabled.