Skip to main content
Glama

get_course_versions

Retrieve historical versions of Swedish educational courses to track curriculum changes, compare old and new syllabi, and analyze how requirements and content have evolved over time.

Instructions

Hämta alla versioner av en kurs.

ANVÄNDNINGSFALL:

  • Spåra förändringar i kursen över tid

  • Jämföra gamla och nya läroplaner

  • Forskning och analys

  • Förstå hur krav och innehåll utvecklats

RETURNERAR: Versionshistorik med versionsnummer och datum.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
codeYes

Implementation Reference

  • The main execution logic for the 'get_course_versions' tool. It calls the syllabus API, formats the response as JSON, handles errors, and returns MCP-compatible content.
    export async function getCourseVersions(params: { code: string; }) { try { const versions = await syllabusApi.getCourseVersions(params.code); return { content: [ { type: 'text' as const, text: JSON.stringify({ code: params.code, totalVersions: versions.totalElements, versions: versions.versions }, null, 2) } ] }; } catch (error) { return { content: [ { type: 'text' as const, text: `Fel vid hämtning av kursversioner: ${error instanceof Error ? error.message : String(error)}` } ], isError: true }; } }
  • Zod schema for validating the input parameters (course code) of the get_course_versions tool.
    export const getCourseVersionsSchema = { code: z.string().describe('Kurskod att hämta versioner för') };
  • Registration of the tool handler in the central tools registry object, mapping 'get_course_versions' to the getCourseVersions function.
    get_course_versions: getCourseVersions,
  • Import statement bringing the getCourseVersions handler into the http-server module for registration.
    import { searchCourses, getCourseDetails, getCourseVersions } from './tools/syllabus/courses.js';
  • Helper API client method that makes the HTTP GET request to Skolverket's syllabus API to retrieve versions for a specific course code.
    async getCourseVersions(code: string): Promise<VersionsResponse> { return this.get<VersionsResponse>(`/v1/courses/${code}/versions`); }

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/isakskogstad/skolverket-syllabus-mcp'

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