MIT API: Search courses
Finds free MIT OpenCourseWare courses matching a topic, in relevance order, optionally limited to a course level or courses with lecture videos.
Unofficial. Not affiliated with or endorsed by MIT.
Inputs
Values from the run on Oct 23, 2026, shown under Output.
- Level optional
level Course level, for example undergraduate.
any (default)
One of
any,undergraduate,graduate.- Topic, required
topic Topic or search words, for example linear algebra.
linear algebra
- Max Results optional
max_results Maximum courses to return, for example 20.
20 (default)
Whole number from 1 to 100.
- With Video Lectures optional
with_video_lectures Only include courses with lecture videos, for example true.
false (default)
True or false.
Input as JSON
{ "topic": "linear algebra"}Output
{ "courses": [ { "level": "Undergraduate", "title": "Linear Algebra", "department": "Mathematics", "course_link": "https://ocw.mit.edu/courses/18-06sc-linear-algebra-fall-2011/" , "description": "This course covers matrix theory and linear algebra, emphasizing topics useful in other disciplines such as physics, economics and social sciences, natural sciences, and engineering. It parallels the combination of theory and applications in Professor Strang’s textbook Introduction to Linear Algebra…", "instructors": [ "Prof. Gilbert Strang" ], "course_number": "18.06SC", "semester_year": "Fall 2011", "available_materials": [ "Lecture Videos", "Lecture Notes", "Problem-solving Videos" ] }, { "level": "Undergraduate", "title": "Linear Algebra", "department": "Mathematics", "course_link": "https://ocw.mit.edu/courses/18-700-linear-algebra-fall-2013/" , "description": "This course offers a rigorous treatment of linear algebra, including vector spaces, systems of linear equations, bases, linear independence, matrices, determinants, eigenvalues, inner products, quadratic forms, and canonical forms of matrices. Compared with 18.06 Linear Algebra, more emphasis is pla…", "instructors": [ "David Vogan" ], "course_number": "18.700", "semester_year": "Fall 2013", "available_materials": [ "Problem Sets" ] }, { "level": "Undergraduate", "title": "A Vision of Linear Algebra", "department": "Mathematics", "course_link": "https://ocw.mit.edu/courses/res-18-010-a-2020-vision-of-linear-algebra-spring-2020/" , "description": "This collection of videos presents Professor Strang’s updated vision of how linear algebra could be taught.", "instructors": [ "Prof. Gilbert Strang" ], "course_number": "RES.18-010", "semester_year": "Spring 2020", "available_materials": [ "Lecture Videos" ] } ]}Code
curl https://api.fous.com/v1/runs \ -H "Authorization: Bearer $FOUS_API_KEY" \ -H "Content-Type: application/json" \ -d '{"method":"ocw.mit.edu/search_courses","input":{"topic":"linear algebra"}}' # Save as fous.py, then run: python3 fous.pyimport json, os, timefrom urllib.error import HTTPErrorfrom urllib.request import Request, urlopenAPI = "https://api.fous.com/v1/runs" KEY = os.environ["FOUS_API_KEY"]HEADERS = { "Authorization": f"Bearer {KEY}", "Content-Type": "application/json" ,}def call(url, body=None): data = json.dumps(body).encode() if body else None request = Request(url, data, HEADERS) try: with urlopen(request, timeout=120) as r: return r.status, json.load(r) except HTTPError as error: message = json.load(error)["error"]["message"] raise RuntimeError(message) from errorstatus, run = call(API, { "method": "ocw.mit.edu/search_courses" , "input": { "topic": "linear algebra" }})# 202: still going after 30 s. Ask again until it ends.while status == 202: time.sleep(2) status, run = call(f"{API}/{run['id']}")print(json.dumps(run["data"], indent=2))// Save as fous.mjs, then run: node fous.mjsconst api = "https://api.fous.com/v1/runs" ;const headers = { Authorization: `Bearer ${process.env.FOUS_API_KEY}`, "Content-Type": "application/json" ,};let response = await fetch(api, { method: "POST", headers, body: JSON.stringify({ "method": "ocw.mit.edu/search_courses" , "input": { "topic": "linear algebra" } }), signal: AbortSignal.timeout(120_000),});let run = await response.json();// 202: still going after 30 s. Ask again until it ends.while (response.status === 202) { await new Promise((done) => setTimeout(done, 2_000)); response = await fetch(`${api}/${run.id}`, { headers }); run = await response.json();}if (!response.ok) throw new Error(run.error.message);console.log(run.data);# Connect your agent to Fous once, over MCP (Streamable HTTP):# https://api.fous.com/mcp# Set FOUS_API_KEY first: create a key at https://app.fous.com/keys.# Claude Codeclaude mcp add \ --scope user \ --transport http fous https://api.fous.com/mcp \ --header "Authorization: Bearer ${FOUS_API_KEY:?Set FOUS_API_KEY to your Fous API key}"# Codexcodex mcp add fous \ --url https://api.fous.com/mcp \ --bearer-token-env-var FOUS_API_KEY# Cursor, VS Code, Windsurf, Cline and morenpx -y add-mcp https://api.fous.com/mcp -g -n fous \ --header "Authorization: Bearer ${FOUS_API_KEY:?Set FOUS_API_KEY to your Fous API key}"# Then ask your agent:# "Use Fous to run ocw.mit.edu/search_courses# with {"topic":"linear algebra"}"Over HTTP, the answer’s data holds the output. A run still going after 30 seconds answers 202 with its id: ask GET /v1/runs/{id} until it ends.
Schema
Input schema
{ "type": "object", "required": [ "topic" ], "properties": { "level": { "enum": [ "any", "undergraduate", "graduate" ], "type": "string", "default": "any", "description": "Course level, for example undergraduate." }, "topic": { "type": "string", "minLength": 1, "description": "Topic or search words, for example linear algebra." }, "max_results": { "type": "integer", "default": 20, "maximum": 100, "minimum": 1, "description": "Maximum courses to return, for example 20." }, "with_video_lectures": { "type": "boolean", "default": false, "description": "Only include courses with lecture videos, for example true." } }}Output schema
{ "type": "object", "required": [ "courses" ], "properties": { "courses": { "type": "array", "items": { "type": "object", "required": [ "title", "course_number", "instructors", "department", "level", "semester_year", "available_materials", "description", "course_link" ], "properties": { "level": { "type": [ "string", "null" ] }, "title": { "type": "string" }, "department": { "type": [ "string", "null" ] }, "course_link": { "type": "string" }, "description": { "type": [ "string", "null" ] }, "instructors": { "type": "array", "items": { "type": "string" } }, "course_number": { "type": [ "string", "null" ] }, "semester_year": { "type": [ "string", "null" ] }, "available_materials": { "type": "array", "items": { "type": "string" } } }, "additionalProperties": false }, "description": "Matching courses in relevance order." } }, "additionalProperties": false}- Price
- 1 credit per completed run (1¢ with pay as you go); failed runs are free.
- Method
ocw.mit.edu/search_courses- Returns
- title, course number, instructors, department, level, semester, materials, description, course link
Use it from your agent
Give your agent this line. It reads SKILL.md, gets a Fous API key and connects the Fous MCP server. Its run then takes the method ocw.mit.edu/search_courses with the inputs above.
Ask your agent
- Find free undergraduate linear algebra courses with lecture videos
- Show me graduate-level machine learning courses from MIT OpenCourseWare
- I need up to 10 courses on organic chemistry, any level
- List MIT open courses about thermodynamics that include video lectures
- Search OCW for beginner-friendly introductory programming courses, limit 5 results
See more
Finds Coursera courses, specializations, professional certificates, degrees and guided projects on a topic, in Coursera's search order.
coursera.org/search_coursesSearches Udemy courses on a topic and returns US visitor prices in USD, ratings, lecture counts and course details.
udemy.com/search_coursesLooks up a Coursera course, specialization or professional certificate by name or link and returns its providers, instructors, rating, enrollment, modules, skills, languages and publicly shown price.
coursera.org/get_courseFinds Open Library books by search words, optionally narrowed by author and subject, sorted by relevance or publication age. Returns work-level results; free_online means at least one edition is marked public or borrowable, not that a loan is available now.
openlibrary.org/search_booksFinds upcoming public Meetup events by topic and city, sorted by start time. Only events that mention the topic are included; external costs and undisclosed venues may not be shown.
meetup.com/search_eventsSearches OpenAlex scholarly works by topic, with optional institution, publication-year and open-access filters, ranked by relevance, citations or newest date.
openalex.org/search_papersFinds public Substack newsletters matching a topic, in Substack's search order. Subscriber counts are null when Substack does not display one.
substack.com/search_newslettersSearches Library of Congress digital collections by keywords, material format and date range, in Library search relevance order. Rights notes may be unavailable for some records.
loc.gov/search_collections