Welcome to the backend API for 'Simplifying Small Business Payments.'
To set up and run the application locally, follow these steps:
- Create User Secrets
- Navigate to
C:\%USERPROFILE%\AppData\Roaming\Microsoft\UserSecrets
and create a folder named41019bab-28dd-41f1-a221-82ed1e906626
. - Create a file named
secrets.json
. - Add the following JSON to the file:
- Navigate to
{
"DatabaseSettings": {
"ConnectionString": "Server=kluster.database;Database=KlusterDB;User Id=SA;Password={Password};
MultipleActiveResultSets=true;TrustServerCertificate=true;"
},
"JwtSettings": {
"Audience": "{Audience}",
"Issuer": "{Issuer}",
"SecretKey": "{SecretKey}",
"TokenLifetimeInHours": 1
},
"RabbitMqSettings": {
"Host": "kluster.messaging",
"Password": "{Password}",
"Username": "{Password}"
},
"MailSettings": {
"DisplayName": "{FirstName} {LastName}",
"From": "{EmailAddress}",
"Host": "{Host}",
"Password": "{Password}",
"Port": {Port},
"UserName": "{Username}",
"UseSsl": false,
"UseStartTls": true
}
}
- Run the Application
- Navigate to the
Kluster.Host/
directory in the project. - Execute
docker compose up
.
- Navigate to the
-
Create User Secrets
- Navigate to
~/.microsoft/usersecrets
and create a folder named41019bab-28dd-41f1-a221-82ed1e906626
. - Create a file named
secrets.json
. - Add the same JSON content provided earlier.
- Navigate to
-
Run the Application
- Navigate to the Kluster.Host directory in the project.
- Run docker compose up.
- After running the command, three containers will start:
kluster-api
,kluster-database
andkluster.messaging
. - Access the Swagger documentation at Swagger.
- Send requests to the API at http://localhost:5000/api.
- If required folders are missing, ensure to create them.
You can access the postman collection here, with examples: PostmanDoc.