The backend API is built using the following technologies and modules:
- Cloudflare Workers - JavaScript runtime environment.
- Hono - Web framework for Cloudflare Workers.
- TypeScript - Static typing for JavaScript.
- SQLite - Relational database.
- Drizzle ORM - ORM for database access and modeling.
- Zod - Data validation.
- Pino - Logging library.
- Swagger - API documentation.
- ESLint - Linter.
- Prettier - Code formatter.
To set up the development environment for the backend API, follow these steps:
- Clone the repository from GitHub to your local machine:
git clone https://github.com/alikehel/ecommerce-api.git
- Navigate into the project directory:
cd ecommerce-api
- Install dependencies:
pnpm install
- Rename
.dev.vars.example
to.dev.vars.exale
and update the environment variables to match your local setup:
CLOUDFLARE_ACCOUNT_ID=
CLOUDFLARE_DATABASE_ID=
CLOUDFLARE_API_TOKEN=
- Start the application:
pnpm run dev
-
The API should now be running on
http://localhost:8787
or the port defined in code. -
Test API endpoints.
The project is currently under development, and the following tasks are being worked on:
- [ ]
For any minor updates to the curriculum, such as fixing broken URLs, correcting spelling or syntax errors, and other non-substantive issues, we welcome you to submit a pull request. You can do this by following the guidelines in pull request guide.
If you have specific and substantial feedback or concerns about the content, we encourage you to open an issue. Please refer to open an issue for assistance.
This project is licensed under the MIT License.