Type answer
Discussion
This type represents an answer to a question on one of the Stack Exchange sites, such as this famous answer of bobince's.
As on the question page, it is possible to fetch the comments on an answer as part of a call; though this is not done by default.
The upvoted, downvoted, and accepted fields can only be queried for with an access_token with the private_info scope.
Fields
accepted 2.2
boolean
private_info
body_markdown 2.2
string
can_comment 2.3
boolean
can_edit 2.3
boolean
can_suggest_edit 2.3
boolean
comment_count 2.2
integer
content_license 2.2
string
down_vote_count
integer
downvoted 2.2
boolean
private_info
is_accepted
boolean
score
integer
tags 2.1
an array of strings
title
string
up_vote_count
integer
upvoted 2.2
boolean
private_info
Fields marked with are included in the default filter, those marked with are excluded in the default filter.
Examples
► Normal Answer
{"owner":{"reputation":9001,"user_id":1,"user_type":"registered","accept_rate":55,"profile_image":"https://www.gravatar.com/avatar/a007be5a61f6aa8f3e85ae2fc18dd66e?d=identicon&r=PG","display_name":"Example User","link":"http://example.stackexchange.com/users/1/example-user"},"down_vote_count":2,"up_vote_count":3,"is_accepted":false,"score":1,"last_activity_date":1737241251,"last_edit_date":1737266451,"creation_date":1737198051,"answer_id":5678,"question_id":1234,"link":"http://example.stackexchange.com/questions/1234/an-example-post-title/5678#5678","title":"An example post title","body":"An example post body"}
► Locked Answer
{"owner":{"reputation":9001,"user_id":1,"user_type":"registered","accept_rate":55,"profile_image":"https://www.gravatar.com/avatar/a007be5a61f6aa8f3e85ae2fc18dd66e?d=identicon&r=PG","display_name":"Example User","link":"http://example.stackexchange.com/users/1/example-user"},"down_vote_count":2,"up_vote_count":3,"is_accepted":false,"score":1,"last_activity_date":1737241251,"creation_date":1737198051,"locked_date":1737262851,"answer_id":5678,"question_id":1234,"link":"http://example.stackexchange.com/questions/1234/an-example-post-title/5678#5678","title":"An example post title","body":"An example post body"}
► Community Owned Answer
{"owner":{"reputation":9001,"user_id":1,"user_type":"registered","accept_rate":55,"profile_image":"https://www.gravatar.com/avatar/a007be5a61f6aa8f3e85ae2fc18dd66e?d=identicon&r=PG","display_name":"Example User","link":"http://example.stackexchange.com/users/1/example-user"},"down_vote_count":2,"up_vote_count":3,"is_accepted":false,"score":1,"last_activity_date":1737241251,"creation_date":1737198051,"answer_id":5678,"question_id":1234,"link":"http://example.stackexchange.com/questions/1234/an-example-post-title/5678#5678","title":"An example post title","body":"An example post body"}
Methods That Return This Type
answers
answers/{ids}
questions/{id}/answers/render 2.2
answers/{id}/flags/add 2.2
answers/{id}/accept/undo 2.2
answers/{id}/recommend 2.3
answers/{id}/recommend/undo 2.3
answers/{id}/accept 2.2
answers/{id}/downvote/undo 2.2
answers/{id}/downvote 2.2
answers/{id}/upvote/undo 2.2
answers/{id}/upvote 2.2
answers/{id}/delete 2.2
answers/{id}/edit 2.2
questions/{id}/answers/add 2.2
collectives/{slugs}/answers 2.3
questions/{ids}/answers
users/{ids}/answers
users/{id}/tags/{tags}/top-answers
me/answers
me/tags/{tags}/top-answers
answers/{ids}
questions/{id}/answers/render 2.2
answers/{id}/flags/add 2.2
answers/{id}/accept/undo 2.2
answers/{id}/recommend 2.3
answers/{id}/recommend/undo 2.3
answers/{id}/accept 2.2
answers/{id}/downvote/undo 2.2
answers/{id}/downvote 2.2
answers/{id}/upvote/undo 2.2
answers/{id}/upvote 2.2
answers/{id}/delete 2.2
answers/{id}/edit 2.2
questions/{id}/answers/add 2.2
collectives/{slugs}/answers 2.3
questions/{ids}/answers
users/{ids}/answers
users/{id}/tags/{tags}/top-answers
me/answers
me/tags/{tags}/top-answers