[keyserver/lib] Set up the endpoints and responder for retrieving media
Summary:
This diff handles setting up the endpoints and responder for actually fetching the media for a given thread. The changes made are:
- Set up the endpoint (keyserver/src/endpoints.js) and the type (lib/types/endpoints.js)
- Use callServerEndpoint in lib/actions/thread-actions.js to hit the newly created endpoint, and route to the appropriate responder.
- Handle the validation of the request and call fetchMediaForThread from the responder in keyserver/src/responders/thread-responders.js
Linear: https://linear.app/comm/issue/ENG-2874/set-up-the-endpoints-and-responder-for-retrieving-media
Depends on D6485
Test Plan: Ran flow for all of the new type introductions, and this will be tested in the next diff where we actually use useServerCall to retrieve the media.
Reviewers: atul, ginsu, kamil, tomek, ashoat
Reviewed By: ashoat
Subscribers: ashoat
Differential Revision: https://phab.comm.dev/D6531