PHP2Shell: Is Your Joomla Site Safe? What to Do Today Introducing Next Boards: Kanban project and task boards for Joomla Next Exams 6.2.0: Exam Studio, six visual question types, exam embeds and six new languages Building the Future of Joomla Extensions
NextSoftware

List Questions

GET /v1/nextexams/questions

List bank questions

The question bank, paged. Questions that are private to one exam (made there with Keep in bank off) and retired versions are not listed. Scope questions:read.

Request

GET https://your-site.example/api/index.php/v1/nextexams/questions?limit=<integer>&offset=<integer>&search=<string>&published=<integer>

Parameters

Name Type In Required Description
limit integer query No Page size. (min 1) Defaults to 20.
offset integer query No Rows to skip. (min 0) Defaults to 0.
search string query No Matches the title (and, for questions, the stem).
published integer query No 1 for published only, 0 for unpublished only. One of 0, 1.

Responses

200 — A page of questions.

{
    "data": [
        {
            "id": 1,
            "subject_id": 1,
            "question_type": "string",
            "title": "string",
            "alias": "string",
            "stem": "string",
            "explanation": "string",
            "difficulty": 1,
            "default_points": 1.5,
            "answer_key": {},
            "shuffle_options": true,
            "published": true,
            "version": 1,
            "approval_status": "approved",
            "owner_exam_id": 1,
            "created": "2026-01-01T12:00:00Z",
            "modified": "2026-01-01T12:00:00Z",
            "exam_count": 1
        }
    ],
    "meta": {
        "total": 1
    }
}
Field Type Meaning
data[].id integer
data[].subject_id integer 0 when filed under no subject.
data[].question_type string One of the values GET /question-types returns.
data[].title string The internal name authors see; examinees see the stem.
data[].alias string
data[].stem string The question as examinees see it (HTML).
data[].explanation string|null Shown with the released result (HTML).
data[].difficulty integer 1 (easy) to 5 (hard).
data[].default_points number
data[].answer_key object|null The grading configuration. Its shape depends on question_type.
data[].shuffle_options boolean
data[].published boolean
data[].version integer
data[].approval_status string
data[].owner_exam_id integer 0 for a bank question, the exam's id for one private to an exam, -1 for a retired version.
data[].created string|null ISO 8601 in UTC, or null when not set. (date-time)
data[].modified string|null ISO 8601 in UTC, or null when not set. (date-time)
data[].exam_count integer Exams that use it.
meta.total integer Matching records in all pages.

Errors

Status Code When
401 INVALID_TOKEN No token (MISSING_TOKEN), or one that is wrong, expired, revoked, or whose owner can no longer sign in (INVALID_TOKEN).
403 MISSING_SCOPE The token is valid but this request is not allowed, and code says why: MISSING_SCOPE (the token lacks the scope), FORBIDDEN (the owner's role does not allow it), ACCESS_DENIED (the owner cannot manage Next Exams), API_DISABLED (the API Tokens app is off), APP_DISABLED (the feature's app is off — meta.app names it), ACCOUNT_UNUSABLE (the owner is blocked or must reset their password), DEMO_LOCKED (a demo site).

Examples

curl

curl -s "https://your-site.example/api/index.php/v1/nextexams/questions" \
  -H "Authorization: Bearer $API_TOKEN"

PHP

<?php
$ch = curl_init('https://your-site.example/api/index.php/v1/nextexams/questions?limit=<integer>&offset=<integer>&search=<string>&published=<integer>');

curl_setopt_array($ch, [
    CURLOPT_RETURNTRANSFER => true,
    CURLOPT_HTTPHEADER     => [
        'Authorization: Bearer ' . getenv('API_TOKEN'),
    ],
]);

$response = json_decode(curl_exec($ch), true);
curl_close($ch);

JavaScript

const API_TOKEN = process.env.API_TOKEN;

const response = await fetch("https://your-site.example/api/index.php/v1/nextexams/questions?limit=<integer>&offset=<integer>&search=<string>&published=<integer>", {
  headers: {
    "Authorization": `Bearer ${API_TOKEN}`,
  },
});
const data = await response.json();

All Extensions