All case studies
AI / Education

Secure AI Course Access: A Production MCP Server with Entitlement-Scoped Retrieval

Confidential — under NDA
AI / Education
3 milestones
SCOPED BY ENTITLEMENT01020304bulkexportblockedp95 LATENCY4.58s → 2.80s
Hover or tap a step to explore.

AI clientA student asks the assistant a question about their course material.

Architecture shown in schematic form — client details withheld under NDA.

Overview

The client wanted an AI assistant that answers from paid course material — but only for the courses a given student had actually bought. Two failure modes would each break the business: a student asks about content they never paid for and the assistant answers anyway, or someone uses the assistant to bulk-extract the entire library.

The Challenge

The client wanted an AI assistant that answers from paid course material — but only for the courses a given student had actually bought. Two failure modes would each break the business: a student asks about content they never paid for and the assistant answers anyway, or someone uses the assistant to bulk-extract the entire library. Complicating it further, there was no existing auth or purchase API to plug into.

Our Solution

We built a remote MCP server exposing course-scoped retrieval to an AI client. OAuth 2.1 with PKCE and JWKS was designed and built from scratch, since no auth layer existed. Retrieval is filtered by entitlement server-side rather than in the prompt, so scope cannot be talked around. Anti-bulk-export guardrails and audit logging keep the assistant answering questions rather than surrendering the library. We then profiled the endpoint and parallelised the independent reads — rate limiting, entitlements, embedding, citation and audit — to cut response time.

Results

p95 latency cut 4.58s → 2.80s and median 4.03s → 2.26s under 50 concurrent users

50 concurrent live calls: 50/50 succeeded, zero errors

Entitlement scoping enforced server-side, not by prompt instruction

Handed over with the environment cleaned and the roster verified

Tech Stack

TypeScriptMCP SDKSupabase Edge FunctionspgvectorOAuth 2.1 / PKCE

Have a similar project?

Let's talk about how we can build something like this for you. Free 30-minute consultation, no obligations.

Related Services

More Case Studies

AI / Consumer

Pokepal

Product Startup, United States · 6 weeks

Supports English and Japanese card scanning

Read case study
Web3 / FinTech

Nftcomplete

Product Startup, United States · 8 weeks

5+ marketplace APIs aggregated into one platform

Read case study
Health & Fitness

Efn

Fitness Startup, France · Ongoing (from March 2026)

Live on App Store and Google Play

Read case study
Location Tech / AI

Dripmap

Startup Founder, United States · 5 weeks

MVP live in 5 weeks from signed scope

Read case study
Productivity / Mobile

Notepd

Product Founder, United States · 8 weeks

25,000+ downloads in the first quarter

Read case study
Dating & Matchmaking

Matchportalen

Matchmaking Agency, Norway · 10 weeks

Manual matching workflow replaced with a structured dashboard

Read case study
AI / Productivity

Proposalgenie

SaaS Startup, US · 6 weeks

Live SaaS product at proposalgenie.ai, shipped production-ready

Read case study
Food & Beverage / Hospitality

Culineer

Restaurant Tech Startup, UAE · 8 weeks

50+ restaurants onboarded

Read case study
AI / Document Intelligence

Air-gapped-rag-platform

Confidential — under NDA · 18 days

Runs fully air-gapped on a local model — zero outbound calls, proven end-to-end

Read case study
AI / Field Services

Ai-inspection-pipeline

Confidential — under NDA · Ongoing

Live in production on both the iOS App Store and Google Play

Read case study
DevOps / Observability

Production-debug-no-access

Confidential — under NDA · Fixed scope

Live production fault diagnosed and fixed without hosting or dashboard access

Read case study