Skip to main content
Glama

list_user_activity

Retrieve a user's recent threads and comments in a course to monitor participation and engagement.

Instructions

List a user's recent threads and comments in a course

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
user_idYesUser ID
course_idYesCourse ID
limitNoMax items
offsetNoPagination offset
filterNoall

Implementation Reference

  • The actual API client implementation for listing user activity.
    async listUserActivity(
      userId: number,
      courseId: number,
      opts: { limit?: number; offset?: number; filter?: string } = {}
    ): Promise<EdActivityItem[]> {
      const params: Record<string, string | number> = {
        courseID: courseId,
      };
      if (opts.limit !== undefined) params.limit = opts.limit;
      if (opts.offset !== undefined) params.offset = opts.offset;
      if (opts.filter) params.filter = opts.filter;
    
      const res = await this.request<{ items: EdActivityItem[] }>(
        "GET",
        `users/${userId}/profile/activity`,
        undefined,
        params
      );
      return res.items ?? [];
  • src/index.ts:423-436 (registration)
    The tool registration and handler wrapper for `list_user_activity`.
    "list_user_activity",
    "List a user's recent threads and comments in a course",
    {
      user_id: z.number().describe("User ID"),
      course_id: z.number().describe("Course ID"),
      limit: z.number().min(1).max(50).default(30).describe("Max items"),
      offset: z.number().min(0).default(0).describe("Pagination offset"),
      filter: z.enum(["all", "thread", "answer", "comment"]).default("all"),
    },
    async ({ user_id, course_id, limit, offset, filter }) => {
      try {
        return ok(await api.listUserActivity(user_id, course_id, { limit, offset, filter }));
      } catch (err) {
        return fail(err);
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations provided, the description carries the full burden. It adds the behavioral qualifier 'recent' implying temporal filtering, but fails to disclose ordering (chronological?), read-only safety, pagination limits, or what constitutes the 'recent' window.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The single-sentence description is appropriately front-loaded with the verb 'List' and contains no wasted words. However, given the tool's complexity (5 parameters including pagination and filtering), it borders on under-specification.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the 80% schema coverage and absence of annotations/output schema, the description meets minimum viability but leaves gaps. It doesn't explain the relationship between filter types ('answer' vs 'comment'), return format, or how pagination behaves with 'recent' items.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 80%, establishing a baseline of 3. The description adds semantic context mapping 'user' to user_id and 'in a course' to course_id, and hints at filter values ('threads and comments' aligns with the enum). However, it doesn't explain pagination strategy or limit constraints beyond the schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool lists a user's threads and comments within a course scope, distinguishing it from sibling tools like list_threads (general listing) and get_user (profile data). It uses specific verbs ('List') and resources ('threads and comments'), though it doesn't explicitly name alternatives.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides no guidance on when to use this tool versus alternatives like get_thread (for specific thread details) or list_threads (for course-wide activity). It lacks prerequisites or exclusion criteria.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/rob-9/edstem-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server