question-answers

Create Question Answer

POST
Creates a question-answer.

Request

This endpoint expects an object.
answer
stringRequired
Answer of the question-answer.
applies_to_parts
list of stringsRequired
The parts that the question-answer applies to.
owned_by
list of stringsRequired
The users that own the question-answer.
question
stringRequired
Question of the question-answer.
status
enumRequired
Status of the question answer.
Allowed values: archiveddraftpublishedreview_needed
access_level
enumOptional
Allowed values: externalinternalprivatepublicrestricted
applies_to_articles
list of stringsOptional
The articles that the question-answer applies to.
shared_with
list of maps from strings to anyOptional
Information about the role the member receives due to the share.
sources
list of stringsOptional
The source of the question-answer.
suggested_answer
stringOptional
Alternative answer for the question-answer sugested by Q/A Discovery.
suggested_for_deletion
booleanOptional
Whether the question-answer was suggeste to be deleted by Q/A Discovery.
tags
list of objectsOptional
Tags associated with the question-answer.
topic
stringOptional
Topic of the question-answer.
verified
booleanOptional
Whether the question-answer was verified by a user or not.

Response

This endpoint returns an object
question_answer
object
POST
1curl -X POST https://api.devrev.ai/question-answers.create \
2 -H "Authorization: <apiKey>" \
3 -H "Content-Type: application/json" \
4 -d '{
5 "answer": "answer",
6 "applies_to_parts": [
7 "applies_to_parts"
8 ],
9 "owned_by": [
10 "owned_by"
11 ],
12 "question": "question",
13 "status": "archived"
14}'
200
Successful
1{
2 "question_answer": {
3 "id": "id",
4 "answer": "answer",
5 "created_date": "2023-01-01T12:00:00Z",
6 "display_id": "display_id",
7 "modified_date": "2023-01-01T12:00:00Z",
8 "question": "question",
9 "suggested_answer": "suggested_answer",
10 "suggested_for_deletion": true,
11 "topic": "topic",
12 "verified": true
13 }
14}