Skip to content
API documentation
View as MarkdownOpen in Claude

Group challenges

List what has happened in one group

GET
/v1/{organizationId}/group-challenge/{challengeId}/group/{groupId}/activity

Lists what has happened in one group that one of your students is an active member of, newest first: the group created, confirmed, members added, files uploaded, steps submitted, the work sent. It is the log every member of the group can read; notes and details the organizers keep are not included.

Only your own students are named. Every other person — the other members, the teacher, the organizers — is shown by role alone, with studentId and name set to null, and a file’s name only when one of your students uploaded it. What your account did for a student is actor.role: partner with yours: true, and the student in onBehalfOf.

A page at a time: limit is 20 by default and at most 100.

Parameters

Path parameters

NameTypeDescription
organizationIdrequiredstringpattern ^[0-9a-f]{24}$

The organization’s _id: 24 hexadecimal digits, as listOrganizations (GET /v1/organization) lists it.

Example 64b7f0c2a1d3e4f5a6b7c8d9

challengeIdrequiredstring

The group challenge’s _id, from listGroupChallenges.

groupIdrequiredstring

The group’s _id, from listGroupChallengeGroups or a student’s group.

Query parameters

NameTypeDescription
pageoptionalnumber

Page number. Defaults to 1.

Example 1

limitoptionalnumber

Items per page. Defaults to 20, max 100.

Example 20

Responses

200 OK

Success: message is "Activity fetched successfully.".

Body

  • successbooleanrequired

    Always true on a success.

    one oftrue

  • messagestringrequired

    exampleActivity fetched successfully.

  • paginationobject · PaginationMetarequired

    Where one page sits in the whole list.

    4 fields of pagination
    • pagenumberrequired

      The page returned, counting from 1.

      min1example1

    • limitnumberrequired

      Items per page: the limit you sent, 20 if you sent none, and never more than 100.

      min1max100example20

    • totalnumberrequired

      Items across every page.

      min0example57

    • totalPagesnumberrequired

      Pages at this limit: total / limit, rounded up.

      min0example3

  • dataarray of GroupChallengeActivityResponserequired

    9 fields of each item
    • _idstringrequired

      The entry’s id.

      example6650a1b2c3d4e5f6a7b8c9f0

    • atstringrequired

      When it happened (UTC).

      formatdate-timeexample2026-10-20T16:02:11.000Z

    • eventstringrequired

      What happened. New values may be added; ignore one you do not know.

      one ofgroup_createdgroup_renamedmember_addedmember_removedgroup_finalizedgroup_deletedgroup_restoredstep_unlockedfile_uploadedfile_replacedfile_deletedfile_rejectedstep_submittedstep_reopenedfinal_submittedfinal_reverted

      examplestep_submitted

    • actorobject · GroupChallengePersonResponserequired

      Who did it. Your account acting for a student is partner with yours: true.

      4 fields of actor
      • rolestringrequired

        student, teacher, administrator (the organizers), partner (an API account, acting for a student) or system. New values may be added.

        one ofstudentteacheradministratorpartnersystem

        examplestudent

      • studentIdobjectnullablerequired

        The student’s _id, only when they are yours; otherwise null.

        example6650a1b2c3d4e5f6a7b8c9d0

      • nameobjectnullablerequired

        Their name, only when they are yours; otherwise null.

        exampleAda Lovelace

      • yoursbooleanrequired

        Whether this is one of your students, or your account acting for one.

        exampletrue

    • viastringrequired

      Where it was done: the panel, the app, an AI assistant (mcp), this API, or the system itself. New values may be added; ignore one you do not know.

      one ofpanelappmcpapisystem

      exampleapi

    • onBehalfOfobject · GroupChallengePersonResponsenullablerequired

      Whom it was done for: the student a partner acted for, or the teacher an administrator acted for. null otherwise.

      4 fields of onBehalfOf
      • rolestringrequired

        student, teacher, administrator (the organizers), partner (an API account, acting for a student) or system. New values may be added.

        one ofstudentteacheradministratorpartnersystem

        examplestudent

      • studentIdobjectnullablerequired

        The student’s _id, only when they are yours; otherwise null.

        example6650a1b2c3d4e5f6a7b8c9d0

      • nameobjectnullablerequired

        Their name, only when they are yours; otherwise null.

        exampleAda Lovelace

      • yoursbooleanrequired

        Whether this is one of your students, or your account acting for one.

        exampletrue

    • subjectobject · GroupChallengePersonResponsenullablerequired

      The student it was about (added or removed), or null.

      4 fields of subject
      • rolestringrequired

        student, teacher, administrator (the organizers), partner (an API account, acting for a student) or system. New values may be added.

        one ofstudentteacheradministratorpartnersystem

        examplestudent

      • studentIdobjectnullablerequired

        The student’s _id, only when they are yours; otherwise null.

        example6650a1b2c3d4e5f6a7b8c9d0

      • nameobjectnullablerequired

        Their name, only when they are yours; otherwise null.

        exampleAda Lovelace

      • yoursbooleanrequired

        Whether this is one of your students, or your account acting for one.

        exampletrue

    • stepobject · GroupChallengeActivityStepResponsenullablerequired

      The step it was about, or null.

      2 fields of step
      • _idstringrequired

        The step’s id.

        example6650a1b2c3d4e5f6a7b8c9ee

      • orderobjectnullablerequired

        Its position when the entry was written.

        example1

    • fileobject · GroupChallengeActivityFileResponsenullablerequired

      The file it was about, or null.

      2 fields of file
      • _idstringrequired

        The file’s id.

        example6650a1b2c3d4e5f6a7b8c9ef

      • nameobjectnullablerequired

        Its name, only when one of your students did what the entry records; otherwise null.

        exampleproposal.pdf

Headers

X-RateLimit-Limit integer

Requests your account may make to this operation per window (100).

X-RateLimit-Remaining integer

Requests left in the current window.

X-RateLimit-Reset integer

Seconds until the current window ends.

Example

{
  "success": true,
  "message": "Activity fetched successfully.",
  "pagination": {
    "page": 1,
    "limit": 20,
    "total": 57,
    "totalPages": 3
  },
  "data": [
    {
      "_id": "6650a1b2c3d4e5f6a7b8c9f0",
      "at": "2026-10-20T16:02:11.000Z",
      "event": "step_submitted",
      "actor": {
        "role": "student",
        "studentId": "6650a1b2c3d4e5f6a7b8c9d0",
        "name": "Ada Lovelace",
        "yours": true
      },
      "via": "api",
      "onBehalfOf": {
        "role": "student",
        "studentId": "6650a1b2c3d4e5f6a7b8c9d0",
        "name": "Ada Lovelace",
        "yours": true
      },
      "subject": {
        "role": "student",
        "studentId": "6650a1b2c3d4e5f6a7b8c9d0",
        "name": "Ada Lovelace",
        "yours": true
      },
      "step": {
        "_id": "6650a1b2c3d4e5f6a7b8c9ee",
        "order": 1
      },
      "file": {
        "_id": "6650a1b2c3d4e5f6a7b8c9ef",
        "name": "proposal.pdf"
      }
    }
  ]
}

Example request

# $TOKEN: a short-lived token you minted with your API key and secret
curl -sS 'https://api.main-team.org/v1/<organizationId>/group-challenge/<challengeId>/group/<groupId>/activity?page=1&limit=20' \
  -H "Authorization: Bearer $TOKEN"

Search the API documentation

Guides, endpoints by name, path or permission, and error codes such as not_found.