Skip to content

AndriiPiatakha/udemy-coupons-courses-instructors

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 

Repository files navigation

Udemy Coupons, Courses & Instructors Data FREE API (Unofficial)

> Independent project. Not affiliated with or endorsed by Udemy, Inc. Data is sourced from partner submissions and our ecosystem.

Overview

The API provides structured access to active coupons, course metadata, and instructor profiles. Ideal for deal aggregators, learning apps, analytics dashboards, and bots. Built for speed with cursor (keyset) pagination and lightweight JSON.

🆓 FREE API — use instantly on RapidAPI 🚀

Udemy API Logo


Endpoints

1) GET /coupons.php

List the latest active coupons with light course cards and authors.

Default sorting: created_at DESC (newest first)

Query parameters

Name Type Default Description
q string Search in course name/headline
language string Filter by course language (e.g., English, Spanish)
topic string Filter by course topic or primary_subcategory
rating_gte number Minimum course rating (e.g., 4.5)
valid_from YYYY-MM-DD today Only coupons with valid_until >= valid_from (or NULL)
is_active int 1 1 = active only
limit int 10 Page size (max 10)
cursor string Base64 cursor for next page

Response

{
  "ok": true,
  "page": { "limit": 10, "next_cursor": "MjAyNS0xMC0xNCB8MjgzOA==", "has_more": true },
  "items": [
    {
      "coupon": {
        "id": 2838,
        "code": "OCT12FREE",
        "percent_off": 100,
        "discount": { "price": 0.0, "currency": "USD" },
        "regular":  { "price": 74.99, "currency": "USD" },
        "valid_until": "2025-10-18 17:24:00",
        "is_active": 1,
        "created_at": "2025-10-13 18:31:26"
      },
      "course": {
        "id": 6871051,
        "slug": "python-masterclass",
        "name": "Learn Python in 2025",
        "rating": 4.8,
        "duration_hours": 7.5,
        "language": "en",
        "topic": "Programming",
        "image_url": "https://img-c.udemycdn.com/...",
        "url_with_coupon": "https://www.udemy.com/course/python-masterclass/?couponCode=OCT12FREE",
        "authors": [
          { "id": 314059795, "name": "John Doe", "url": "https://www.udemy.com/user/johndoe/" }
        ]
      }
    }
  ]
}

Notes

  • cursor is returned in every response if has_more=true. Pass it back as ?cursor=... for the next page.
  • URLs are normalized to https://www.udemy.com/... and include couponCode when provided.

2) GET /course.php

Get full details for a single course plus authors and the latest active coupon.

Query: id (required)

Example

GET /api/v1/course?id=6871051

Response

{
  "ok": true,
  "data": {
    "course": {
      "id": 6871051,
      "slug": "building-hpe-hybrid-it-solutions-practice-exam-i",
      "url": "https://www.udemy.com/course/building-hpe-hybrid-it-solutions-practice-exam-i/",
      "url_with_coupon": "https://www.udemy.com/course/building-hpe-hybrid-it-solutions-practice-exam-i/?couponCode=OCT12FREE",
      "type": "course",
      "name": "Building HPE Hybrid IT Solutions Practice Exam",
      "headline": "High-quality practice exams...",
      "rating": 0.0,
      "course_price": "$74.99",
      "description": "<p>HTML description…</p>",
      "students_amount": 48,
      "primary_category": "IT & Software",
      "primary_subcategory": "IT Certifications",
      "topic": null,
      "duration_minutes": 0,
      "duration_hours": 0.0,
      "locale": "en_US",
      "language": "English",
      "is_featured": 0,
      "status": "published",
      "image_url": "https://img-c.udemycdn.com/course/750x422/6871051_59b7.jpg",
      "created_at": "2025-10-13 18:31:22",
      "updated_at": "2025-10-13 18:31:22"
    },
    "authors": [
      {
        "id": 314059795,
        "display_name": "SkillUp • Trusted by 16,000+ Students Globally",
        "job_title": "Udemy Premium Instructor | Udemy Instructor Partner",
        "url": "https://www.udemy.com/user/b-aaron/",
        "created_at": "2025-09-21 09:03:50",
        "updated_at": "2025-10-13 18:31:22"
      }
    ],
    "coupon": {
      "id": 2838,
      "course_id": 6871051,
      "code": "OCT12FREE",
      "percent_off": 100,
      "discount_price": 0.0,
      "discount_currency": "USD",
      "regular_price": 74.99,
      "regular_currency": "USD",
      "valid_until": "2025-10-18 17:24:00",
      "is_active": 1,
      "created_at": "2025-10-13 18:31:26",
      "updated_at": "2025-10-13 18:31:26"
    }
  }
}

Errors

  • Not found → 404 { ok:false, error:"course_not_found" }
  • Missing/invalid id400 { ok:false, error:"Bad request: id is required..." }

3) GET /authors.php

Search/list authors or get one author with optional course list.

Query parameters

