A complete implementation of the Competencies and Academic Standards Exchange (CASE) Service v1.1 using Express.js and Prisma ORM.
This implementation follows the CASE v1.1 specification from 1EdTech:
- Specification URL: https://purl.imsglobal.org/spec/case/v1p1
- OpenAPI Definition: https://purl.imsglobal.org/spec/case/v1p1/schema/openapi/imscasev1p1_openapi2_v1p0.json
This service provides a REST API that implements the CASE v1.1 specification from 1EdTech. It enables the exchange of competency frameworks and academic standards data between service providers and consumers.
- ✅ PostgreSQL database with Prisma ORM
- ✅ TypeScript for type safety
- ✅ Six manager endpoints:
- AssociationsManager: Manage CFAssociations
- DefinitionsManager: Manage CFConcepts, CFSubjects, CFLicenses, CFItemTypes, CFAssociationGroupings
- DocumentsManager: Manage CFDocuments
- ItemsManager: Manage CFItems
- PackagesManager: Manage CFPackages
- RubricsManager: Manage CFRubrics and CFRubricCriteria
- ✅ OpenAPI specification endpoint at
/ims/case/v1p1/openapi.json
- Node.js (v18 or higher)
- PostgreSQL database (or Docker for containerized setup)
- yarn package manager
- Docker and Docker Compose (optional, for containerized setup)
The easiest way to run the application with all dependencies:
# Start both the application and database
docker-compose up -d
# View logs
docker-compose logs -f app
# Stop services
docker-compose down
# Stop and remove volumes (clears database)
docker-compose down -vThe application will be available at http://localhost:3000
-
Install dependencies:
yarn install
-
Configure environment:
cp .env.example .env
-
Edit
.envand update theDATABASE_URLwith your PostgreSQL connection string:DATABASE_URL="postgresql://caseuser:casepassword@localhost:5432/case_provider?schema=public" -
Initialize Prisma:
yarn prisma:generate
-
Run database migrations:
yarn prisma:migrate
yarn devyarn build
yarn startThe server will start on http://localhost:3000 (or the PORT specified in your .env file).
All CASE API endpoints are prefixed with: /ims/case/v1p1
GET /ims/case/v1p1/CFAssociations/{sourcedId}- Get a specific associationGET /ims/case/v1p1/CFItemAssociations/{sourcedId}- Get the associations of the given CFItem
GET /ims/case/v1p1/CFConcepts/{sourcedId}- Get a conceptGET /ims/case/v1p1/CFSubjects/{sourcedId}- Get a subjectGET /ims/case/v1p1/CFLicenses/{sourcedId}- Get a licenseGET /ims/case/v1p1/CFItemTypes/{sourcedId}- Get an item typeGET /ims/case/v1p1/CFAssociationGroupings/{sourcedId}- Get an association grouping
GET /ims/case/v1p1/CFDocuments- List all documentsGET /ims/case/v1p1/CFDocuments/{sourcedId}- Get a specific document
GET /ims/case/v1p1/CFItems/{sourcedId}- Get a specific item
GET /ims/case/v1p1/CFPackages/{sourcedId}- Get a package
GET /ims/case/v1p1/CFRubrics/{sourcedId}- Get a rubric
GET /- Service informationGET /health- Health checkPOST /upload- Add Packages from a CSV filePOST /upload/items- Add Items from a CSV filePOST /upload/associations- Add Associations from a CSV file
View and edit your database using Prisma Studio:
yarn prisma:studioAfter modifying the Prisma schema:
yarn prisma:migrateCASEProvider/
├── prisma/
│ ├── migrations/ # Database migrations
│ └── schema.prisma # Database schema
├── public/
│ └── openapi-spec.json # CASE v1.1 OpenAPI specification
├── src/
│ ├── index.ts # Application entry point
│ ├── lib/
│ │ ├── errors.ts # Error handling utilities
│ │ ├── prisma.ts # Prisma client
│ │ └── validation.ts # Validation utilities
│ ├── routes/
│ ├── associations.ts # Associations endpoints
│ ├── definitions.ts # Definitions endpoints
│ ├── documents.ts # Documents endpoints
│ ├── items.ts # Items endpoints
│ ├── packages.ts # Packages endpoints
│ ├── rubrics.ts # Rubrics endpoints
│ ├── spec.ts # OpenAPI spec endpoint
│ └── upload.ts # Upload endpoints
├── package.json
├── tsconfig.json
└── README.mdThe application implements the following CASE entities:
- CFDocument: Root entry point for competency frameworks
- CFItem: Containers for competency definitions
- CFAssociation: Relationships between documents and items
- CFConcept: Framework concepts
- CFSubject: Framework subjects
- CFLicense: License definitions
- CFItemType: Item type definitions
- CFAssociationGrouping: Association groupings
- CFPackage: Complete framework packages
- CFRubric: Rubric definitions
- CFRubricCriterion: Individual rubric criteria
This project uses:
- TypeScript for type safety
- Express.js for the web framework
- Prisma for database ORM
- PostgreSQL as the database
- Docker for containerization
See the OpenAPI specification file for 1EdTech licensing information.