Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Historical data #62

Closed
Mister-Mario opened this issue Mar 23, 2024 · 4 comments · Fixed by #68
Closed

Historical data #62

Mister-Mario opened this issue Mar 23, 2024 · 4 comments · Fixed by #68
Assignees
Labels
enhancement New feature or request

Comments

@Mister-Mario
Copy link
Contributor

Create an endpoint to save a game played by an user and being able to retrieve it later

@Mister-Mario Mister-Mario added the enhancement New feature or request label Mar 23, 2024
@Mister-Mario Mister-Mario self-assigned this Mar 23, 2024
@uo289267
Copy link
Contributor

image
View of historical Data

@uo289267
Copy link
Contributor

image
View of one of the games stored in the historical data

@Mister-Mario
Copy link
Contributor Author

//DB
{
"userIdentification": "prob email or username",
"games": [
{
"questions": [
{
"question": "¿Cuál es la capital de Francia?",
"answers": ["Madrid", "París", "Londres", "Roma"],
"answerGiven": "París",
"correctAnswer": "París"
},
{
"question": "¿En qué año comenzó la Segunda Guerra Mundial?",
"answers": ["1939", "1945", "1914", "1941"],
"answerGiven": "1939",
"correctAnswer": "1939"
},
{
"question": "¿Quién escribió 'Don Quijote de la Mancha'?",
"answers": ["Miguel de Cervantes", "Gabriel García Márquez", "Federico García Lorca", "Jorge Luis Borges"],
"answerGiven": "Miguel de Cervantes",
"correctAnswer": "Miguel de Cervantes"
}
],
"points": 3000,
"date": "01/02/24"
},
{
"questions": [
{
"question": "¿Cuál es el río más largo del mundo?",
"answers": ["Nilo", "Amazonas", "Yangtsé", "Misisipi"],
"answerGiven": "Amazonas",
"correctAnswer": "Amazonas"
},
{
"question": "¿Cuál es el elemento más abundante en la corteza terrestre?",
"answers": ["Hierro", "Oxígeno", "Silicio", "Aluminio"],
"answerGiven": "Oxígeno",
"correctAnswer": "Oxígeno"
}
],
"points": 2500,
"date": "02/02/24"
},
{
"questions": [
{
"question": "¿Quién pintó la Mona Lisa?",
"answers": ["Leonardo da Vinci", "Pablo Picasso", "Vincent van Gogh", "Rembrandt"],
"answerGiven": "Leonardo da Vinci",
"correctAnswer": "Leonardo da Vinci"
},
{
"question": "¿Cuál es el planeta más grande del sistema solar?",
"answers": ["Júpiter", "Saturno", "Neptuno", "Urano"],
"answerGiven": "Júpiter",
"correctAnswer": "Júpiter"
}
],
"points": 3500,
"date": "03/02/24"
}
]
}

@Mister-Mario
Copy link
Contributor Author

//What is expected when finishing a game
{
user:userIdentifier
game:
{
"questions": [
{
"question": "¿Cuál es el río más largo del mundo?",
"answers": ["Nilo", "Amazonas", "Yangtsé", "Misisipi"],
"answerGiven": "Amazonas",
"correctAnswer": "Amazonas"
},
{
"question": "¿Cuál es el elemento más abundante en la corteza terrestre?",
"answers": ["Hierro", "Oxígeno", "Silicio", "Aluminio"],
"answerGiven": "Oxígeno",
"correctAnswer": "Oxígeno"
}
],
"points": 2500,
"date": "02/02/24"
}
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants