Update QuestionSet

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

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

PATCH /questionset/v1/update

/Update/ endpoint executes the "Update QuestionSet" request based on parameters provided as metadata in the request body. • It points to inquiry-api-service (assessment service) - /questionset/v4/update • It is mandatory to provide values for parameters marked with *. • Mandatory fields cannot be null or empty.

Path Parameters

Name
Type
Description

QuestionSet_Id*

String

Append a valid QuestionSet ID to the requested URL

Headers

Name
Type
Description

Content-Type*

String

The Content-Type entity is the media type of the resource. Possible media types can be:-Application/json

Authorization*

String

All question APIs require authorization for use. Specify the authorization key received from the administrator when placing the request for use of the API. Set Bearer {{api_key}}

x-channel-id

String

Unique identification number associated with a root organization.

Request Body

Name
Type
Description

request*

Object

It contains metadata about the questionset to be updated.

{
  "id": "api.questionset.update",
  "ver": "3.0",
  "ts": "2021-02-02T19:55:07ZZ",
  "params": {
    "resmsgid": "9d9d4824-cc40-4ac7-a3d6-6da61c0240e9",
    "msgid": null,
    "err": null,
    "status": "successful",
    "errmsg": null
  },
  "responseCode": "OK",
  "result": {
    "identifier": "do_113207924037746688110",
    "versionKey": "1612295707004"
  }
}

Sample Request

{
  "request": {
    "questionset": {
      "description": "Updated description",
      "versionKey": "1612295414767"
    }
  }
}

Request schema

Attribute
Type
Description
Required

versionKey

String

Represents the transaction update version key of the Questionset

Yes

description

String

Represents the description of the Questionset

No

Success result schema

Attribute
Type
Description

identidier

String

Unique Question identifier

versionKey

String

Unique version key for question

cURL

curl --location -g --request PATCH '{{host}}/questionset/v1/update/{{questionSet_id}}' \
--header 'Content-Type: application/json' \
--header 'Authorization: Bearer {{api_key}}' \
--data-raw '{
  "request": {
      "questionset":{
        "versionKey": {{versionKey}},
        "description": "Updated description"
      }
  }
}'

Last updated