Page:
Mock API Ceation Guidelines
Pages
API SMHI
API Sudoku
API TimeEdit
Accessibility Testing
Api documentation
Bat/Ps
Branch Creation
C# Coding Convention
CSS Coding Convention
Coding Conventions
Creating new databases
Dapper
Dictionary API
Documentation for service endpoints
Documentation of useTemperature and mock sensor
Energy endpoints
Environment
Evaluation react-grid-layout
Evaluation Localization
Evaluation Password hashing
Evaluation Testing framework
Evaluation of Logging Frameworks
Formatter
Frontend model
Generic Diagram for Sensor data flow
Home
How to- Creating Databases in Docker
Implementing different Styles
Implementing new Services (and Mockups)
Implementing new Views
Installation script documentation
Installation
Integration testing utilizing testcontainers, xUnit and ASP.NET core web testservers
Issues
JSON Coding Convention
Jest Testing
Layout endpoints
Linux
Localization
Login endpoints
Mac
Menu Endpoints
Middleware model
Mock API Ceation Guidelines
Mockup models
Model Tools and Standards
Parking endpoints
React/JavaScript Coding Convention
React
Reviews
Room booking endpoints
SQL Coding Convention
Scheduled Database tasks
Scripting Coding Convention
Seasonal theme
Secrets and .env
Server Access
Server-DeploymentUnix
Server-DeploymentWindows
Server-Hardware/Benchmarks
Service/API models
System models
System requirements
Temperature endpoints
Testing API with Bruno
Testing Architecture
Testing frontend for Mobile devices
Testing frontend with Playwright
Testing methodology
Themes
Trivia API
Västtrafik API
Webpage Design
Windows
file endpoints
pg_cron and scheduled database jobs
xUnit Testing
No results
5
Mock API Ceation Guidelines
Nedzad Kalajdzic edited this page 2026-05-28 07:59:00 +00:00
The rules:
- Every micro service shall have a database. At the moment we use sensor database until the investigation about the database structure is done.
- Map Structure
- shall follow Object oriented (use of classes) check out the parking service structure
- Every micro service has unique functionalities such as electricity and sensor then some parts may not be similar
- Having a README: What to include:
- How it integrates from frontend and back
- How we reach the data and having proper comments
- In the pr having a label about testing
- How to build the project and make it run
- The decision and why
Communication
- At the moment the communication will happen through the middleware
- The update request is at the moment mockup until the investigation about how to handle it in the middleware and database.
When you create a new project, you need to first choose the correct template, then run the following command.
-"dotnet new <TEMPLATE> -n YOUR_PROJECT_NAME"
To list the available templates, use the command:
-"dotnet new list"
Service Creation Scripts
-
New services can be created using:
- WindowsCreateService.bat
- UnixCreateService.sh
-
The scripts generate :
- Service structure
- Dockerfile
- Test project
- DatabaseLogic folder
- Endpoint structure
- Request and Response models
Docker compose and Database Structure
- The projects current stack includes:
- Energy
- file
- frontend
- menu
- parking
- roomBooking
- temperature
- user
- vasttrafik
- solarPanel
- Each stack can be rebuilt and managed independently.
- The project architecture is designed so that each micro service should have its own database structure, although some services currently still use shared sensor database structures while the database investigation is ongoing.
API vs MicroServices
- Mockup APIs are mainly used for simulating external systems and external data sources. ReadMockup services collects data from the mockup API's and publish data through MQTT middleware communication. Service micro services mainly handles:
- Business logic
- Database communication
- Endpoints
- Middleware communication
Data Flow Models
-
The project mainly uses this following structure for data flow:
- Mockup API => ReadMockup => Middleware => Service => Database.
-
Within the service layer the flow mainly follows:
- Endpoint => Service => DatabaseLogic => Database
-
The most used models and layers are:
- Request
- Response
- Services
- DatabaseLogic
- Endpoints
1. Setup
2. Standards
- Coding Conventions
- Issues
- Branch creation
- Reviews
- Implementation Standards
- [WIP] Creating new databases
- Localization
3. Models and Diagrams
4. Testing
- Testing methodology
- Testing Architecture
- Testing frontend with Playwright
- Integration testing utilizing testcontainers, xUnit and ASP.NET core webhost
5. Documentation
- Documentation for service endpoints
- API documentation
- Webpage Design
- Secrets and .env
- Evaluations
- Installation and Rebuild script documentation
6. Guides and How-to's
7. Micro Service Mockup Api
- Guidelines Mircro Service Mockup
- Documentation of useTemperature/useTemperatureTimeSeries mockup sensor