File size: 3,181 Bytes
5afe693 |
1 |
{"openapi":"3.1.0","info":{"title":"FastAPI","version":"0.1.0"},"paths":{"/":{"get":{"summary":"Vérification Que L'Api Fonctionne","operationId":"Vérification_que_l_API_fonctionne__get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/questions":{"get":{"summary":"Récupération Des Questions Pour Un Qcm","description":"Récupère les questions en fonction du type de test (use) et des catégories (subject) spécifiés\nL'application peut produire des QCMs de 5, 10 ou 20 questions (seulement)\nLes questions sont retournées dans un ordre aléatoire\nSeuls les utilisateurs se trouvant dans users_credentials peuvent utiliser cette application","operationId":"Récupération_des_questions_pour_un_QCM_questions_get","security":[{"HTTPBasic":[]}],"parameters":[{"name":"use","in":"query","required":true,"schema":{"type":"string","title":"Use"}},{"name":"subject","in":"query","required":true,"schema":{"type":"string","title":"Subject"}},{"name":"num_questions","in":"query","required":true,"schema":{"type":"integer","title":"Num Questions"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/questions/create":{"post":{"summary":"Création D'Une Nouvelle Question","description":"Crée une nouvelle question et l'ajoute à questions.csv\nSeuls l' utilisateur admin a le droit d'utiliser cette fonction","operationId":"Création_d_une_nouvelle_question_questions_create_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Question"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBasic":[]}]}}},"components":{"schemas":{"HTTPValidationError":{"properties":{"detail":{"items":{"$ref":"#/components/schemas/ValidationError"},"type":"array","title":"Detail"}},"type":"object","title":"HTTPValidationError"},"Question":{"properties":{"question":{"type":"string","title":"Question"},"subject":{"type":"string","title":"Subject"},"correct":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Correct"},"use":{"type":"string","title":"Use"},"responseA":{"type":"string","title":"Responsea"},"responseB":{"type":"string","title":"Responseb"},"responseC":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Responsec"},"responseD":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Responsed"}},"type":"object","required":["question","subject","use","responseA","responseB"],"title":"Question"},"ValidationError":{"properties":{"loc":{"items":{"anyOf":[{"type":"string"},{"type":"integer"}]},"type":"array","title":"Location"},"msg":{"type":"string","title":"Message"},"type":{"type":"string","title":"Error Type"}},"type":"object","required":["loc","msg","type"],"title":"ValidationError"}},"securitySchemes":{"HTTPBasic":{"type":"http","scheme":"basic"}}}} |