Name Type Default Description
id int If set, returns single author details
include string courses to include author’s courses (with latest free coupon per course)
q string Search by name/job title
limit int 10 Page size (max 10 on Free plan)
cursor string Base64 cursor; for lists uses author_id, for author-courses uses course_id

Examples

GET /api/v1/author?q=python
GET /api/v1/author?id=542659
GET /api/v1/author?id=542659&include=courses&limit=10

Pagination

  • Authors list: ordered by id DESC; cursor = base64(author_id).
  • Author’s courses: ordered by course.id DESC; cursor = base64(course_id).

> Free plan is strictly for experiments and non‑commercial use. Commercial/production usage requires a paid plan.


Status Codes

  • 200 OK – success
  • 400 Bad Request – invalid/missing parameters
  • 403 Forbidden – invalid proxy secret
  • 404 Not Found – resource does not exist
  • 405 Method Not Allowed – non‑GET request
  • 429 Too Many Requests – rate limit exceeded
  • 500 Server Error – unexpected failure

Best Practices

  • Always follow the cursor for pagination (don’t use offset)
  • Respect rate limits and apply client‑side retry with backoff

Legal

  • Independent project; not affiliated with Udemy, Inc.
  • All course and instructor content remains the property of their respective owners.
  • Use is governed by the Terms of Use. The provider may suspend access for abuse or violations.

Udemy Coupons, Courses & Instructors Data API – Docs

> Independent project. Not affiliated with or endorsed by Udemy, Inc. Data is sourced from partner submissions and our ecosystem.
> Free plan: experiments & non‑commercial use only. Paid plans required for commercial/production use.


Base Info

  • Format: JSON (UTF‑8)
  • Pagination: Cursor (keyset) pagination where applicable.

Endpoints

1) GET /coupons.php

List the latest active coupons with lightweight course cards and authors.

Default order: created_at DESC, id DESC (newest first)

Query Parameters

Name Type Required Default Example Description
q string python Search in course name and headline
language string English Filter by full language name (English names only). Case-insensitive.
topic string Data Science Filter by course topic or primary_subcategory
rating_gte number 4.5 Minimum course rating
valid_from YYYY-MM-DD today 2025-10-10 Only coupons with valid_until &gt;= valid_from (or NULL)
is_active int 1 1 1 = only active coupons
limit int 10 10 Page size (server-enforced max may be 10)
cursor string MjAyNS0xMC0xMyAxODozMToyNnwyODM4 Base64 cursor for next page.

Request Examples

# Basic list
GET https://YOUR_HOST/api/v1/coupons?limit=10

# With filters
GET https://YOUR_HOST/api/v1/coupons?q=python&language=English&rating_gte=4.5&limit=10

# Next page
GET https://YOUR_HOST/api/v1/coupons?cursor=MjAyNS0xMC0xMyAxODozMToyNnwyODM4

Success Response (200)

{
  "ok": true,
  "page": {
    "limit": 10,
    "next_cursor": "MjAyNS0xMC0xMyAxODozMToyNnwyODM4",
    "has_more": true
  },
  "items": [
    {
      "coupon": {
        "id": 2838,
        "code": "OCT12FREE",
        "percent_off": 100,
        "discount": { "price": 0.0, "currency": "USD" },
        "regular":  { "price": 74.99, "currency": "USD" },
        "valid_until": "2025-10-18 17:24:00",
        "is_active": 1,
        "created_at": "2025-10-13 18:31:26"
      },
      "course": {
        "id": 6871051,
        "slug": "python-masterclass",
        "name": "Learn Python in 2025",
        "rating": 4.8,
        "duration_hours": 7.5,
        "language": "English",
        "topic": "Programming",
        "image_url": "https://img-c.udemycdn.com/course/750x422/6871051_59b7.jpg",
        "url_with_coupon": "https://www.udemy.com/course/python-masterclass/?couponCode=OCT12FREE",
        "authors": [
          { "id": 314059795, "name": "John Doe", "url": "https://www.udemy.com/user/johndoe/" }
        ]
      }
    }
  ]
}

Notes

  • next_cursor appears when has_more=true. Pass it back as ?cursor=... to fetch the next page.
  • All outgoing course and author links are normalized to https://www.udemy.com/; coupon URLs include ?couponCode=... when present.

2) GET /course.php

Return full details for a single course by id, including authors and the latest active coupon (if any).

Query Parameters

Name Type Required Example Description
id int 6871051 Course ID. Returns 404 if not found.

Request Example

GET https://YOUR_HOST/api/v1/course?id=6871051

Success Response (200)

