{
"title": "General Knowledge about Ukraine",
"data": [
{
"id": "Ae19CdyQxub",
"question": "What is the official and national language of Ukraine?",
"answer": "Ukrainian",
"options": [
"Belarusian",
"Polish",
"Russian",
"Romanian",
"Ukrainian"
]
},
{
"id": "R4US2xWVvHo",
"question": "Which country is Ukraine's eastern neighbor?",
"answer": "Russia",
"options": [
"Belarus",
"Hungary",
"Moldova",
"Poland",
"Russia"
]
},
{
"id": "gB8NN6OiTyd",
"question": "What is the approximate area that Ukraine covers?",
"answer": "600,000 square kilometers",
"options": [
"100,000 square kilometers",
"300,000 square kilometers",
"500,000 square kilometers",
"600,000 square kilometers",
"700,000 square kilometers"
]
},
{
"id": "h-ErweMSDJU",
"question": "Which body of water is along Ukraine's south and southeast coastlines?",
"answer": "Black Sea",
"options": [
"Adriatic Sea",
"Aegean Sea",
"Baltic Sea",
"Black Sea",
"Caspian Sea"
]
},
{
"id": "h44yj-sKEGU",
"question": "What is the capital city of Ukraine?",
"answer": "Kiev",
"options": [
"Budapest",
"Kiev",
"Minsk",
"Moscow",
"Warsaw"
]
},
{
"id": "QMZVDOMNi0V",
"question": "Which of the following countries does not border Ukraine?",
"answer": "Slovakia",
"options": [
"Belarus",
"Hungary",
"Moldova",
"Poland",
"Slovakia"
]
},
{
"id": "D94SrY60miz",
"question": "What was Ukraine's population prior to the Russo-Ukrainian War?",
"answer": "41 million people",
"options": [
"31 million people",
"41 million people",
"51 million people",
"61 million people",
"71 million people"
]
},
{
"id": "r-Q53DgDdfx",
"question": "Which country is Ukraine's southwest neighbor?",
"answer": "Moldova",
"options": [
"Belarus",
"Hungary",
"Moldova",
"Poland",
"Slovakia"
]
},
{
"id": "tLpl3NzUkGH",
"question": "Which of the following languages are most commonly spoken by Ukrainians besides Ukrainian?",
"answer": "Russian",
"options": [
"Belarusian and Polish",
"Hungarian and Romanian",
"Polish and Slovak",
"Romanian and Turkish",
"Russian"
]
},
{
"id": "PVOr2mGhrwy",
"question": "Which country is the largest in Europe?",
"answer": "Russia",
"options": [
"France",
"Germany",
"Russia",
"Ukraine",
"United Kingdom"
]
}
]
}
curl --location --request POST 'https://zylalabs.com/api/15189/opexams+questions+generator+api/40639/generate+questions' --header 'Authorization: Bearer YOUR_API_KEY'
--data-raw '{
"type": "topicBased",
"topic": "The French Revolution",
"questionType": "MCQ",
"language": "English",
"difficulty": "medium"
}'
注册后,每个开发者都会被分配一个个人 API 访问密钥,这是一个唯一的字母和数字组合,用于访问我们的 API 端点。要使用 OpExams 试题生成器 API 进行身份验证,只需在 Authorization 标头中包含您的 bearer token。
| 标头 | 描述 |
|---|---|
授权
|
必需
应为 Bearer access_key. 订阅后,请查看上方的"您的 API 访问密钥"。
|
根据文本、主题、音频/视频文件或 YouTube 链接生成选择题、判断题和开放式问题及答案。支持 90 多种语言和三个难度级别
长文本(基于上下文)、主题(基于主题)或 YouTube 视频网址(基于转录).
单项选择题(MCQ)、判断题(TF)和开放式问题(open)。每次请求返回5到10道题及答案】【。
90 多种语言。将语言设置为某种语言名称,例如英语或西班牙语,也可以保留为“自动”,以便从输入内容中检测语言。
是的。将难度设置为简单、中等或困难
发送请求头 request-type: test 以接收用于集成测试的示例响应
它返回一个 JSON 对象,其中包含生成的标题和一个数据数组。该数组包含 5–10 个可用于考试的问题对象,每个对象都包含 ID、问题文本、答案,以及适用时的答案选项
每个问题都包含 `id`、`question` 和 `answer`。选择题还包含一个 `options` 数组,其中列出了可能的选项。`answer` 字段标识正确答案 乐彩
将 `type` 设置为 `contextBased`、`topicBased` 或 `transcriptBased`。提供相应的来源值:`contextBased` 对应上下文文本,`topicBased` 对应主题,或 `transcriptBased` 对应 YouTube URL】【。
将 `type` 和 `questionType` 设为必填控件,并可选设置 `language`、`difficulty` 和 `requestId`。`questionType` 的取值为 `MCQ`、`TF` 和 `open`;难度取值为 `easy`、`medium` 和 `hard`】【。
选择题提供一个 `options` 数组和正确的 `answer`。判断题通过 `answer` 标明正确的布尔值式回答。开放式问题提供提示和预期答案;通常不需要选项
`requestId` 允许你为生成请求附加自己的标识符。你可以用它将 API 调用与应用中的测验、课程、任务或记录关联起来。
每个问题都有一个看起来独一无二的 `id`,例如 `Ae19CdyQxub`。应用程序可以使用此值在呈现测验、存储结果、跟踪回答或引用生成内容时识别问题
使用 `type: "transcriptBased"` 时,请提供一个 `youtubeUrl`。该服务会使用视频的文字稿作为素材,并根据其内容返回问题,具体取决于文字稿是否可用及其质量