> For the complete documentation index, see [llms.txt](https://inquiry.sunbird.org/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://inquiry.sunbird.org/learn/product-and-developer-guide/question-and-question-set-service/apis/v2/questionset-apis/read-private-questionset.md).

# Read Private QuestionSet

This API is used to read an existing private question set on the Sunbird-inQuiry Platform.

## This API is used to read an existing private question set on the Sunbird-inQuiry Platform.

<mark style="color:blue;">`GET`</mark> `/questionset/v2/private/read/{questionSet_id}`

• The <mark style="color:orange;">/questionset/v2/private/read/{QuestionSet\_Id}</mark> endpoint executes a request for fetching the private and public question sets to be viewed and read. \
• The endpoint for reading Private QuestionSet is <mark style="color:orange;">/questionset/v2/private/read</mark>\
• It points to inquiry-api-service (assessment service) - <mark style="color:orange;">/questionset/v5/private/read</mark> \
• You need to provide a valid QuestionSet Id value in <mark style="color:orange;">{questionSet\_id}</mark> field of the API URL.\
• It is mandatory to provide values for parameters marked with <mark style="color:red;">\*</mark>\
• Mandatory fields cannot be null or empty.

#### Path Parameters

| Name                                              | Type   | Description                                       |
| ------------------------------------------------- | ------ | ------------------------------------------------- |
| questionSet\_id<mark style="color:red;">\*</mark> | String | Append a valid Question Set Id To the Request URL |

#### Headers

| Name                                            | Type   | Description                                                                                                                                                                                                                                                 |
| ----------------------------------------------- | ------ | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Content-Type                                    | String | The Content-Type entity is the media type of the resource. Possible media types can be: <mark style="color:green;">Application/json</mark>                                                                                                                  |
| Authorization<mark style="color:red;">\*</mark> | String | <p>To make use of the API, you require authorization. Raise a request to the administrator for the use of the API. You will receive the authorization key. Specify the key received, here.<br>Set <mark style="color:green;">Bearer {{api\_key}}</mark></p> |
| x-channel-id<mark style="color:red;">\*</mark>  | String | Unique identification number associated with a root organization.                                                                                                                                                                                           |

{% tabs %}
{% tab title="200: OK The "Read Private Question Set" operation was successfully executed" %}

```javascript
{
    "id": "api.questionset.private.read",
    "ver": "5.0",
    "ts": "2023-06-29T11:23:27ZZ",
    "params": {
        "resmsgid": "c14dcc78-4387-4a7d-acb5-2e071dbc3117",
        "msgid": null,
        "err": null,
        "status": "successful",
        "errmsg": null
    },
    "responseCode": "OK",
    "result": {
        "questionset": {
            "code": "sunbird.qs.1",
            "allowSkip": "Yes",
            "containsUserData": "No",
            "qumlVersion": 1.1,
            "channel": "test-0001",
            "language": [
                "English"
            ],
            "mimeType": "application/vnd.sunbird.questionset",
            "showHints": false,
            "createdOn": "2023-06-29T11:22:49.141+0000",
            "objectType": "QuestionSet",
            "scoreCutoffType": "AssessmentLevel",
            "primaryCategory": "Practice Question Set",
            "contentDisposition": "inline",
            "lastUpdatedOn": "2023-06-29T11:22:49.141+0000",
            "contentEncoding": "gzip",
            "generateDIALCodes": "No",
            "showSolutions": false,
            "trackable": {
                "enabled": "No",
                "autoBatch": "No"
            },
            "allowAnonymousAccess": "Yes",
            "identifier": "do_2138284054041886721542",
            "lastStatusChangedOn": "2023-06-29T11:22:49.141+0000",
            "schemaVersion": "1.1",
            "requiresSubmit": "No",
            "visibility": "Private",
            "showTimer": true,
            "consumerId": "6968004d-c67e-434a-a350-773aa1e068a3",
            "setType": "materialised",
            "languageCode": [
                "en"
            ],
            "versionKey": "1688037769141",
            "showFeedback": false,
            "license": "CC BY 4.0",
            "createdBy": "sunbird-user-1",
            "compatibilityLevel": 6,
            "name": "QuestionSet-FT-1",
            "navigationMode": "non-linear",
            "allowBranching": "No",
            "shuffle": true,
            "status": "Draft"
        }
    }
}
```

{% endtab %}

{% tab title="404: Not Found The Read Private Question Set operation failed! The possible reason for failure is that you may have provided wrong question set ID." %}

```javascript
{
  "id": "api.questionset.private.read",
  "ver": "5.0",
  "ts": "2023-06-29T07:51:03ZZ",
  "params": {
    "resmsgid": "50bd44a0-ccc8-48fd-9361-3a2990f44e16",
    "msgid": null,
    "err": "NOT_FOUND",
    "status": "failed",
    "errmsg": "Error! Node(s) doesn't Exists. | [Invalid Node Id.]: do_11336896348850585612"
  },
  "responseCode": "RESOURCE_NOT_FOUND",
  "result": {
    "messages": null
  }
}
```

{% endtab %}

{% tab title="500: Internal Server Error Looks like something went wrong! These errors are tracked automatically" %}

```javascript
{
  "id": "api.questionset.private.read",
  "ver": "5.0",
  "ts": "2023-06-29T07:51:03ZZ",
  "params": {
    "resmsgid": "f234a6f0-3ac4-11eb-b0a2-8d5c9f561887",
    "msgid": null,
    "status": "failed",
    "err": null,
    "errmsg": null
  },
  "responseCode": "SERVER_ERROR",
  "result": {}
}
```

{% endtab %}
{% endtabs %}

#### cURL

```shell
curl --location -g --request GET '{{host}}/questionset/v2/private/read/{{questionSet_id}}' \
--header 'Authorization: Bearer {{api_key}}' \
--header 'X-Channel-ID: {{channel_id}}'
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://inquiry.sunbird.org/learn/product-and-developer-guide/question-and-question-set-service/apis/v2/questionset-apis/read-private-questionset.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
