Video summary

What is an API? | Introduction to APIs | FAST API for Machine Learning | CampusX

Main summary

Key takeaways

Technology

Overview / Purpose of the video

  • The creator, Nitesh (CampusX), introduces a new YouTube playlist focused on APIs, specifically FastAPI for Machine Learning.
  • The series is structured to cover:
    • the core concept of APIs first
    • then applying APIs to ML
    • and finally deploying ML-backed APIs

Why APIs matter (core explanation)

  • API definition: A mechanism that lets software components communicate using:
    • defined rules/protocols
    • data formats
  • API as a connector: The video repeatedly presents an API as the “middle layer” between:
    • the front end (user-facing UI)
    • the back end (business logic, database/model access)

Example flow (websites)

  1. A user interacts with the front end
  2. The front end sends a request to the API
  3. The API calls the back end
  4. The back end queries a database
  5. Results return to the API, then back to the front end

Protocols and formats mentioned

  • HTTP is used for communication
  • JSON is the common response data format because it’s language-agnostic (works across Java, Python, PHP, etc.)

Why APIs exist: problem with monolithic architecture

  • The video contrasts pre-API “monolithic architecture” with API-based architecture.
  • In monolithic systems:
    • front end and back end are part of the same application
    • they are tightly coupled
    • changes can break the entire app

Main limitation highlighted

  • It’s difficult to let third-party applications access your internal services/data.

Business/data-sharing example (IRCTC vs travel apps)

  • Without APIs:
    • third parties (e.g., MakeMyTrip/Yatra/Goibibo-style apps) can’t safely access IRCTC’s train schedule database.
  • With APIs:
    • you decouple the backend into an independent service
    • expose it via public API endpoints
    • third-party apps call those endpoints instead of accessing the database directly
  • The API layer can also enforce constraints/security, reducing the risk of malicious requests harming internal systems.

Second major problem APIs solve: multi-platform apps

  • The video describes the impact of the “smartphone revolution”:
    • companies wanted website + Android app + iOS app
  • Without API architecture:
    • teams often end up with separate monolithic back ends and duplicated logic per platform
  • With API architecture:
    • keep one back end and one database
    • build multiple front ends (web/Android/iOS)
    • all front ends communicate through the same API
    • this reduces duplication and maintenance overhead
  • Industry examples cited: Google, Uber, Zomato

APIs in the ML domain (architecture analogies)

  • In ML systems, the “database” role is replaced by the ML model.

ML app example (ChatGPT-style)

  • Train an LLM model and save it (as a model file/binary)
  • Build a back end with something like a /predict function:
    • loads the model
    • takes user input
    • returns predictions
  • Build a front end to send queries and display results

Why APIs matter for ML

  • Without APIs:
    • the ML service is tightly coupled (monolithic), so third parties can’t easily use the model
  • With APIs:
    • expose ML prediction capability via API endpoints
    • external apps (e.g., chatbots, e-commerce summarizers, RAG systems, etc.) call the API
    • responses are returned in JSON over HTTP

Recommender system example (Amazon-style)

  • One ML recommender model powers recommendations
  • Multiple front ends (web/Android/iOS) call the same API layer
  • The API routes requests to the back end → model → returns JSON to the caller

Playlist curriculum plan (structured tutorial roadmap)

The author outlines a 3-part FastAPI + ML curriculum:

  1. Part 1: FastAPI fundamentals (no ML yet)

    • Learn FastAPI as a web/API framework
    • Use a small project to build understanding of core concepts
  2. Part 2: Connect FastAPI with ML

    • Take an already-performing ML model
    • Build an API using FastAPI
    • Goal: move a working model from Jupyter Notebook to a fully functional API
    • May include connecting the API to a website
  3. Part 3: Deployment

    • Deploy the ML API using AWS
    • Teach industry-grade code
    • Dockerize the application
    • Deploy the Dockerized API to AWS

Additional logistics

  • Estimated ~15 videos
  • Plan to complete the playlist in 21–25 days

Main speakers / sources (as stated)

  • Nitesh (CampusX YouTube channel) — the primary speaker and presenter
  • Other sources are not credited beyond general company examples such as:
    • IRCTC, MakeMyTrip, Yatra
    • later examples including Google, Uber, Zomato, Amazon, OpenAI as contextual references

Original video