Skip to content

Latest commit

 

History

History
80 lines (59 loc) · 1.54 KB

File metadata and controls

80 lines (59 loc) · 1.54 KB

### root GET http://localhost:7000/v2

### User register POST localhost:7000/api/event Content-Type: application/json

{
"firstname" : "Davronbek Rustamov", "email" : "afjoiea@gmail.com", "password" : "test1"

}

### Login POST localhost:7000/v2/login Content-Type: application/json

{
"username" : "davron", "password" : "test1"

}

### Logout POST localhost:7000/v2/logout Content-Type: application/json

### Create Event POST localhost:7000/v2/event Content-Type: application/json

{
"event_name" : "Yozda birga kod yozamiz", "end_date" : "2024-07-30"

}

### Get all Events ## userning barcha eventlar ro'yxat ## require : user -> _id GET localhost:7000/v2/event Content-Type: application/json

### Get Event ## mavjud event haqidagi malumotlar ## require : event -> _id GET localhost:7000/v2/event/66a7780433154ebe2b53b66b Content-Type: application/json

### Delete Event ## require : event -> _id DELETE localhost:7000/v2/event/66a7780433154ebe2b53b66b Content-Type: application/json

### Update Event ## require : event -> _id PUT localhost:7000/v2/event/66a7780433154ebe2b53b66b Content-Type: application/json

{
"moderators" : ["66a38d883d4a636d98407a2b"]

}

### Get all questions GET localhost:7000/v2/event/66a77880452340ea78cfc4b6/questions Content-Type: application/json

### Send questions POST localhost:7000/v2/event/66a77880452340ea78cfc4b6/questions Content-Type: application/json

{
"message" : "Qandedur savol 2"

}

### Generate questions GET localhost:7000/v2/event/66a77880452340ea78cfc4b6/questions/generate Content-Type: application/json