API for question bank data

API for question bank data

by suraj shukl -
Number of replies: 5

How to fetch Question bank data through API ?
we are not able to get any API from Moodle to fetch question bank database.

Average of ratings: -
In reply to suraj shukl

Re: API for question bank data

by suraj shukl -
Hi All,

we are waiting your support for this.
Please help for fetch Question bank data through API.
In reply to suraj shukl

Re: API for question bank data

by Marcus Green -
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers

What have you found so far?

In reply to Marcus Green

Re: API for question bank data

by suraj shukl -
Hi Marcus Green,

Thank you for your response.

I didn't find much details on this. I have checked the url(https://docs.moodle.org) for Question bank API and Question engine API but there is no text in both pages. I have review this URL https://docs.moodle.org/dev/Question_bank_API and https://docs.moodle.org/dev/Question_engine_API
but not got any information for question bank API.
I am new for Moodle. I need to make a different front-end I need good API interface for Question Bank/Question Engine.
In reply to suraj shukl

Re: API for question bank data

by Marcus Green -
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers
The Mobile app makes extensive use of web services for end user calls to questions and you can find the code here
https://github.com/moodlehq/moodleapp/
Another source is to see how various plugins use the question bank, e.g. studentquiz and you can find automated documentation for the whole Moodle api here
https://wimski.org/api/4.1/modules.html

A lot of Moodle development comes down to reading other peoples code rather than reading API docs.
In reply to Marcus Green

Re: API for question bank data

by suraj shukl -
Hi Marcus Green,
I am using
Moodle 4.1.2
MOODLE_4012
I am creating the web application that's why I need API from Moodle and I have found this web services wsfunction=core_course_get_courses to get all courses from moodle that is fine and it worked.
so I am also looking is there any web services to get all the question from moodle question bank. If yes then help for this.
I tried but could not get success. I want a simple documentation for this from where I can see the endpoint for the question bank and simply call them to get those question from question bank.