example-data.com
Menu
Browse docs and collections

enrollments

enrollments

Page 21 of 21.

Overview

Request

curl example

curl -sS \
  "https://example-data.com/api/v1/enrollments?limit=25"

JavaScript example

const res = await fetch(
  "https://example-data.com/api/v1/enrollments?limit=25"
);
const { data, meta } = await res.json();

TypeScript example

// Download once: mkdir -p types && curl -o types/enrollments.d.ts https://example-data.com/types/enrollments.d.ts
import type { Enrollment, ListEnvelope } from "./types/enrollments";

const res = await fetch(
  "https://example-data.com/api/v1/enrollments?limit=25"
);
const { data, meta } = (await res.json()) as ListEnvelope<Enrollment>;

Python example

import requests

res = requests.get(
    "https://example-data.com/api/v1/enrollments",
    params={"limit": 25},
)
data = res.json()

Response

{
  "data": [
    {
      "id": 481,
      "userId": 242,
      "courseId": 31,
      "enrolledAt": "2025-11-20T16:35:52.738Z",
      "completedAt": null,
      "progressPercent": 94,
      "createdAt": "2025-11-20T16:33:57.548Z"
    },
    {
      "id": 482,
      "userId": 242,
      "courseId": 26,
      "enrolledAt": "2025-02-21T22:40:13.953Z",
      "completedAt": null,
      "progressPercent": 53,
      "createdAt": "2025-02-21T22:36:18.243Z"
    },
    {
      "id": 483,
      "userId": 243,
      "courseId": 37,
      "enrolledAt": "2025-10-09T21:07:37.038Z",
      "completedAt": null,
      "progressPercent": 84,
      "createdAt": "2025-10-09T21:04:14.187Z"
    }
  ],
  "meta": {
    "page": 21,
    "limit": 24,
    "total": 501,
    "totalPages": 21
  },
  "links": {
    "self": "/api/v1/enrollments?page=21&limit=24",
    "first": "/api/v1/enrollments?page=1&limit=24",
    "last": "/api/v1/enrollments?page=21&limit=24",
    "next": null,
    "prev": "/api/v1/enrollments?page=20&limit=24"
  }
}