This project is a Payment Routing System that uses Dijkstra's algorithm to find the cheapest path between banks for processing payments. It is built with Node.js, Express, and TypeScript, and includes Swagger documentation for API endpoints.
- Find the cheapest path between banks for payments in EUR or USD.
- Modular architecture with controllers, services, and repositories.
- Middleware for logging and error handling.
- Swagger documentation for API endpoints.
Before running the application, ensure you have the following installed:
- Node.js (v18 or later)
- npm or yarn
- Docker (optional, for containerized deployment)
-
Clone the repository:
git clone https://github.com/garsetayusuf/path-finder-algorithm.git cd path-finder-algorithm
-
Install dependencies:
npm install # or yarn install
-
Configure environment variables:
- Copy
.env.example
to.env
and update the values as needed.
- Copy
-
Run the application:
npm run dev # or yarn dev
- The API documentation is available at
/api-docs
after starting the server. - To find the cheapest payment route, send a POST request to
/api/payment/cheapest_path
with the required parameters.
- Fork the repository.
- Create a new branch for your feature or bugfix.
- Make your changes and commit them.
- Push to your forked repository.
- Create a pull request describing your changes.
- Dijkstra's Algorithm for pathfinding.
- Express for the web framework.
- TypeScript for static typing.
- Swagger for API documentation.