Skip to main content
Glama
README.md
<p align="center">
  <picture>
    <source media="(prefers-color-scheme: dark)" srcset="https://img.shields.io/badge/COURSERA-MCP-0056D2?style=for-the-badge&logo=coursera&logoColor=white&labelColor=0056D2">
    <img alt="Coursera MCP" src="https://img.shields.io/badge/COURSERA-MCP-0056D2?style=for-the-badge&logo=coursera&logoColor=white&labelColor=0056D2">
  </picture>
</p>

<p align="center">
  <b>The most advanced MCP server for Coursera.</b><br>
  <sub>279 tools · 5.6 MB binary · async Rust · zero dependencies · rich Obsidian export</sub>
</p>

<p align="center">
  <a href="#setup"><img src="https://img.shields.io/badge/setup-guide-blue?style=flat-square" alt="Setup"></a>
  <a href="#tools-279"><img src="https://img.shields.io/badge/tools-279-green?style=flat-square" alt="Tools"></a>
  <a href="#architecture"><img src="https://img.shields.io/badge/architecture-8_layers-purple?style=flat-square" alt="Architecture"></a>
  <a href="https://github.com/VoidChecksum/coursera-mcp/blob/main/LICENSE"><img src="https://img.shields.io/badge/license-MIT-yellow?style=flat-square" alt="License"></a>
</p>

<p align="center">
  <img src="https://img.shields.io/badge/rust-1.85+-DEA584?style=flat-square&logo=rust&logoColor=white" alt="Rust">
  <img src="https://img.shields.io/badge/MCP-stdio-black?style=flat-square" alt="MCP">
  <img src="https://img.shields.io/badge/tokio-async-blue?style=flat-square" alt="Tokio">
  <img src="https://img.shields.io/badge/binary-5.0MB-brightgreen?style=flat-square" alt="Binary size">
  <img src="https://img.shields.io/badge/deps-zero-success?style=flat-square" alt="Zero dependencies">
</p>

---

```
 ██████╗ ██████╗ ██╗   ██╗██████╗ ███████╗███████╗██████╗  █████╗       ███╗   ███╗ ██████╗██████╗
██╔════╝██╔═══██╗██║   ██║██╔══██╗██╔════╝██╔════╝██╔══██╗██╔══██╗      ████╗ ████║██╔════╝██╔══██╗
██║     ██║   ██║██║   ██║██████╔╝███████╗█████╗  ██████╔╝███████║█████╗██╔████╔██║██║     ██████╔╝
██║     ██║   ██║██║   ██║██╔══██╗╚════██║██╔══╝  ██╔══██╗██╔══██║╚════╝██║╚██╔╝██║██║     ██╔═══╝
╚██████╗╚██████╔╝╚██████╔╝██║  ██║███████║███████╗██║  ██║██║  ██║      ██║ ╚═╝ ██║╚██████╗██║
 ╚═════╝ ╚═════╝  ╚═════╝ ╚═╝  ╚═╝╚══════╝╚══════╝╚═╝  ╚═╝╚═╝  ╚═╝      ╚═╝     ╚═╝ ╚═════╝╚═╝
```

> Give any AI agent — Claude, GPT, or your own — full programmatic access to Coursera.
> Enroll in courses, speedrun lectures, solve quizzes, submit assignments,
> earn certificates, and push them to LinkedIn. All from a single MCP server.

---

## Highlights

