Skip to content

Latest commit

 

History

History
91 lines (71 loc) · 1.82 KB

README.adoc

File metadata and controls

91 lines (71 loc) · 1.82 KB

planning-poker

main

This is simplistic scrum planning poker application. It keeps all data in memory, and expire it after period of inactivity.

Currently, consists of backend part (golang).

build

backend

go build ./cmd/web

docker

docker build -t planning-poker ./ && docker run --rm -p 10080:10080 --name planning-poker -t planning-poker

frontend

Deprecated and removed, see https://github.com/ParallelLines/planning-poker instead.

endpoints

# create session
POST localhost:10080/api/sessions

{
    "id": 1234,
    "votes_info": [],
    "votes_hidden": true,
}
# check if session exists
GET localhost:10080/api/sessions/SESSION_ID

http code 204 or 404
# join session
POST localhost:10080/api/sessions/SESSION_ID/join
Content-Type: application/json
{
    "name": "Roman"
}

{
    "id": 1234,
    "name": "Roman",
    "last_active": "2023-03-22T20:29:50.403844814Z",
    "active": true
}
# establish websocket connection
# ugly url due to workaround for std mux
GET localhost:10080/api/sessions/SESSION_ID/get/USER_ID

## votes hidden
{"id":1234,"votes_info":[{"name":"Not Roman","is_voted":true,"vote":5,"is_current_user":false},{"name":"Roman","is_voted":false,"vote":null,"is_current_user":true}],"votes_hidden":true}

## votes shown/session data visible
{"id":1234,"votes_info":[{"name":"Not Roman","is_voted":true,"vote":5,"is_current_user":false},{"name":"Roman","is_voted":true,"vote":5,"is_current_user":true}],"votes_hidden":false}
POST localhost:10080/api/sessions/SESSION_ID/vote
Content-Type: application/json
{
    "user_id": USER_ID,
    "vote": 8
}
POST localhost:10080/api/sessions/SESSION_ID/clear
POST localhost:10080/api/sessions/SESSION_ID/show