Author: Denis Lebó
Last Modification Date: 20/05/2022
All endpoints have the following form: /api/[Endpoint]
. For brevity, in the following chapters only the Endpoint
will be given. This API is supposed to serve as a backend for a future summer project of developing an app for group
fund management. It was developed as a part of the subject PV178 - Úvod do vývoje v C#/.NET
.
Available methods: [ GET, POST ]
Access privilege is determined by data contained in the JWT token. If the token is out-of-date and does not contain the most up-to-date data, some groups may not be visible.
Retrieves all group the current user has access to.
Creates a new group. Unless importing data from a previously existing group members and debt fields should not be included. If the current user is not present in the members field, he is automatically added.
After this operation you MUST request a new JWT token to have access to the created group!
(int) id - id of the group
Available methods: [ GET, PUT, DELETE ]
Access privilege is determined by data contained in the JWT token. If the token is out-of-date and does not contain the most up-to-date data, some groups may not be accessible.
Retrieves the group with details of members and debt.
Updates the name of the group.
Deletes the group
Available methods: [ GET, POST ]
Access privilege is determined by data contained in the JWT token. If the token is out-of-date and does not contain the most up-to-date data, some members may not be visible.
Retrieves all members the current user has access to.
Creates a new member
(int) id - id of the member
Available methods: [ GET, PUT ]
Access privilege is determined by data contained in the JWT token. If the token is out-of-date and does not contain the most up-to-date data, some groups may not be accessible.
Retrieves the member
Updates the name of the member.
Available methods: [ POST ]
Creates a user account. All access privileges are bound to this user account!
Available methods: [ POST ]
Generates a an up-to-date JWT token with necessary access information
Available methods: [ GET, POST ]
Access privilege is determined by data contained in the JWT token. If the token is out-of-date and does not contain the most up-to-date data, some transactions may not be visible.
Retrieves all transactions that the user has paid for.
Creates a new transaction.
If debts is left empty, the cost will be dispersed equally among all members. When defining weight or amount, both CANNOT be defined in the same debt. However, it can be used in combination between different debts. E.g. debt 1 has amount and debt 2 has weight. When determining amounts and weights first all amount debts will be allocated and then the residual cost is split between weight debts.
(int) id - id of the transaction
Available methods: [ GET, PUT ]
Access privilege is determined by data contained in the JWT token. If the token is out-of-date and does not contain the most up-to-date data, some groups may not be accessible.
Retrieves the transaction
Update the name of the transaction