| | Feature | How |
|---|---|---|
| 🦀 | **Native Rust binary** | 4.9 MB stripped binary — no Python, no venv, no interpreter overhead |
| ⚡ | **Async I/O** | tokio runtime with zero-copy async HTTP — true non-blocking concurrency |
| 🚀 | **Speedrun entire courses** | `speedrun_course` completes lectures, quizzes, discussions, and graded exams in one call |
| 🔓 | **Freemium bypass** | Auto-detects `enrolledViaFreemiumAt` restrictions and re-enrolls without the flag |
| 🧠 | **Solve quizzes via GraphQL** | Elimination-learning solver: submits, learns from feedback, retries until passing |
| 🤖 | **AI-powered quiz solving** | Gemini LLM picks correct answers on first attempt, elimination as fallback |
| 📝 | **Submit everything** | Written, peer review, discussion prompts, programming assignments — all automated |
| 📊 | **Full analytics** | Learner stats, XP, streaks, goals, module progress, detailed grades, timelines |
| 🔗 | **LinkedIn integration** | Auto-add certificates to your profile with fuzzy duplicate detection |
| 📦 | **Zero runtime deps** | Single 5 MB binary — no Python, no Node.js, no interpreters, no scripting |
| 🔑 | **Cookie-based auth** | No passwords stored — session cookies via [Cookie-Editor](https://cookie-editor.com/) |
| 📓 | **Obsidian export** | Summarize courses into structured study notes and write directly to your Obsidian vault |

### Python → Rust

| Metric | Python (before) | Rust (now) |
|--------|:---:|:---:|
| Runtime size | 397 MB (venv + node_modules) | **5.0 MB** |
| Startup | ~500ms | **<1ms** |
| Idle RAM | ~80 MB | **~5 MB** |
| Concurrency | GIL-bound threads | **tokio async** |
| Tools | 126 | **231** |
| Dependencies | pip + venv + npm + skipera + curl_cffi + scrapling + puppeteer | **None — single binary** |

---

## Prerequisites

### 1. Install Cookie-Editor

All authentication uses browser session cookies. Install **[Cookie-Editor](https://cookie-editor.com/)** to export them:

| Browser | Install |
|:---:|:---|
| <img src="https://img.shields.io/badge/Chrome-4285F4?style=flat-square&logo=googlechrome&logoColor=white"> | [Chrome Web Store](https://chromewebstore.google.com/detail/cookie-editor/hlkenndednhfkekhgcdicdfddnkalmdm) |
| <img src="https://img.shields.io/badge/Firefox-FF7139?style=flat-square&logo=firefoxbrowser&logoColor=white"> | [Firefox Add-ons](https://addons.mozilla.org/en-US/firefox/addon/cookie-editor/) |
| <img src="https://img.shields.io/badge/Edge-0078D7?style=flat-square&logo=microsoftedge&logoColor=white"> | [Edge Add-ons](https://microsoftedge.microsoft.com/addons/detail/cookie-editor/neaplmfkghagebokkhpjpoebhdledlfi) |

### 2. Export Coursera Cookies

1. Log into **[coursera.org](https://www.coursera.org)**
2. Click Cookie-Editor icon → **Export** → copy `CAUTH` and `CSRF3-Token` values
3. Paste into `.env` (see [Setup](#setup))

### 3. Export LinkedIn Cookies *(optional)*

1. Log into **[linkedin.com](https://www.linkedin.com)**
2. Click Cookie-Editor icon → **Export** → copy `li_at` and `JSESSIONID` values
3. Paste into `.env`

---

## Setup

```bash
git clone https://github.com/VoidChecksum/coursera-mcp.git
cd coursera-mcp

# Build the binary
cargo build --release

# Configure secrets
cp .env.example .env
chmod 600 .env
```

### `.env` format

```env
COURSERA_CAUTH=<paste CAUTH cookie value>
COURSERA_CSRF3=<paste CSRF3-Token cookie value>

LINKEDIN_LI_AT=<paste li_at cookie value>
LINKEDIN_JSESSIONID=<paste JSESSIONID value, without quotes>

# Optional: AI quiz solving via Gemini
GEMINI_API_KEY=<your Gemini API key>
```

### Tuning parallelism

```env
COURSERA_MCP_PARALLEL_COURSES=3   # concurrent course speedruns (default 3)
COURSERA_MCP_MAX_CONCURRENT=6     # concurrent Coursera API requests (default 6)
COURSERA_MCP_MAX_WORKERS=6        # concurrent lecture completions (default 6)
COURSERA_MCP_MAX_RETRIES=4        # retry count for transient failures (default 4)
COURSERA_MCP_BACKOFF_BASE=0.5     # backoff base seconds (default 0.5)
```

> [!NOTE]
> When Coursera or LinkedIn logs you out, re-export cookies with Cookie-Editor and update `.env`.

---

## Connect to Your AI Client

<details>
<summary><b>Claude Desktop / Claude Code</b></summary>

Add to your MCP config (`claude_desktop_config.json` or via CLI):

```json
{
  "mcpServers": {
    "coursera": {
      "command": "/path/to/coursera-mcp/run.sh"
    }
  }
}
```

Or via CLI:

```bash
claude mcp add coursera /path/to/coursera-mcp/run.sh
```

</details>

<details>
<summary><b>Other MCP Clients</b></summary>

Any MCP-compatible client that supports stdio transport works.
Point it at `run.sh` which loads `.env` and starts the binary.

</details>

---

## Tools (279)

### Course Discovery & Enrollment

| Tool | Description |
|:---|:---|
| `whoami` | Verify session, return user ID |
| `my_courses` | List enrolled courses (name, slug, role) |
| `search` | Search Coursera catalog via GraphQL |
| `search_courses` | Search with filters (free, difficulty, rating) |
| `course_details` | Full course metadata by slug |
| `course_info` | Course description, partners, instructors, workload, specialization |
| `enroll_course` | Enroll in a course, auto-bypassing freemium restrictions |
| `unenroll_course` | Delete course enrollment |
| `batch_enroll` | Enroll in multiple courses at once with freemium bypass |
| `reset_course_deadlines` | Reset/extend deadlines to unlock expired submissions |

### Speedrunning

| Tool | Description |
|:---|:---|
| `speedrun_course` | Complete an entire course in one call: freemium bypass → lectures → quizzes → discussions → graded exams with elimination learning |
| `speedrun_all` | Speedrun every enrolled course in parallel with bounded concurrency |
| `complete_course` | Improved single-course completion with detailed status |
| `complete_course_lectures` | Mark all lectures, readings, widgets, and labs as completed in parallel |
| `bulk_solve_all` | Solve all failing quizzes across all enrolled courses in parallel |

### Progress, Grades & Certificates

| Tool | Description |
|:---|:---|
| `get_course_grades` | Grades, outcomes, and passing state for all graded items |
| `get_course_progress` | Overall progress % and per-item completion status |
| `get_detailed_grades` | Full grade breakdown with item outcomes and assignment group grades |
| `get_module_progress` | Per-module completion status (completed/in-progress/not-started) |
| `get_home_progress` | Modules completed and modules passed counts |
| `get_graded_assignment_progress` | Assignment group pass/fail status |
| `get_course_completion_status` | Detailed completion: progress %, items done/total, breakdown by type |
| `get_certificates` | All certificates with codes and verification URLs |
| `get_certificate_details` | Certificate grade, grant date, verification URL, preview image |
| `get_certificate_image` | Certificate preview image URL |

### Learner Analytics

| Tool | Description |
|:---|:---|
| `get_learner_stats` | Total XP, items completed, learning minutes, active days, weekly stats |
| `get_weekly_streaks` | Current and target weekly learning streaks |
| `get_weekly_goals` | Day-by-day goal tracking and progress status |
| `get_course_timeline` | Start/end dates, ahead/behind/overdue schedule status |
| `get_profile` | User ID, full name, locale, timezone, profile photos |
| `get_subscription_status` | Coursera Plus/trial/payment status and subscription details |
| `check_product_ownership` | Enrollment type (freemium/paid/Plus), ownership status |
| `get_product_ownership` | Detailed product ownership with expiry dates |
| `send_learning_heartbeat` | Send learning time heartbeat (registers active time on a course item) |
| `get_cohorts` | Social learning cohorts the user belongs to |
| `get_item_deadlines` | Per-item content deadlines (more granular than session deadlines) |
| `get_notifications` | Unread notification center messages |
| `get_id_verification_status` | Identity verification status (for verified certificates) |
| `get_program_memberships` | Program memberships (professional certificates, specializations) |
| `get_course_group_membership` | Study group membership for a course |
| `get_coach_eligibility` | Check if AI Coach is available for a course |
| `check_cheating_flags` | Check academic integrity incidents |

### Skill & Career Intelligence

| Tool | Description |
|:---|:---|
| `get_skill_xp` | Skill area XP breakdown per course (gained vs potential) |
| `get_item_xp` | XP earned vs potential for a specific course item |
| `get_learning_plan` | AI-generated personalized learning plan (role, skills, courses) |
| `get_related_courses` | Related course recommendations |
| `get_interested_careers` | User's interested career roles |
| `get_career_roles` | Career role recommendations for a specialization |
| `get_specialization_progress` | Progress across all courses in a specialization |

### Quiz & Assessment (GraphQL — no browser)

| Tool | Description |
|:---|:---|
| `get_quiz_questions_api` | Fetch questions + option IDs via GraphQL, handles START_NEW_ATTEMPT |
| `submit_quiz_answers_api` | Submit answers, get instant grade + per-question feedback |
| `submit_richtext_answer_api` | Submit RichText / AI-graded essay answers via GraphQL |
| `get_quiz_state` | Check quiz attempt status, grade, and rate-limit info without starting |
| `get_discussion_prompt` | Get discussion prompt content and metadata |
| `submit_discussion_prompt_answer` | Post answer to discussion prompt |
| `solve_quiz` | Solve a single quiz using systematic elimination |
| `smart_solve_quiz` | AI-powered answer selection + elimination fallback |
| `solve_course_quizzes` | Find and solve ALL failing quizzes in a course |
| `get_failing_quizzes` | List all unpassed quizzes in a course |
| `get_quiz_attempt_history` | View persisted elimination data (known correct/incorrect) |
| `discard_quiz_draft` | Discard a stuck quiz draft for fresh attempt |
| `clear_quiz_data` | Wipe persisted quiz answer data |
| `get_submission_status` | Check submission status for any graded item via GraphQL |

### Peer Assignments (Native REST API — no browser)

| Tool | Description |
|:---|:---|
| `get_peer_assignment_api` | Get assignment definition, rubric, and submission schema |
| `get_assignment_instructions_api` | Get instructions for any assignment type (peer/programming/script) |
| `submit_peer_assignment_api` | Submit peer assignment with text/URL parts |
| `get_my_submission_api` | Get your own submission content, status, and grade |
| `submit_written_assignment_api` | Submit simple text-based written assignments |

### Peer Review (Native REST API — no browser)

| Tool | Description |
|:---|:---|
| `get_peer_review_schema_api` | Get review rubric, criteria, and scoring options |
| `get_review_queue_api` | Get available submissions to review |
| `submit_peer_review_api` | Submit a peer review evaluation with scores and feedback |
| `get_review_progress_api` | Check how many reviews done vs required |

### Discussion Forums (Native REST API — no browser)

| Tool | Description |
|:---|:---|
| `get_forum_threads_api` | Get threads with sort/filter (newest, most upvoted, most active) |
| `post_forum_thread_api` | Post new discussion thread |
| `get_thread_replies_api` | Get replies/answers for a thread |
| `reply_forum_thread_api` | Reply to a thread or to a specific answer |
| `upvote_thread_api` | Upvote a forum thread |

### Programming Assignments (Native REST API)

| Tool | Description |
|:---|:---|
| `get_programming_assignment_api` | Get assignment key, parts, and schema |
| `submit_programming_assignment_api` | Submit code via authenticated session (no email/token needed) |
| `get_programming_submission_status` | Check autograder results for latest submission |
| `get_programming_assignment_instructions` | Get programming assignment spec (REST + fallback) |
| `submit_programming_api` | Submit to external autograder (legacy, requires email/token) |

### Content Extraction

| Tool | Description |
|:---|:---|
| `get_video_transcript` | Clean text transcript of any lecture video (VTT dedup) |
| `get_video_download_urls` | Video download URLs and subtitle tracks |
| `get_supplement_content` | Clean text of any reading/supplement |
| `get_lecture_assets` | Downloadable slides, PDFs, and supplementary files |
| `get_course_references` | Glossary and reference materials |
| `get_instructor_notes` | Module-level instructor notes |
| `get_learning_objectives` | Module learning objectives |
| `get_user_notes` | Personal study notes for a course item |
| `create_user_note` | Create study notes on lectures/readings with video timestamps |
| `get_course_content_items` | ALL content items with types, IDs, names, and completion status |

### Course Structure & Navigation

| Tool | Description |
|:---|:---|
| `course_materials` | Full course syllabus: modules, lessons, items |
| `module_items` | Items in a specific module (lectures, quizzes, readings) |
| `get_course_navigation` | Full navigation with deadline status per module |
| `get_course_schedule` | Session deadlines per module and item |
| `get_session_deadlines` | Session deadlines with module and item due dates |
| `get_forum_structure` | Full forum hierarchy (IDs, types, descriptions) |
| `get_specialization_info` | Specialization courses, partners, pricing |
| `get_specialization` | Specialization details + course list |
| `get_ai_grading_eligibility` | Check if AI peer review grading is available |
| `mark_item_completed` | Mark item completed via API |

### Item Completion (Pure REST/GraphQL)

| Tool | Description |
|:---|:---|
| `get_quiz_attempt` | Get quiz questions via GraphQL (no browser needed) |
| `submit_quiz_attempt` | Submit quiz answers via GraphQL |
| `get_assignment_instructions` | Get assignment instructions via REST API |
| `submit_assignment` | Submit assignment via REST API |
| `get_workspace_url` | Get Jupyter/lab workspace URL via REST |
| `get_forum_threads` | Get forum threads via REST |
| `post_forum_thread` | Post thread via REST |
| `get_peer_review_questions` | Get review rubric via REST |
| `submit_peer_review_evaluation` | Submit review via REST |
| `mark_completed` | Mark any item completed via REST/GraphQL completion APIs |

### HTTP Utilities

| Tool | Description |
|:---|:---|
| `scrapling_api_fetch` | Fast Coursera API call via HTTP |
| `scrape_course_page` | Fetch authenticated course pages |
| `scrape_url` | General-purpose URL fetch |

### LinkedIn — Coursera Certificate Sync

| Tool | Description |
|:---|:---|
| `get_linkedin_certifications` | Fetch existing certs on LinkedIn profile |
| `add_certificate_to_linkedin` | Add cert to LinkedIn (auto-skips duplicates) |
| `add_all_certificates_to_linkedin` | Batch-add all Coursera certs (dedup) |
| `remove_linkedin_certification` | Remove a certification from LinkedIn |
| `sync_certificates_to_linkedin` | One-shot sync with optional stale removal |
| `post_certificate_to_linkedin` | Post completion celebration to LinkedIn feed |
| `post_all_certificates_to_linkedin` | Batch-post all not-yet-posted certificates |
| `get_linkedin_profile` | Fetch basic LinkedIn profile info |
| `get_linkedin_feed` | Fetch recent LinkedIn posts |

### LinkedIn — Profile & Identity

| Tool | Description |
|:---|:---|
| `get_linkedin_full_profile` | Full profile: headline, summary, education, experience, skills |
| `get_linkedin_connections` | Paginated connection list |
| `get_linkedin_connection_count` | Connection and follower counts |
| `get_linkedin_skills` | All endorsed skills |
| `get_linkedin_education` | Education entries |
| `get_linkedin_experience` | Work experience entries |
| `update_linkedin_headline` | Update your headline |

### LinkedIn — Search

| Tool | Description |
|:---|:---|
| `linkedin_search_people` | Search for people |
| `linkedin_search_companies` | Search for companies |
| `linkedin_search_jobs` | Search for jobs |
| `linkedin_search_posts` | Search for posts/content |

### LinkedIn — Messaging

| Tool | Description |
|:---|:---|
| `get_linkedin_conversations` | Recent messaging conversations |
| `get_linkedin_messages` | Messages in a conversation |
| `send_linkedin_message` | Send a message |
| `get_linkedin_message_count` | Unread message count |

### LinkedIn — Posts & Feed

| Tool | Description |
|:---|:---|
| `create_linkedin_post` | Create a feed post |
| `react_to_linkedin_post` | React (LIKE, CELEBRATE, SUPPORT, LOVE, INSIGHTFUL, FUNNY) |
| `comment_on_linkedin_post` | Comment on a post |
| `delete_linkedin_post` | Delete a post |
| `get_linkedin_post_reactions` | Get reactions on a post |
| `get_linkedin_post_comments` | Get comments on a post |

### LinkedIn — Network & Invitations

| Tool | Description |
|:---|:---|
| `send_linkedin_connection` | Send a connection request |
| `get_linkedin_pending_invitations` | Sent pending invitations |
| `get_linkedin_received_invitations` | Received invitations |
| `accept_linkedin_invitation` | Accept an invitation |
| `withdraw_linkedin_invitation` | Withdraw a sent invitation |

### LinkedIn — Companies & Jobs

| Tool | Description |
|:---|:---|
| `get_linkedin_company` | Company page details |
| `get_linkedin_company_updates` | Company feed posts |
| `get_linkedin_job_details` | Job posting details |
| `apply_linkedin_job` | Apply to a job |
| `save_linkedin_job` | Save a job |
| `get_linkedin_saved_jobs` | Your saved jobs |

### LinkedIn — Notifications & Analytics

| Tool | Description |
|:---|:---|
| `get_linkedin_notifications` | Notification counts |
| `get_linkedin_notification_feed` | Notification feed |
| `get_linkedin_analytics` | Profile view analytics |
| `get_linkedin_who_viewed` | Who viewed your profile |

### LinkedIn — Groups

| Tool | Description |
|:---|:---|
| `get_linkedin_groups` | Your groups |
| `get_linkedin_group_posts` | Posts from a group |

### LinkedIn — Profile Management

| Tool | Description |
|:---|:---|
| `add_linkedin_education` | Add education entry |
| `add_linkedin_experience` | Add work experience |
| `delete_linkedin_education` | Delete education entry |
| `delete_linkedin_experience` | Delete work experience |
| `add_linkedin_skill` | Add a skill |
| `endorse_linkedin_skill` | Endorse a skill on another profile |

### Study & Planning

| Tool | Description |
|:---|:---|
| `course_content_digest` | Bundle a module's transcripts + readings into one study document |
| `search_course_transcripts` | Full-text search across a course's lecture transcripts |
| `learning_dashboard` | Progress %, certificate, and grade across all enrolled courses |
| `get_upcoming_deadlines` | Session end dates across enrolled courses, soonest first |
| `export_deadlines_ics` | Export deadlines as an importable `.ics` calendar |

### Obsidian Integration

| Tool | Description |
|:---|:---|
| `summarize_module` | Summarize a module's lectures and readings into concise study notes |
| `summarize_course` | Summarize an entire course organized by module |
| `export_course_to_obsidian` | Summarize + write to Obsidian vault with frontmatter, wiki-links, callouts, and tags |
| `export_module_to_obsidian` | Export a single module to Obsidian |
| `export_all_courses_to_obsidian` | Batch export all enrolled courses to Obsidian |

### Reviews & Ratings

| Tool | Description |
|:---|:---|
| `get_course_reviews` | Get aggregate ratings and recent reviews |
| `submit_course_review` | Submit a star rating and text review |
| `get_course_review_highlights` | Get AI-generated review highlights |

### Wishlist & Saved Courses

| Tool | Description |
|:---|:---|
| `get_saved_courses` | Get courses saved to your wishlist |
| `save_course` | Save a course to wishlist |
| `unsave_course` | Remove from wishlist |

### Announcements & Communications

| Tool | Description |
|:---|:---|
| `get_course_announcements` | Get instructor announcements |
| `get_email_preferences` | Get notification settings |
| `update_email_preferences` | Toggle notification types |

### Certificates & Accomplishments

| Tool | Description |
|:---|:---|
| `download_certificate_pdf` | Download certificate as PDF (base64) |
| `get_accomplishments` | Get all accomplishments across courses |
| `share_certificate` | Get public share URLs for a certificate |

### Account & Profile Management

| Tool | Description |
|:---|:---|
| `update_profile` | Update bio, location, company, title |
| `get_account_settings` | Get privacy, language, timezone settings |
| `update_account_settings` | Change language/timezone |

### Session Management

| Tool | Description |
|:---|:---|
| `get_available_sessions` | Get available course sessions |
| `switch_session` | Switch to a different session |
| `get_session_info` | Get current session details |

### Course Categories & Discovery

| Tool | Description |
|:---|:---|
| `get_domains` | Get all course domains/categories |
| `get_subdomains` | Get subcategories for a domain |
| `get_trending_courses` | Get trending/recommended courses |
| `search_suggestions` | Get autocomplete search suggestions |

### Partners & Instructors

| Tool | Description |
|:---|:---|
| `get_partner_info` | Get university/company details |
| `get_instructor_info` | Get instructor biography and courses |
| `get_partner_courses` | Get all courses by a partner |

### Activity & History

| Tool | Description |
|:---|:---|
| `get_recently_viewed` | Get recently viewed courses/items |
| `get_learning_history` | Get learning activity log |
| `get_browsing_history` | Get course browsing history |

### Bookmarks

| Tool | Description |
|:---|:---|
| `get_bookmarks` | Get bookmarked content |
| `create_bookmark` | Bookmark a course item |
| `delete_bookmark` | Remove a bookmark |
| `get_all_notes` | Get all study notes across courses |

### Labs & Workspaces

| Tool | Description |
|:---|:---|
| `get_lab_status` | Get lab session status |
| `start_lab` | Start a lab environment |
| `get_workspace_info` | Get Jupyter/lab workspace details |

### Degree Programs & Professional Certificates

| Tool | Description |
|:---|:---|
| `get_degree_programs` | Get available degree programs |
| `get_professional_certificates` | Get professional cert enrollments |
| `get_specialization_enrollment` | Get specialization memberships |

### Skills & Achievements

| Tool | Description |
|:---|:---|
| `get_skill_scores` | Get skill proficiency scores |
| `get_achievements` | Get badges, streaks, milestones |
| `get_skill_tags` | Get skill tags for a course |

### Batch Operations

| Tool | Description |
|:---|:---|
| `batch_complete_courses` | Complete multiple courses in parallel |
| `batch_get_progress` | Get progress for multiple courses at once |
| `batch_solve_quizzes` | Solve all failing quizzes across multiple courses |

### Honor Code & Compliance

| Tool | Description |
|:---|:---|
| `get_honor_code` | Get honor code text |
| `sign_honor_code` | Sign the honor code agreement |
| `get_honor_code_status` | Check if honor code is signed |

### Financial Aid

| Tool | Description |
|:---|:---|
| `check_financial_aid` | Check financial aid status |
| `get_financial_aid_application` | Get application status |

### Social & Community

| Tool | Description |
|:---|:---|
| `get_course_mates` | Get other learners in a course |
| `get_mentors` | Get course mentors |
| `follow_user` | Follow another learner |
| `get_followers` | Get your followers |
---

## Reverse Engineering

Several tools were built by intercepting live browser traffic and reverse-engineering Coursera's internal APIs:

**Freemium Bypass** — Coursera sets `enrolledViaFreemiumAt` on free enrollments, which causes all `opencourse.v1` video-event and supplement-completion endpoints to return 403. The bypass deletes the enrollment via `DELETE /api/openCourseMemberships.v1/{uid}~{courseId}` (with an empty `{}` body — Akka backend requires it) and re-creates it via `POST` without the freemium flag.

**GraphQL Gateway** — 48+ operations captured from `graphql-gateway`, including `GetLearnerStats`, `WeeklyStreaks_QueryWeeklyStreaks`, `GetLearnerWeeklyGoals`, `GetCourseBranchModuleProgressByCourse`, `GetLearnerCourseTimeline`, `GetMyCertificateByProduct`, `CourseNavigation`, `GetAiGradingEligibilityByCourse`, `CareerRolesQuery`, and `GetProductOwnership`.

**REST APIs** — 61+ endpoints mapped from browser network traffic, including `onDemandCourseViewGrades.v1`, `onDemandReferences.v1`, `onDemandLectureAssets.v1`, `onDemandInstructorNotes.v1`, `userNotes.v1`, `onDemandCourseForums.v1`, `onDemandLearningObjectives.v2`, and `subscriptions.v1`.

**Quiz Solver** — Elimination-learning algorithm reimplemented natively in Rust (replacing the Python `skipera` library): submits answers, gets per-question feedback marking options correct/incorrect, persists learned answers to disk, and retries with improved answers until passing (≥70%). AI-powered first attempt via Gemini LLM, with systematic elimination as fallback. Handles `START_NEW_ATTEMPT`, `RESUME_DRAFT`, rate limits, option ID reshuffling, and all question types (multiple choice, checkbox, text reflect, rich text, numeric).

---

## Architecture

```
coursera-mcp/
├── Cargo.toml           Rust project manifest
├── src/
│   ├── main.rs          Entry point — tokio runtime + MCP stdio transport
│   ├── config.rs        Environment-based configuration
│   ├── client.rs        Async HTTP client (retry, backoff, semaphore, caching)
│   ├── server.rs        ServerHandler — 279-tool dispatch + tool descriptors
│   └── tools/
│       ├── courses.rs       Course CRUD, search, specializations (9 tools)
│       ├── progress.rs      Grades, progress, stats, XP (21 tools)
│       ├── enrollment.rs    Enrollment, lecture completion, items (11 tools)
│       ├── quiz.rs          Full quiz solver engine (10 tools, 3500 lines)
│       ├── speedrun.rs      Speedrun, bulk solve (4 tools)
│       ├── content.rs       Transcripts, supplements, notes (14 tools)
│       ├── forum.rs         Forum threads, replies, upvotes (8 tools)
│       ├── assignments.rs   Peer, programming, written (22 tools)
│       ├── linkedin.rs      LinkedIn Voyager API (53 tools)
│       ├── obsidian.rs      Obsidian vault export (5 tools)
│       ├── dashboard.rs     Dashboard, deadlines, notifications (21 tools)
│       ├── ai_quiz.rs       Gemini LLM quiz solver (1 tool + helpers)
│       ├── automation.rs    Pure REST/GraphQL item completion (1 tool)
│       └── extra.rs         Reviews, wishlist, accounts, social, etc. (53 tools)
├── run.sh               Launcher (just execs the binary)
├── .env                 Your cookies (gitignored)
└── .env.example         Template
```

```
┌──────────────────────────────────────────────────────────────────────┐
│              MCP Clients (Claude / GPT / Custom)                     │
├──────────────────────────────────────────────────────────────────────┤
│            coursera-mcp  ·  rmcp stdio  ·  tokio async               │
├─────────┬─────────┬──────────┬──────────┬──────────┬────────────────┤
│  REST   │ GraphQL │  HTTP    │ LinkedIn │ Gemini   │ Obsidian       │
│  API    │ Gateway │  Client  │  Voyager │  LLM     │  API           │
│  (279   │  (50+   │ (reqwest │          │  API     │                │
│  endpts)│  ops)   │ +rustls) │          │          │  REST :27123   │
└─────────┴─────────┴──────────┴──────────┴──────────┴────────────────┘
       Single 5.6 MB binary — zero runtime dependencies
```

---

## Security

| | |
|---|---|
| **No passwords stored** | Cookie-based auth only — session tokens from your browser |
| **`.env` is gitignored** | Secrets never enter version control |
| **No hardcoded credentials** | All secrets read from environment at runtime |
| **No secret logging** | Cookies are never printed or logged to stdout/stderr |
| **`.env.example` is safe** | Contains only empty placeholders |
| **rustls** | Pure-Rust TLS — no OpenSSL dependency or CVE surface |

> [!CAUTION]
> Never commit your `.env` file. If you accidentally expose cookies, log out of
> Coursera/LinkedIn immediately to invalidate them.

---

## License

[MIT](LICENSE)

---

<p align="center">
  <sub>Built for agents that learn faster than humans.</sub>
</p>