Reject Question
This API is used to reject the questions on the Sunbird-inQuiry Platform.
This API is used to reject the questions on the Sunbird-inQuiry Platform.
DELETE
/question/reject/{Question_Id}
• /question/reject/{Question_Id} endpoint executes the "Reject Question" request based on parameters provided as metadata in the request body • This API is used to send back the question to the creator by the reviewer. The API changes the question object status from review to draft. • It points to inquiry-api-service (assessment service) - /question/v4/reject • It is mandatory to provide values for parameters marked with *. • Mandatory fields cannot be null or empty.
Path Parameters
Question_Id*
String
Append a valid Question ID To the Request URL
Headers
Authorization*
String
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.
Set Bearer {{api_key}}
x-channel-id
String
Unique identification number associated with a root organization.
Request Body
request*
Object
Metadata about the question to be rejected.
{
"id": "api.question.reject",
"ver": "3.0",
"ts": "2021-10-19T12:49:25Z+05:30",
"params": {
"resmsgid": "70dc4cef-b7d0-4794-ae78-e80cc85b4770",
"msgid": null,
"err": null,
"status": "successful",
"errmsg": null
},
"responseCode": "OK",
"result": {
"identifier": "do_11336893480941158415",
"versionKey": "1634627965206"
}
}
Success result schema
identidier
String
Unique Question identifier
versionKey
String
Unique version key for question
cURL
curl --location -g --request POST '{{host}}/question/v1/reject/{{question_id}}' \
--header 'Authorization: Bearer {{api_key}}' \
--header 'X-Channel-ID: {{channel_id}}' \
--header 'Content-Type: application/json' \
--data-raw '{
"request": {
"question": {
"rejectComment":"Rejected for testing"
}
}
}'
Last updated
Was this helpful?