{
  "ok": true,
  "data": {
    "course": {
      "id": 6871051,
      "slug": "building-hpe-hybrid-it-solutions-practice-exam-i",
      "url": "https://www.udemy.com/course/building-hpe-hybrid-it-solutions-practice-exam-i/",
      "url_with_coupon": "https://www.udemy.com/course/building-hpe-hybrid-it-solutions-practice-exam-i/?couponCode=OCT12FREE",
      "type": "course",
      "name": "Building HPE Hybrid IT Solutions Practice Exam",
      "headline": "High-quality practice exams to boost confidence...",
      "rating": 0.0,
      "course_price": "$74.99",
      "description": "<p>HTML description…</p>",
      "students_amount": 48,
      "primary_category": "IT & Software",
      "primary_subcategory": "IT Certifications",
      "topic": null,
      "duration_minutes": 0,
      "duration_hours": 0.0,
      "locale": "en_US",
      "language": "English",
      "is_featured": 0,
      "status": "published",
      "image_url": "https://img-c.udemycdn.com/course/750x422/6871051_59b7.jpg",
      "created_at": "2025-10-13 18:31:22",
      "updated_at": "2025-10-13 18:31:22"
    },
    "authors": [
      {
        "id": 314059795,
        "display_name": "SkillUp • Trusted by 16,000+ Students Globally",
        "job_title": "Udemy Premium Instructor | Udemy Instructor Partner",
        "url": "https://www.udemy.com/user/b-aaron/",
        "created_at": "2025-09-21 09:03:50",
        "updated_at": "2025-10-13 18:31:22"
      }
    ],
    "coupon": {
      "id": 2838,
      "course_id": 6871051,
      "code": "OCT12FREE",
      "percent_off": 100,
      "discount_price": 0.0,
      "discount_currency": "USD",
      "regular_price": 74.99,
      "regular_currency": "USD",
      "valid_until": "2025-10-18 17:24:00",
      "is_active": 1,
      "created_at": "2025-10-13 18:31:26",
      "updated_at": "2025-10-13 18:31:26"
    }
  }
}

Errors

  • 400 – missing/invalid id
  • 404course_not_found
  • 403, 405, 429, 500 – see Common Errors below

3) GET /author.php

Search/list authors or fetch a single author by id. Optional include of the author’s courses (with normalized Udemy URLs and latest free coupon per course).

Modes

  • List/Search: omit id, use q to search. Cursor = base64 ordered by author.id DESC.
  • Details: pass id. Add include=courses to fetch author’s courses. Cursor = base64 ordered by course.id DESC.

Query Parameters

Name Type Required Default Example Description
id int 542659 Details mode: single author by ID
include string courses In details mode, include author’s courses
q string Sorin List/Search mode: search in display_name, job_title
limit int 10 10 Page size (max may be 10)
cursor string NTQyNjU5 Base64 cursor

Request Examples

# Search authors
GET https://YOUR_HOST/api/v1/author?q=SkillUp&limit=10

# Single author
GET https://YOUR_HOST/api/v1/author?id=542659

# Author + courses
GET https://YOUR_HOST/api/v1/author?id=542659&include=courses&limit=10

Success Response (author + courses)

{
  "ok": true,
  "author": {
    "id": 542659,
    "display_name": "Sorin Dumitrascu",
    "job_title": "City Manager & Instructor | PMP, PgMP...",
    "url": "https://www.udemy.com/user/sorindumitrascu/",
    "created_at": "2025-09-17 09:02:49",
    "updated_at": "2025-09-17 09:02:49"
  },
  "courses_page": {
    "limit": 10,
    "next_cursor": "Njg3MTA1MQ==",
    "has_more": true
  },
  "courses": [
    {
      "course": {
        "id": 6871051,
        "slug": "python-masterclass",
        "name": "Learn Python in 2025",
        "rating": 4.8,
        "duration_hours": 7.5,
        "language": "English",
        "topic": "Programming",
        "image_url": "https://img-c.udemycdn.com/course/750x422/6871051_59b7.jpg",
        "url_with_coupon": "https://www.udemy.com/course/python-masterclass/?couponCode=OCT12FREE"
      },
      "latest_free_coupon": {
        "id": 2838,
        "code": "OCT12FREE",
        "valid_until": "2025-10-18 17:24:00",
        "created_at": "2025-10-13 18:31:26"
      }
    }
  ]
}

Common Errors

HTTP Body (example) When
400 { "ok": false, "error": "Bad request: id is required and must be a positive integer" } Missing or invalid parameter
403 { "ok": false, "error": "Forbidden: invalid proxy secret" } Header does not match server secret
404 { "ok": false, "error": "course_not_found" } or { "ok": false, "error": "author_not_found" } Resource not found
405 { "ok": false, "error": "Method Not Allowed" } Non‑GET request
429 { "ok": false, "error": "Rate limit exceeded" } Quota hit
500 { "ok": false, "error": "SQL error: <details>" } Server/database error

Notes

  • Always follow the cursor for pagination; do not use offsets.
  • Language filtering uses full English names (e.g., English, Spanish).

Legal & Contact

  • This API is independent and not affiliated with Udemy, Inc.
  • All course and instructor content remains property of their respective owners.
  • Use is governed by the product Terms of Use
  • Contact us through RapidAPI portal in case you have additional questions or requests.

About

Udemy Coupons, Courses & Instructors Data FREE API (Unofficial). Get live Udemy deals, free coupons, course and instructor data sourced from our partner network.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors