Skip to content

RagSharan/assignment

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

18 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

assignment

#Run Application By Command in vs code

go run cmd/svr/main.go

Run through build file ./main.exe

Answer APIs

1- Post API- http://localhost:8080/api/v1/answer

    Body- {
          "Key": "Q1",
          "Value": 23
          }

2- Get API-
GetById- http://localhost:8080/api/v1/answer/62d4558d2000fc95e9f117ff

    GetByOtherParams- http://localhost:8080/api/v1/answer?id=62d4546db78721f67bf825de

3- Put API- http://localhost:8080/api/v1/answer

    Body   {    "id": "62d4558f2000fc95e9f11803",
                "key": "Q1",
                "value": "answer"
          }

4- Delete API- DeleteById

            http://localhost:8080/api/v1/answer/62d4558f2000fc95e9f11803

Events API

1- GetEvents here id = answerId :- http://localhost:8080/api/v1/events/{id}

http://localhost:8080/api/v1/events/62d593e3e072f3f2b336c88a

DB Mongodb docker container url

url- mongodb://localhost:27017

All the code is inside pkg folder

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages