← Underholdning

Triviaspørgsmål

GET /trivia/questions

Hent tilfældige triviaspørgsmål med multiple choice- eller sandt/falsk-svar. Konfigurerbar efter antal (op til 50), kategori og sværhedsgrad (let/medium/svær). Returnerer spørgsmål med korrekte og forkerte svar, kategori og sværhedsgrad. Nyttigt til quizapps, triviaspil, uddannelsesværktøjer, teambuilding-aktiviteter og chatbot-underholdningsfunktioner. Data fra Open Trivia Database med 4.000+ verificerede spørgsmål.

Se det visualiseret

Parametre

amount valgfri standard: 10

Count

category valgfri

Category

difficulty valgfri

easy/medium/hard

Eksempelforespørgsler

Grundlæggende brug
curl "https://nordapi.ee/api/v1/trivia/questions?amount=5"
5 random trivia questions
curl "https://nordapi.ee/api/v1/trivia/questions?amount=5"
10 easy science questions
curl "https://nordapi.ee/api/v1/trivia/questions?amount=10&category=17&difficulty=easy"
20 hard history questions
curl "https://nordapi.ee/api/v1/trivia/questions?amount=20&category=23&difficulty=hard"

Livesvar

{
  "count": 5,
  "data": [
    {
      "category": "Entertainment: Music",
      "correct_answer": "Wales",
      "difficulty": "medium",
      "incorrect_answers": [
        "America",
        "England",
        "Canada"
      ],
      "question": "What country did Shirley Bassey originate from?",
      "type": "multiple"
    },
    {
      "category": "Entertainment: Television",
      "correct_answer": "Mr. Bean in Room 426",
      "difficulty": "medium",
      "incorrect_answers": [
        "Mr. Bean Goes to Town",
        "The Trouble with Mr. Bean",
        "Back to School Mr. Bean"
      ],
      "question": "What episode of \"Mr. Bean\" saw him trying to prevent people from seeing him naked?",
      "type": "multiple"
    },
    {
      "category": "Entertainment: Film",
      "correct_answer": "Duck Soup",
      "difficulty": "hard",
      "incorrect_answers": [
        "A Night at the Opera",
        "A Day at the Races",
        "Monkey Business"
      ],
      "question": "What was the last Marx Brothers film to feature Zeppo?",
      "type": "multiple"
    },
    {
      "category": "Science & Nature",
      "correct_answer": "Carl Jung",
      "difficulty": "medium",
      "incorrect_answers": [
        "Jean Piaget",
        "Alice Miller",
        "Hermann Rorschach"
      ],
      "question": "Which Swiss psychologist is synonymous with the concepts of introvert and extrovert personalities?",
      "type": "multiple"
    },
    {
      "category": "Science & Nature",
      "correct_answer": "Sagittarius A*",
      "difficulty": "medium",
      "incorrect_answers": [
        "Messier 87",
        "Alpha Centauri",
        "Andromeda"
      ],
      "question": "What is the name of the Supermassive Black Hole in the centre of the Milky Way?",
      "type": "multiple"
    }
  ],
  "success": true
}