← Afþreying

Þrautaspurningar

GET /trivia/questions

Fáðu random trivia questions with multiple-choice or true/false answers. Stillanleg by amount (allt að 50), category, and difficulty level (easy/medium/hard). Skilar questions with correct and incorrect answers, category, and difficulty. Gagnlegt fyrir quiz forrit, trivia games, educational verkfæri, team-building activities, and chatbot entertainment eiginleika. Gögn frá Open Trivia Database with 4.000+ verified questions.

Breytur

amount valfrjálst sjálfgefið: 10

Count

category valfrjálst

Category

difficulty valfrjálst

easy/medium/hard

Dæmi um fyrirspurnir

Grunnnotkun
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"

Lifandi svar

{
  "count": 5,
  "data": [
    {
      "category": "Entertainment: Video Games",
      "correct_answer": "Gielinor",
      "difficulty": "easy",
      "incorrect_answers": [
        "Glindor",
        "Azeroth",
        "Zaros"
      ],
      "question": "What is the name of the world that the MMO \"RuneScape\" takes place in?",
      "type": "multiple"
    },
    {
      "category": "Entertainment: Video Games",
      "correct_answer": "Portal 2",
      "difficulty": "easy",
      "incorrect_answers": [
        "Left 4 Dead 2",
        "Half-Life 3",
        "Dota 2"
      ],
      "question": "\"The Potato Sack\" was a collection of indie games released on Steam in 2011 as a promotion for which game?",
      "type": "multiple"
    },
    {
      "category": "Science & Nature",
      "correct_answer": "Nose",
      "difficulty": "easy",
      "incorrect_answers": [
        "Ears",
        "Chin",
        "Neck"
      ],
      "question": "Rhinoplasty is a surgical procedure on what part of the human body?",
      "type": "multiple"
    },
    {
      "category": "Science: Computers",
      "correct_answer": "23",
      "difficulty": "medium",
      "incorrect_answers": [
        "8",
        "53",
        "15"
      ],
      "question": "How many bits make up the significand portion of a single precision floating point number?",
      "type": "multiple"
    },
    {
      "category": "Entertainment: Video Games",
      "correct_answer": "Karazhan",
      "difficulty": "hard",
      "incorrect_answers": [
        "Zul'Aman",
        "Blackwing Lair",
        "Temple of Ahn'Qiraj"
      ],
      "question": "In World of Warcraft, which raid instance features a chess event?",
      "type": "multiple"
    }
  ],
  "success": true
}