Skip to content

utkarsharma2/Sliptwise

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 

Repository files navigation

Requests

Group

curl --location --request POST 'http://127.0.0.1:8000/ledger/group/' \
--header 'Content-Type: application/json' \
--data-raw '{
    "name": "group1"
}'

Add user to Group

curl --location --request GET 'http://127.0.0.1:8000/ledger/adduser/?user=3&group=6'

User

curl --location --request POST 'http://127.0.0.1:8000/ledger/user/' \
--header 'Content-Type: application/json' \
--data-raw '{
    "name": "demouser"
}'

Event:

create:

curl --location --request POST 'http://127.0.0.1:8000/ledger/event/' \
--header 'Content-Type: application/json' \
--data-raw '{
	"user": [{
		"id": 1,
		"amount": 2000,
	    "Percent": 0
	}, {
		"id": 2,
		"amount": 100,
	    "percent": 50
	}, {
		"id": 3,
		"amount": 0,
	  	"percent": 50
	}],
	"name": "groceries",
	"type": "percent",
	"group": 6
}'

get:

curl --location --request GET 'http://127.0.0.1:8000/ledger/event/'

delete:

curl --location --request DELETE 'http://127.0.0.1:8000/ledger/event/46/'

Transaction:

curl --location --request GET 'http://127.0.0.1:8000/ledger/transactions/?user=3'

Summary:

curl --location --request GET 'http://127.0.0.1:8000/ledger/summary/?group=6'

Settlement:

curl --location --request GET 'http://127.0.0.1:8000/ledger/settle/?lender=1&borrower=3&amount=500&group=6'

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages