{
  "info": {
    "name": "HyperQuiz API",
    "_postman_id": "hyperquiz-collection",
    "description": "HyperQuiz API v1.0.0\n\nDéfinissez la variable d'environnement `apiKey` pour authentifier vos requêtes.",
    "schema": "https://schema.getpostman.com/json/collection/v2.1.0/collection.json"
  },
  "auth": {
    "type": "apikey",
    "apikey": [
      {
        "key": "key",
        "value": "x-api-key",
        "type": "string"
      },
      {
        "key": "value",
        "value": "{{apiKey}}",
        "type": "string"
      },
      {
        "key": "in",
        "value": "header",
        "type": "string"
      }
    ]
  },
  "variable": [
    {
      "key": "baseUrl",
      "value": "https://hyperquiz.fr"
    },
    {
      "key": "apiKey",
      "value": ""
    }
  ],
  "item": [
    {
      "name": "POST /api/questionnaire",
      "request": {
        "method": "POST",
        "header": [
          {
            "key": "content-type",
            "value": "application/json"
          },
          {
            "key": "x-api-key",
            "value": "{{apiKey}}"
          }
        ],
        "body": {
          "mode": "raw",
          "raw": "{\n  \"theme\": \"Astronomie du système solaire\",\n  \"minLevel\": 1,\n  \"maxLevel\": 10,\n  \"count\": 10,\n  \"nbChoices\": 4\n}",
          "options": {
            "raw": {
              "language": "json"
            }
          }
        },
        "url": {
          "raw": "{{baseUrl}}/api/questionnaire",
          "host": [
            "{{baseUrl}}"
          ],
          "path": [
            "api",
            "questionnaire"
          ]
        },
        "description": "Génère N questions QCM sur un thème en un seul appel IA. Les niveaux sont répartis de manière déterministe entre `minLevel` et `maxLevel`."
      }
    },
    {
      "name": "POST /api/question",
      "request": {
        "method": "POST",
        "header": [
          {
            "key": "content-type",
            "value": "application/json"
          },
          {
            "key": "x-api-key",
            "value": "{{apiKey}}"
          }
        ],
        "body": {
          "mode": "raw",
          "raw": "{\n  \"theme\": \"Astronomie du système solaire\",\n  \"level\": 5,\n  \"nbChoices\": 4\n}",
          "options": {
            "raw": {
              "language": "json"
            }
          }
        },
        "url": {
          "raw": "{{baseUrl}}/api/question",
          "host": [
            "{{baseUrl}}"
          ],
          "path": [
            "api",
            "question"
          ]
        },
        "description": "Génère UNE seule question à un niveau imposé. Équivalent à `getQuestionnaire` avec `count = 1` et `minLevel = maxLevel = level`."
      }
    },
    {
      "name": "POST /api/tuning",
      "request": {
        "method": "POST",
        "header": [
          {
            "key": "content-type",
            "value": "application/json"
          },
          {
            "key": "x-api-key",
            "value": "{{apiKey}}"
          }
        ],
        "body": {
          "mode": "raw",
          "raw": "{\n  \"theme\": \"Astronomie du système solaire\",\n  \"hints\": {\n    \"sources\": [\n      \"NASA\",\n      \"ESA\"\n    ],\n    \"tone\": \"vulgarisation\"\n  }\n}",
          "options": {
            "raw": {
              "language": "json"
            }
          }
        },
        "url": {
          "raw": "{{baseUrl}}/api/tuning",
          "host": [
            "{{baseUrl}}"
          ],
          "path": [
            "api",
            "tuning"
          ]
        },
        "description": "Génère un `TuningContent` JSON prêt à l'emploi pour un thème donné. Utile pour préparer un tuning, l'éditer, puis le renvoyer à `/api/questionnaire`."
      }
    }
  ]
}