Closed
Bug 1089770
Opened 10 years ago
Closed 10 years ago
Need to get all answers to a question.
Categories
(support.mozilla.org :: Questions, task, P2)
support.mozilla.org
Questions
Tracking
(Not tracked)
RESOLVED
FIXED
2014Q4
People
(Reporter: rik, Assigned: mythmon)
References
Details
(Whiteboard: u=dev c=buddyup p=1 s=2014.20)
To have a responsive application, we need to get all answers to a question in one request. I think the cleanest API for this would be GET /question/{id}?full_content=1 or something similar.
Assignee | ||
Comment 1•10 years ago
|
||
After some thought (and looking at some other APIs including GitHub's issue API) I think it would make sense to just include the content in the response all the time. Does that sound reasonable to you? Then to get all answers to a question you could make a GET to /api/2/answer/?question={id} and that would include everything you need to fill out the answers on a question detail page. Do you see any problem with always including the full content?
Reporter | ||
Comment 2•10 years ago
|
||
No, we will never query an answer without the content. I was thinking though that putting this API on the question endpoint will allow us to only do one HTTP request when a user opens a thread.
Reporter | ||
Comment 3•10 years ago
|
||
We're going to go with /api/2/answer/?question={id} that gives us the full content for now. It's one more request but that's not too bad and will make it much easier to implement server side.
Assignee | ||
Comment 4•10 years ago
|
||
In a PR: https://github.com/mozilla/kitsune/pull/2194
Comment 5•10 years ago
|
||
Landed on master: https://github.com/mozilla/kitsune/commit/2cf4aab3a677521d9815540c4891d92fd5da1d8f
Comment 6•10 years ago
|
||
Mike did this in this sprint. Assuming 1pt
Assignee: nobody → mcooper
Priority: -- → P2
Whiteboard: u=dev c=buddyup p=1 s=2014.20
Target Milestone: --- → 2014Q4
Comment 7•10 years ago
|
||
Deployed to prod.
Status: NEW → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
You need to log in
before you can comment on or make changes to this bug.
Description
•