| ... | @@ -25,6 +25,53 @@ |
... | @@ -25,6 +25,53 @@ |
|
|
|
|
|
|
|
</details>
|
|
</details>
|
|
|
|
|
|
|
|
|
<details><summary><b>Example Responses</b></summary>
|
|
|
|
|
|
|
|
```json
|
|
|
|
{
|
|
|
|
"statusCode": 200,
|
|
|
|
"message": "Challenge room created successfully",
|
|
|
|
"details": {
|
|
|
|
"userId": "56f2046a-917b-417b-8d2d-3f00090df73b",
|
|
|
|
"isGameMaster": true,
|
|
|
|
"challengeRoomId": "2e22f027-d3e9-4357-9fb5-963735f6b86e",
|
|
|
|
"challengeRoomCode": "zT57",
|
|
|
|
"challengeRoomName": "Test game",
|
|
|
|
"challengeStartDate": "2021-07-23T10:54:59.965Z",
|
|
|
|
"challengeEndDate": "2021-07-23T11:24:59.000Z",
|
|
|
|
"challengeTasks": [
|
|
|
|
{
|
|
|
|
"taskNumber": 1,
|
|
|
|
"taskDescription": "Haaste 1"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"taskNumber": 2,
|
|
|
|
"taskDescription": "Haaste 2"
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJMZWFkZXIiOiJFbG1lciIsIlVJVVgiOiJFbGxhIiwiRGV2T3BzIjoiRWV0dSIsIlRlc3RlciI6IklsZGlrbyIsIkZyb250IjoiTWlydmEiLCJGdWxsQXMwIjoiTWFya2t1IiwiRnVsbEFzMSI6Ik9sbGkifQ.vR2qPO_hgUnRXp7lbqgDoOrBfqNvW-o9KCw0i2iM3u8"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
```
|
|
|
|
|
|
|
|
```json
|
|
|
|
{
|
|
|
|
"statusCode": 400,
|
|
|
|
"error": "Bad Request",
|
|
|
|
"message": "\"Challenge Name\" must be a string. \"Challenge Duration\" must be less than or equal to 240. \"challengeStartDelay\" must be less than or equal to 60",
|
|
|
|
"validation": {
|
|
|
|
"source": "payload",
|
|
|
|
"keys": [
|
|
|
|
"challengeName",
|
|
|
|
"challengeDuration",
|
|
|
|
"challengeStartDelay"
|
|
|
|
]
|
|
|
|
}
|
|
|
|
}
|
|
|
|
```
|
|
|
|
|
|
|
|
</details>
|
|
|
|
|
|
|
---
|
|
---
|
|
|
|
|
|
|
|
## Join Challenge
|
|
## Join Challenge
|
| ... | |
... | |
| ... | | ... | |